Bug 462603 - Tighten firewall rules
Summary: Tighten firewall rules
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat HPC Solution
Classification: Red Hat
Component: kusu-base-installer
Version: 5.1
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: OCS Support
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-09-17 13:53 UTC by Daniel Riek
Modified: 2009-06-08 13:12 UTC (History)
1 user (show)

Fixed In Version: ocs-5.1-5
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-09-29 19:08:30 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Daniel Riek 2008-09-17 13:53:12 UTC
The current firewall rules for the HPC Solution have the following
catch-all rules in the INPUT part:
  
        for dev in private_nics:
            filter += '-A FORWARD -i %s ' % dev + \
                      '-o %s -m state ' % public + \
                      '--state RELATED,ESTABLISHED -j ACCEPT\n'
            filter += '-A FORWARD -i %s -j ACCEPT\n' % dev
            filter += '-A INPUT -i %s -j ACCEPT\n' % dev
        filter += '-A INPUT -i lo -j ACCEPT\n'
        filter += '-A INPUT -p icmp --icmp-type any -j ACCEPT\n'
        filter += '-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT\n'
        filter += '-A INPUT -i %s -p tcp --dport 0:1024 -j REJECT\n' % public
        filter += '-A INPUT -i %s -p udp --dport 0:1024 -j REJECT\n' % public

That leaves ports higher than 1024 available for remote connections from
public networks. We think that that is dangerous and we would prefer the
last two to be consolidated into one much stricter rule:
        filter += '-A INPUT -i %s -j REJECT\n' % public

Also there would be need for additional rules to open the public ports used by ntop, cacti, or nagios, etc.

Comment 1 OCS Support 2008-09-18 15:58:56 UTC
The code has been changed to replace the last 2 reject rules with the alternate i.e.
-        filter += '-A INPUT -i %s -p tcp --dport 0:1024 -j REJECT\n' % public
-        filter += '-A INPUT -i %s -p udp --dport 0:1024 -j REJECT\n' % public
+        filter += '-A INPUT -i %s -j REJECT\n' % public

The solution will be available in kusu-base-installer 5.1-28 or better

Comment 2 OCS Support 2008-09-29 13:26:52 UTC
Fix has passed QA


Note You need to log in before you can comment on or make changes to this bug.