Friday, August 19, 2011

Logging telnet sessions

We can use TCP Wrapper in logging telnet access of system. spawn is used to launches shell command as child process, this concept can be used to log telnet session. To achieve this just do following entries in /etc/hosts.allow on system hosting telnet server


in.telnetd : .abc.com : spawn /bin/echo `/bin/date` from %h>>/var/log/telnet.log : allow