First rule in the list seems to allow everything?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



 

Hello,

I set my IPTABLES policy to clear all rules and then drop everything
before defining a policy. I suspect this is the default procedure
everyone uses from the looks of the web. Anwyay, when I run iptables -L
-n the first line reads:

target     prot opt source               destination
ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0
RULES      --------			---	------
RULES      --------			---	------

Doing an nmap scan on the box only shows the open ports I specified in
the ruleset. This is good. However, the Accept all above in the first
line has me a little confused. What is happening here?

thanks

# Reset the default policy

echo Resetting default policy!
$IPT --policy INPUT ACCEPT
$IPT --policy OUTPUT ACCEPT
echo OK


echo Allowing all loopback traffic!
# Unlimited traffic on the loopback interface
$IPT -A INPUT -i lo -j ACCEPT
$IPT -A OUTPUT -o lo -j ACCEPT
echo OK

echo Setting default policy to Drop all incoming and allow all outgoing!
# Set the default policy to drop
$IPT --policy INPUT DROP
$IPT --policy OUTPUT ACCEPT
echo OK

ALLOW RULES START HERE!



[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux