Guest User

Untitled

a guest
Mar 24th, 2018
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. #!/bin/sh
  2. IPTABLES="$(which iptables)"
  3.  
  4. # RESET DEFAULT POLICIES
  5. $IPTABLES -P INPUT ACCEPT
  6. $IPTABLES -P FORWARD ACCEPT
  7. $IPTABLES -P OUTPUT ACCEPT
  8. $IPTABLES -t nat -P PREROUTING ACCEPT
  9. $IPTABLES -t nat -P POSTROUTING ACCEPT
  10. $IPTABLES -t nat -P OUTPUT ACCEPT
  11. $IPTABLES -t mangle -P PREROUTING ACCEPT
  12. $IPTABLES -t mangle -P OUTPUT ACCEPT
  13.  
  14. # FLUSH ALL RULES, ERASE NON-DEFAULT CHAINS
  15. $IPTABLES -F
  16. $IPTABLES -X
  17. $IPTABLES -t nat -F
  18. $IPTABLES -t nat -X
  19. $IPTABLES -t mangle -F
  20. $IPTABLES -t mangle -X
Add Comment
Please, Sign In to add comment