Article View: comp.security.firewalls
Article #499Re: SonicWall Rule Denying Specific IP Addr. / SANS Alert
From: wailakid
Date: Thu, 03 Aug 2000 00:00
Date: Thu, 03 Aug 2000 00:00
80 lines
3912 bytes
3912 bytes
You have to write deny rules which prohibit those WAN IP addresses from
reaching any of the things that are EXPLICITLY CONFIGURED TO BE ALLOWED
IN. You have to write a specific rule for each server, because the rule
hierarchy, like you said, sometimes works against you.
The example I give below only applies to things on the LAN. You would
probably want to write rules locking them out of DMZ servers too.
By default, it blocks all incoming packets to the LAN. You can
configure exceptions.
Go to ACCESS>Rules. Examine each rule that allows traffic in for a
server on the LAN: look for other things that look like LAN server
configurations:
Example shows a typical NAT-enabled example:
rule 1: allow ping from <* or WAN> to 192.168.2.1 (LAN)
rule 2: allow SMTP from <* or WAN> to 192.168.2.3 (LAN)
rule 3: allow POP3 from <* or WAN> to 192.168.2.3 (LAN)
rule 4: allow HTTP from <* or WAN> to 192.168.2.2 (LAN)
rule 5: allow PCAnywhere from <* or WAN> to 192.168.2.200 (LAN)
The rules to block certain IP ranges from these servers would look like
this:
Example shows how to block access to your servers from IP addresses
in the 209.8.7.0 /24 (255.255.255.0) network:
rule 1: deny ping from 209.8.7.1-254 <WAN> to 192.168.2.1 (LAN)
rule 2: deny SMTP from 209.8.7.1-254 <WAN> to 192.168.2.3 (LAN)
rule 3: deny POP3 from 209.8.7.1-254 <WAN> to 192.168.2.3 (LAN)
rule 4: deny HTTP from 209.8.7.1-254 <WAN> to 192.168.2.2 (LAN)
rule 5: deny PCAnywhere from 209.8.7.1-254 <WAN> to 192.168.2.200 (LAN)
Analysis:
SonicWall rules are sorted by hierarchy: general rules on the bottom
and exceptions to those rules on the top. The deny rules above are
exceptions to the general rules allowing access to servers. All of the
5 deny rules in the example would appear above all of those 5 allow
rules, when viewed on the ACCESS>Rules screen.
Why doesn't it work if you write a rule that says:
rule x: deny default from 209.8.7.1-254 <WAN> to LAN ?
Because the rule hierarchy scheme is based on three different criteria:
range of IP addresses specifed on either source or destinaton side
range of services or port number ranges referenced in the rule.
Look at the example allow rules again.
This deny default rule wouldn't be honored because the allow rules are
seen as 'exceptions' granted for specific protocols (HTTP, SMTP, POP3,
ping, and PCAnywhere) to be accessible on the LAN for everybody on the
WAN.
Finally, the bottom rule should never be erased. Make sure you see it
down there:
deny default from * to LAN
This rule is the heart of the SonicWall's protection against port scans,
etc. FYI: The 'Default service' means all TCP, UDP and ICMP traffic.
Sent via Deja.com http://www.deja.com/
Before you buy.
Technical Details
Message-ID:
<8mav6u$2qa$1@nnrp1.deja.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<8m7o3t$mmu$1@nnrp1.deja.com> <gv0fos02a73penkifb0lv59ta8vfrvk7uk@4ax.com> <en3fosspit77n464pvr40f92h6ifltl1lg@4ax.com> <8m98tm$p13$1@nnrp1.deja.com> <001d2e5a.4e9f3c1c@usw-ex0107-055.remarq.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f922c,602fe67568b54f83 X-Google-Attributes: gidf922c,public X-Google-Thread: 10ed20,f4a947a9a53b2fbd,start X-Google-Attributes: gid10ed20,public X-Google-Thread: 102e85,f4a947a9a53b2fbd,start X-Google-Attributes: gid102e85,public From: wailakid@my-deja.com Subject: Re: SonicWall Rule Denying Specific IP Addr. / SANS Alert Date: 2000/08/03 Message-ID: <8mav6u$2qa$1@nnrp1.deja.com> X-Deja-AN: 653881401 References: <8m7o3t$mmu$1@nnrp1.deja.com> <gv0fos02a73penkifb0lv59ta8vfrvk7uk@4ax.com> <en3fosspit77n464pvr40f92h6ifltl1lg@4ax.com> <8m98tm$p13$1@nnrp1.deja.com> <001d2e5a.4e9f3c1c@usw-ex0107-055.remarq.com> X-Http-Proxy: 1.0 x68.deja.com:80 (Squid/1.1.22) for client 209.239.190.27 Organization: Deja.com - Before you buy. X-Article-Creation-Date: Thu Aug 03 05:16:16 2000 GMT X-MyDeja-Info: XMYDJUIDwailakid Newsgroups: comp.security.firewalls,mail.firewalls,fa.firewall X-Http-User-Agent: Mozilla/4.05 (Macintosh; I; PPC, Nav)