LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Security (https://www.linuxquestions.org/questions/linux-security-4/)
-   -   OS X like Stealth Mode - iptables ?? (https://www.linuxquestions.org/questions/linux-security-4/os-x-like-stealth-mode-iptables-704000/)

phpinfo 02-11-2009 05:37 PM

OS X like Stealth Mode - iptables ??
 
OS X Leopard Server has firewall options for TCP and UDP stealth mode, which does things like block port scans etc. If you try to do a port scan you won't get any results.

I am using RHEL4. Is there a way to setup iptables in similar fashion with "stealth mode" and block port scans etc.?

win32sux 02-11-2009 05:52 PM

Quote:

Originally Posted by phpinfo (Post 3440289)
OS X Leopard Server has firewall options for TCP and UDP stealth mode, which does things like block port scans etc. If you try to do a port scan you won't get any results.

I am using RHEL4. Is there a way to setup iptables in similar fashion with "stealth mode" and block port scans etc.?

Yes. If you only send inbound packets in states RELATED and ESTABLISHED to ACCEPT (and all others to DROP), then that is considered "stealth mode". Example:
Code:

iptables -P INPUT DROP
iptables -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A INPUT -i lo -j ACCEPT



All times are GMT -5. The time now is 03:44 AM.