Here are some rules that I append to filter
table, and I list the added output related to each one:
$iptables -A INPUT -i eth0 -j ACCEPT
and the output is:
target prot opt source destination
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0
The second command:
$iptables -A INPUT -i eth1 -j ACCEPT
And the appended rule to INPUT chain is the same as the first one:
target prot opt source destination
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0
As you see, I changed the source of packets from eth0
to eth1
, but I don't see it reflected in the appended rule. Can anybody explain me where is the difference made or how the iptables
knows that first rule is related to eth0
and second rule is related to eth1
?
Thanks!
-v
– Jon Lin Jan 17 '12 at 7:30