Skip to content

Instantly share code, notes, and snippets.

@vnugent
Created November 5, 2014 17:06
Show Gist options
  • Save vnugent/3f3db05ce2d8abfffd85 to your computer and use it in GitHub Desktop.
Save vnugent/3f3db05ce2d8abfffd85 to your computer and use it in GitHub Desktop.
#!/bin/bash
iptables -F
iptables -X
while read type;
do
iptables -t $type -F
iptables -t $type -X
done </proc/net/ip_tables_names
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
service iptables save
service iptables restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment