Saturday, 1 June 2013

Exclude Specific User From '/var/log/auth.log'

Exclude Specific User From '/var/log/auth.log'

I am currently setting up a VPS and was wondering if there is any way at all for me to exclude a specific user from being logged to '/var/log/auth.log'?
Doing the same for lastlog and every other log file that is somehow affected by sshd would be even better.
I know I can '/dev/null/' the entire log file, but this would obviously break fail2ban and similiar packages.
I have come across a solution that relies on a cron job cutting out the offending parts, but this seems a little dodgy. Any ideas? Thanks!

No comments:

Post a Comment