Trevor <[EMAIL PROTECTED]> said:

> echo `date` $SSH_CLIENT >> logfile.txt

Thanks Trevor.

Finished /etc/profile.d/ssh-notification.sh now looks like this:

-rwxr-xr-x 1 root root 113 Jun 14 09:40 ssh-notification.sh

#!/bin/sh
if [ "$SSH_CLIENT" ]; then
echo "SSH: $USER from $SSH_CLIENT on `date`" >> /var/log/ssh_access.log
fi

Log file /var/log/ssh_access.log looks like this:

SSH: root from 192.168.1.70 1985 22 on Fri Jun 14 09:40:26 PDT 2002

and is of course easily viewable via the server-manager, View log files
panel.

Regards,


--
Darrell May
DMC Netsourced.com
http://netsourced.com
http://myEZserver.com


--
Please report bugs to [EMAIL PROTECTED]
Please mail [EMAIL PROTECTED] (only) to discuss security issues
Support for registered customers and partners to [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Archives by mail and http://www.mail-archive.com/devinfo%40lists.e-smith.org

Reply via email to