Any way check and notify if some one made a change/addition to cronjobs for a particular user on a Linux server?
Is it possible to know the changes made too?
|
Any way check and notify if some one made a change/addition to cronjobs for a particular user on a Linux server? Is it possible to know the changes made too? |
||||
|
|
|
Lots of them, but (afaik) nothing intrinsic to cron. I would probably use tripwire on the server, and make sure that |
|||
|
|
|
If someone edits his per-user crontab file via user alex edited his own crontab file:
user root edited the crontab file of user alex:
If the crontab gets changed by an external editor, then the following example log entry appears in /var/log/syslog:
This logging mechanism is probably configurable but is activated by default at least on Debian and Ubuntu and I suppose most other distributions, too. |
|||
|
|
grep for ' Write a monitoring script for this log file and using which sent an alert to your email ID. If you want you can use following script for monitoring a particular users cron entries:
|
|||||
|
|
You can use |
|||
|
|