Ask the Expert

Use the right rules in your firewall

How should an administrator determine what rules to set up in a particular firewall?

    Requires Free Membership to View

The best way to go about setting up your rules is to document your requirements in detail. For host firewalls, I tend to identify three types of rules -- incoming traffic flow rules, outgoing traffic flow rules and defensive rules.

Incoming and outgoing traffic flow rules are the traffic flows used by your applications and operating system. You should document their source, destination, ports and any other useful characteristics about them. Lay them out in tables or in a spreadsheet to allow you to better visual and keep track of them. You should also try to "lock" down your rules. If it is possible to limit the source or destination of traffic flow, then do so. For example, if you only need to access two DNS servers then you can write rules to ensure traffic on port 53 can only go to those DNS servers.

Defensive rules consist of rules designed to counter known network-based attacks, scanning and other forms of malicious traffic. There are a variety of these available to you. Many of them are documented in various iptables scripts or sites online. These include rules to counteract network and port scans, SYN/ACK attacks, SYN flooding and other types of malicious traffic. These change on a regular basis so you need to keep up with current attacks and counters. You also need to extensively test these sorts of rules. In the past, badly coded applications have occasionally behaved like attack or scanning tools and had their traffic blocked by these types of rules.

This was first published in August 2005

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: