Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 27 Feb 2014 08:37:02 +0000
From:      Arthur Chance <freebsd@qeng-ho.org>
To:        Jim Pazarena <fquest@paz.bz>, FreeBSD Questions <freebsd-questions@freebsd.org>
Subject:   Re: notifications of log in
Message-ID:  <530EF92E.2050004@qeng-ho.org>
In-Reply-To: <530EBAEA.9050300@paz.bz>
References:  <530EBAEA.9050300@paz.bz>

next in thread | previous in thread | raw e-mail | index | archive | help
On 27/02/2014 04:11, Jim Pazarena wrote:
> Is there a way to have syslog email a notice upon ANY log in to a
> server, by any user ID?
>
> I'm not worried about failed attempts, but I'd like a prompt notice if
> someone does successfully log in.

According to the syslog.conf manual, one option for the action on an 
event is:

> A vertical bar (“|”), followed by a command to pipe the selected mes‐
> sages to.  The command is passed to sh(1) for evaluation, so usual
> shell metacharacters or input/output redirection can occur.

You could feed auth facility syslog events to a script that mails you 
about console logins, sshd events and anything else relevant.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?530EF92E.2050004>