Send an email when someone uses sudo
To keep track when any user uses sudo on your Linux system.
Requirements:
You will need an e-mail server, like sendmail:
apt-get install sendmail
1 - create this file:
sudo nano /etc/sudoers.d/my_sudoers
2 - Add this content:
Defaults mail_always
Defaults mailto="youremail@domain.com"
Written by emi420
Related protips
1 Response
This could be very useful but in my opinion it's very funny! :P
But again, very useful, for tracking and event viewing! ;)
Nice ProTip! :)
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Linux
Authors
Related Tags
#linux
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#