Combine iptables and ufw

  • Posted July 6, 2013


Is it correct that ufw and iptables can be combined, the thing is that i would lve some help on getting a iptables up that block dos/syn flood / and what else to block :D

i a little on thin ice on if i should add :

iptables -P INPUT DROP iptables -P FORWARD DROP iptables -P OUTPUT

before OR after i have made som ruleset?


Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Did you try using “sudo ufw reload” after updating your iptables? I have not tried it, but this mentions it:

Could have been i misread :)

Where did you learn “that ufw and iptables can be combined?” <br> <br>According to this article (<a href=“”>Why ufw Does Not Need A GUI</a> ) that’s already the case (albeit it’s a little dated), in that ufw uses/manipulates iptables. That is, ufw <i>sits on top of</i> iptables. <br> <br>According to the <a href=“”>Ubuntu Manpages</a>, “ufw uses many user-defined chains in addition to the built-in iptables chains.” The <a href=“”>Ubuntu Manpage on ufw</a> also provides some examples. <br> <br>In re: to a ufw HowTo, DigitalOcean has a nice tutorial: <a href=“”>How to Setup a Firewall with UFW on an Ubuntu Cloud Server</a>