ipfw are these two rules the same even though writen different

memyselfnehelp

Registered
Hello I'm a bit confused on these rules right here. Can someone explain if these two rules are the same or different.

05036 deny ip from 127.0.0.0/8 to any in"
05037 deny ip from 127.0.0.0/8 to any out"

The same as?

11010 deny ip from 127.0.0.0/8 to any in"
11020 deny ip from any to 127.0.0.0/8 in"
 
The are different, the first pair says that traffic from 127.0.0.0/8 will be blocked in both the in and out directions. The second one blocks the same set of incoming traffic from 127.0.0.0/8 but none of the matching outgoing traffic in the first pair. Instead, the last rule blocks traffic originated anywhere from reaching something in 127.0.0.0/8.

It might help you to draw a couple of pictures and label the hosts and connection directions, since it is hard to capture these things textually at times.

Good Luck!
 
Back
Top