User Tools

Site Tools


networking:firewall:iptables

This is an old revision of the document!


IPtables Firewall

IPtables is the default firewall on Redhat-based distros.

http://www.cyberciti.biz/faq/rhel-fedorta-linux-iptables-firewall-configuration-tutorial/

List rules:

iptables -nL <table> -v

Flush All

  1. Set the default policies for each of the built-in chains to ACCEPT
  2. Flush the nat and mangle tables
  3. Flush all chains (-F)
  4. Delete all non-default chains (-X)
  5. Flush all counters (-Z)
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
iptables -F
iptables -X
iptables -Z
iptables -t nat -F
iptables -t nat -X
iptables -t mangle -F
iptables -t mangle -X
iptables -t raw -F
iptables -t raw -X
networking/firewall/iptables.1659021180.txt.gz · Last modified: 2022/07/28 09:13 by gcooper