/etc/hosts.deny "booby trap"
The manpage of HOSTS_ACCESS has a section called "BOOBY TRAPS" which
describes how to automatically to do a finger on a machine which
is denied network via /etc/hosts.deny, and mail its output to root.
I'm attmpting to set this up so that any telnet request from outside
my lan is denied and the output of a finger on the offending machine
is sent to me.
Here are my access files:
# next line is "booby trap" for denied telnet requests
in.telnetd: ALL: (/usr/bin/finger -l @%h | /usr/bin/mail -s %d-%h root) &
ALL: LOCAL, .my-net, 192.168.1.
Access seems to be denied (and granted) as I'd like it to be, but the
"booby trap" doesn't seem to work. I copied the example in the manpage
for HOSTS_ACCESS, changing the things specific for my network, but it
just doesn't seem to do the finger and mail the output.
Has anyone gotten this to work?
Powered by Debian GNU/Linux 2.1