in reply to Echo off in IO::Sockets

Unlike others, I see a legitimate need for this kind of functionality.

However there is no need to use Perl to get that. Instead investigate /etc/syslog.conf and you will find that login errors are already logged for you. If you are an authorized administrator (and not a moronic script kiddie) you should be able to figure out what you need to legimately do from the messages you can log from there.