Ubuntu Uncomplicated Firewall
A nice new feature in Ubuntu 8.04 is the so called Uncomplicated Firewall (UFW). It’s a command line tool to handle simple firewall rules on a stand alone computer.
Basically UFW acts as a fronted, with its own configurations files, to iptables-restore. Besides keeping track of saving and loading your firewall rules, the thing which makes UFW really neat is its simple syntax. Assuming you have set it to default deny, and you want to open up port 80 for example, all you have to type is
$ ufw allow 80
If you want to do something more specific there’s a PF-inspired syntax availible.
$ ufw allow proto tcp from 192.168.0.42 to any port 22
Currently there isnt’t that much online documentation available on UFW. Luckily it has a rather well written man(ual) page in ufw(8).