Skip to main content
IBM  
Shop Support Downloads
IBM Home Products Consulting Industries News About IBM
IBM developerWorks : Linux : Education - Tutorials
LPI certification 102 exam prep, Part 3
ZIPPDF (letter)PDF (A4)e-mail
Main menuSection menuFeedbackPreviousNext
3. Internet services
  


Restricting access to known hosts with TCP wrappers page 10 of 12


There's no need to reload inetd, since tcpd is invoked each time there's a connection on the telnet port. So we can try it immediately:


# telnet box.yourdomain.com
Trying 10.0.0.1...
Connected to box.yourdomain.com.
Escape character is '^]'.
Connection closed by foreign host.

Slap! Rejected! (This is one of the few times in life that rejection is indicative of success.) To re-enable access from our own network, we insert the exception in /etc/hosts.allow:


in.telnetd: .yourdomain.com

At this point we're able to successfully telnet into our system again. This is just scraping the surface of the capabilities of tcp_wrappers. There's lots more information on tcp_wrappers in the tcpd(8) and hosts_access(5) man pages.


Main menuSection menuFeedbackPreviousNext
Privacy Legal Contact