Could someone shed some light on what the current iptables entry on my RedHat machine means?

-A RH-Firewall-1-INPUT -j REJECT --reject-with icmp-host-prohibited

It is the last line in my /etc/sysconfig/iptables file

Any rule I add after that does not take affect. I have to add all rules above that line.

Is there a top to bottom precedence in the iptables file? (rule on top take precedence over rules bellow)


Iptables rules will be applied in order. This rule will match all packets (there is no port/address/etc listed), jump to the REJECT table (which will reject the packet), and send an icmp host prohibited packet back to the source.

You should also look at the INPUT table, as this rule is added to the RH-Firewall-1-INPUT table (the -A option).

| improve this answer | |

In general, firewall rules are applied top to bottom. It's like that (as far as I know) in iptables as well as on most Cisco PIX/Firewall products.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.