Sep 032009
 

Debian does not come with a good (I mean, easy to use :D) firewall, and to me ufw on Ubuntu is pretty cool so searched around, found this link:

http://blog.ropetin.com/?p=94

and copy some words here in case someday that URL becomes inaccessible:

# sudo apt-get install python
# wget http://people.ubuntu.com/~jamie/ufw/ufw-0.25.tar.gz
# tar -xzvf ufw-0.25.tar.gz
# cd ufw-0.25
# sudo python ./setup.py install

Once installed it needs to be configured, which really depends on your requirements.ย  A basic setup that allows SSH access, while blocking most other access can be configured by;

# sudo ufw logging on
# sudo ufw default deny
# sudo ufw allow proto tcp from any to any port 22
# sudo ufw enable

  7 Responses to “ufw on Debian”

  1. Also should do a “sudo ln -fs /lib/ufw/ufw-init /etc/init.d/ufw”, and then do regular link to etc/rc?.d/ to make sure ufw is started during boot time.

  2. In lenny and ufw 0.25+ (which is what i’ve been using), you can do a

    ln -s /usr/share/ufw/ufw-init /etc/init.d/ufw

    and then a

    update-rc.d ufw defaults

    to make ufw start at boot time.

  3. ufw is part of ubuntu 9.10, so …

  4. […] UFW to boot with tips from here:ย ln -fs /lib/ufw/ufw-init […]

  5. You no longer need to download ufw from a separate site. It’s in the Debian repositories now. i documented two very detailed guides at http://mauroandres.wordpress.com/2009/12/14/build-a-secure-desktop-firewall-with-ufw-part-i/
    and
    http://mauroandres.wordpress.com/2010/01/28/build-a-secure-desktop-firewall-with-ufw-part-ii/

  6. […] UFW to boot with tips from here: ln -fs /lib/ufw/ufw-init […]

Sorry, the comment form is closed at this time.