summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSeth Vidal <skvidal@fedoraproject.org>2013-05-15 21:39:29 +0000
committerSeth Vidal <skvidal@fedoraproject.org>2013-05-15 21:39:29 +0000
commitc25ebc632c0916a8f79cff42737d95ad1f58f7ce (patch)
tree02a757ad522467c7a337407f2288aa5fde2e03bb
parentc791133923444d18d7f7968bcdbeec552301258a (diff)
downloadansible-c25ebc632c0916a8f79cff42737d95ad1f58f7ce.tar.gz
ansible-c25ebc632c0916a8f79cff42737d95ad1f58f7ce.tar.xz
ansible-c25ebc632c0916a8f79cff42737d95ad1f58f7ce.zip
add simple default iptables
-rw-r--r--files/iptables/iptables15
1 files changed, 15 insertions, 0 deletions
diff --git a/files/iptables/iptables b/files/iptables/iptables
new file mode 100644
index 000000000..85f56c1a2
--- /dev/null
+++ b/files/iptables/iptables
@@ -0,0 +1,15 @@
+# Simple static firewall loaded by iptables.service. Replace
+# this with your own custom rules, run lokkit, or switch to
+# shorewall or firewalld as your needs dictate.
+*filter
+:INPUT ACCEPT [0:0]
+:FORWARD ACCEPT [0:0]
+:OUTPUT ACCEPT [0:0]
+-A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
+-A INPUT -p icmp -j ACCEPT
+-A INPUT -i lo -j ACCEPT
+-A INPUT -m conntrack --ctstate NEW -m tcp -p tcp --dport 22 -j ACCEPT
+-A INPUT -m conntrack --ctstate NEW -m tcp -p tcp --dport 80 -j ACCEPT
+-A INPUT -j REJECT --reject-with icmp-host-prohibited
+-A FORWARD -j REJECT --reject-with icmp-host-prohibited
+COMMIT