PIX 506 blocking access to specific outside IP addresses

Posted on 2004-10-21
Last Modified: 2010-04-09
We have a PIX 506. We are for testing purposes trying to either block whole IP ranges or subnets. Our PIX currently works well for what we need. In a few weeks or so we are going to need to start blocking websites that employees are visiting during work hours (browsing is allowed but is being abused)
My users are computer savy and have figured out how to bypass the W2K proxy server.

1. The first thing I tried was to block a users computer IP address from being able to access any IP addresses outside. This would force them to go through the proxy which is permitted to get  to the outside. I could not figure this out (I am in over my head :-) )

2. I am now trying to block whole ranges of IP addresses and would like to redirect the user to a default page e.g.

Please take a look at my config and let me know where I am am going wrong. I have marked the areas in question with "--->"
Also if there are thing that I can do to streamline my config I would love to get ay pointers.




Running config

Building configuration...
: Saved
PIX Version 6.3(3)
interface ethernet0 10baset
interface ethernet1 10baset
nameif ethernet0 outside security0
nameif ethernet1 inside security100
enable password 9kMLrOeFU.sbene6 encrypted
passwd 1wx2wOiaRQlEVJZQ encrypted
hostname ALI-pix
clock timezone CST -6
clock summer-time CDT recurring
fixup protocol dns maximum-length 512
fixup protocol ftp 21
fixup protocol h323 h225 1720
fixup protocol h323 ras 1718-1719
fixup protocol http 80
fixup protocol rsh 514
fixup protocol rtsp 554
fixup protocol sip 5060
fixup protocol sip udp 5060
fixup protocol skinny 2000
fixup protocol smtp 25
fixup protocol sqlnet 1521
fixup protocol tftp 69
---> name wlee
name xanga
name gizmo
name xangablock2
name xanga3
name xanga4
name xanga5
name julie
name xang
name google
access-list 100 permit ip xang
access-list 100 permit tcp any any
access-list 100 permit icmp any any
access-list 100 permit tcp any host eq 3389
---->access-list 100 deny ip host wlee any
---->access-list 100 deny tcp any google eq www
access-list 120 permit ip
access-list inside_cryptomap_dyn_20 permit ip any
pager lines 24
logging on
mtu outside 1500
mtu inside 1500
ip address outside
ip address inside
ip audit info action alarm
ip audit attack action alarm
ip local pool ippool
pdm location inside
pdm location inside
pdm location julie inside
pdm location inside
pdm location outside
pdm location inside
pdm location inside
pdm location inside
pdm location wlee inside
pdm location wlee outside
pdm location gizmo inside
pdm location xanga inside
pdm location xang inside
pdm location xangablock2 inside
pdm location xanga3 inside
pdm location xanga4 inside
pdm location xanga5 inside
pdm location julie outside
pdm location google inside
pdm history enable
arp timeout 14400
global (outside) 1 interface
nat (inside) 0 access-list 120
nat (inside) 1 0 0
static (inside,outside) tcp interface 3389 3389 netmask 0 0
static (inside,outside) google google netmask 0 0
access-group 100 in interface outside
route outside 1
route outside wlee 1
timeout xlate 3:00:00
timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 rpc 0:10:00 h225 1:00:00
timeout h323 0:05:00 mgcp 0:05:00 sip 0:30:00 sip_media 0:02:00
timeout uauth 0:05:00 absolute
aaa-server TACACS+ protocol tacacs+
aaa-server RADIUS protocol radius
aaa-server LOCAL protocol local
http server enable
http julie inside
http inside
http inside
http inside
no snmp-server location
no snmp-server contact
snmp-server community public
no snmp-server enable traps
tftp-server inside /tftp-root
floodguard enable
sysopt connection permit-ipsec
crypto ipsec transform-set myset esp-des esp-md5-hmac
crypto dynamic-map dynmap 10 set transform-set myset
crypto dynamic-map inside_dyn_map 20 match address inside_cryptomap_dyn_20
crypto dynamic-map inside_dyn_map 20 set transform-set myset
crypto map mymap 10 ipsec-isakmp dynamic dynmap
crypto map mymap interface outside
crypto map inside_map 65535 ipsec-isakmp dynamic inside_dyn_map
crypto map inside_map interface inside
isakmp enable outside
isakmp identity address
isakmp policy 10 authentication pre-share
isakmp policy 10 encryption des
isakmp policy 10 hash md5
isakmp policy 10 group 2
isakmp policy 10 lifetime 65534
vpngroup vpn3000 address-pool ippool
vpngroup vpn3000 dns-server
vpngroup vpn3000 default-domain
vpngroup vpn3000 idle-time 1800
vpngroup vpn3000 password ********
vpngroup vbumhira address-pool ippool
vpngroup vbumhira dns-server
vpngroup vbumhira default-domain
vpngroup vbumhira idle-time 1800
vpngroup vbumhira password ********
telnet outside
telnet inside
telnet inside
telnet timeout 5
ssh timeout 5
console timeout 0
terminal width 80
: end

Question by:optidigix
    LVL 79

    Expert Comment

    To prevent them from bypassing the proxy, simply add this :

      access-list inside_out permit ip host <proxy ip> any
      access-group inside_out in interface inside

    You might want to look at WebSense, N2H2, or iPrism for internet control.
    I think iPrism is the most cost-effective solution -

    LVL 79

    Expert Comment

    Or, if you just want to deny certain hosts:
     >name wlee

    access-list inside_out deny ip host wlee any
    access-list inside_out permit ip any any
    access-group inside_out in interface inside


    Author Comment

    Thank. I applied the config to deny certain inside_out to a specific ip address on our network. It works perfectly. I am weary about applying the config to prevent all machines from bypassing the proxy as there are a few that I have to have connected directly to the Internet (Linux boxes being used for security testing)

    Would the following config work (test blocking google)

    access-list inside_out deny ip host any any
    access-list inside_out permit ip any any
    access-group inside_out in interface inside

    I am also going to look into iPrism. Thanks you very much.
    LVL 79

    Accepted Solution


    >access-list inside_out deny ip host any any

    Should be:
        access-list inside_out deny ip any


    Author Comment

    thank you very much

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Wikipedia defines 'Script Kiddies' in this informal way: "In hacker culture, a script kiddie, occasionally script bunny, skiddie, script kitty, script-running juvenile (SRJ), or similar, is a derogatory term used to describe those who use scripts or…
    This article offers some helpful and general tips for safe browsing and online shopping. It offers simple and manageable procedures that help to ensure the safety of one's personal information and the security of any devices.
    In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

    884 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now