Visit Jeremy's Blog.
Go Back > Blogs > arniekat
User Name


Rate this Entry


Posted 09-18-2011 at 09:11 PM by arniekat

Uncomplicated Firewall

Get the SlackBuild Tarball for Slackware 13.1 from It will be for ufw version 0.27. Go to and download the ufw-0.30.1.tar.gz source code. After untarring the SlackBuild tarball, open the ufw.SlackBuild with a text editor and change the version to 0.30.1, like so:


Save the SlackBuild with the changes, compile the package, and install it.

The startup scripts for Slackware 13.37 check to see if you have a file called /etc/rc.d/rc.firewall

If this file exists and is executable, the startup script runs it. You can put the raw iptables commands here, but I put the commands to startup the ufw firewall tool and it worked fine. Create the file /etc/rc.d/rc.firewall

# vi /etc/rc.d/rc.firewall

and place the following in it:

# /etc/rc.d/rc.firewall
# This file is for Slackware 13.37 to enable the UFW application
# to run at boot-time. Be sure this file is executable, like so:
# chmod +x /etc/rc.d/rc.firewall
ufw enable

Save the file, exit, and make the file executable.

# chmod +x /etc/rc.d/rc.firewall

Now, you can either reboot to start the firewall or do it manually with:

# ufw enable
Firewall is active and enabled on system startup

ufw is set by default to a default deny policy, which means that your machine will not allow incoming connections to your machine. This setup will allow your browser to make connections outbound to the Internet. If you need to allow certain incoming connections to your machine, put these commands before the "ufw enable" line in the file /etc/rc.d/rc.firewall (See ufw manpages). To check the status of the firewall:

# ufw status
Status: active

If you decide you do not want to run the firewall at boot-time, just take away the executable bit from the script:

# chmod -x /etc/rc.d/rc.firewall
Posted in Uncategorized
Views 1813 Comments 0
« Prev     Main     Next »
Total Comments 0




All times are GMT -5. The time now is 02:24 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration