Is the ufw firewall default setting save or not?

Asked by Manes on 2008-08-02

Hi,

I installed Ubuntu 8.04 on my computer. I enabled the firewall ufw by "sudo ufw enable". What is the default status of ufw? Is it save or not? Are there any ports open? Can someone access my computer from the Internet? I would like to avoid this.
What do I need to do forbid any access from the Internet? I know there it the command "sudo ufw default deny". Only this doesn't seem to be persistent. I would not like to run it with each log on. How could I make this persistent?

Thanks for your help

Manes

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu ufw Edit question
Assignee:
No assignee Edit question
Solved by:
Vojtěch Trefný
Solved:
2008-09-20
Last query:
2008-09-20
Last reply:
2008-08-28

Hi, default status of UFW is to deny all incoming traffic. If you want to create special rules, or just set the firewall, you can use GUFW - graphical interface for UFW -- it's simple and easy.

Homepage -- http://gufw.tuxfamily.org/index.html
Launchpad page -- https://edge.launchpad.net/gui-ufw

Deepak Mishra (dpux) said : #2

download the GUI (Gufw), this will get you what you want.
http://gufw.tuxfamily.org/screenshots.html

bodhi.zazen (bodhi.zazen) said : #3

I hate to post contrary information, but the default status of ufw is permissive :

Also gui tools do not answer the OP question nor do they work on server w/o X, LOL

Check it out for yourself :

sudo ufw enable
sudo iptables -L

To set your default, use

sudo ufw default allow

or

sudo ufw default deny

See also :

https://help.ubuntu.com/8.04/serverguide/C/firewall.html

https://help.ubuntu.com/community/Uncomplicated_Firewall_ufw

Jamie Strandboge (jdstrand) said : #4

By default the firewall is disabled. If you do 'sudo ufw enable', the firewall is default deny for incoming and default allow for outgoing. Once ufw is enabled, it is saved so subsequent reboots will have it enabled. ufw has a straightforward command line interface for adding rules and changing various settings. Please see https://help.ubuntu.com/8.04/serverguide/C/firewall.html and 'man ufw' for details.

Thanks Vojtěch Trefný, that solved my question.