Koozali.org: home of the SME Server

ipchains or SquidGuard

John Trombly

ipchains or SquidGuard
« on: January 23, 2002, 04:24:38 AM »
I have a need to dissallow all Internet bound traffic by IP number. I have SquidGuard up and running and it is doing a find job of allowing or dissallowing people who are using their browsers, but I need an On/Off switch that will dissallow all traffic (like TelNet, FTP, ICQ... etc).
I was thinking that an entry into the IPCHAINS would work. One that I want to put in is as follows:

ipchains -A input -s 192.168.1.123/255.255.255.255 -d  216.169.50.2/0.0.0.0 -j DENY

but I do not know where to put this. I have put it in by hand and it does not seem to work. I know that it needs to end up in a template somewhere, but I do not know where.

If someone can point me to a How-to, or give good instructions, I would appreciate it.

nobody

Re: ipchains or SquidGuard
« Reply #1 on: January 23, 2002, 07:36:46 PM »
Yes, add these to your MASQ file:

# Deny ICQ Messaging (login.icq.com, icq.mirabilis.com, www.icq.com)

/sbin/ipchains -A input -b -d 205.188.179.0/24 -j DENY -l

/sbin/ipchains -A input -b -d 64.12.162.0/24 -j DENY -l

/sbin/ipchains -A input -b -d 205.188.153.0/24 -j DENY -l

/sbin/ipchains -A input -b -d 205.188.248.0/24 -j DENY -l

/sbin/ipchains -A input -p TCP -b --sport 4000 -j DENY -l

/sbin/ipchains -A input -p UDP -b --sport 4000 -j DENY -l

# Deny MSN Messaging (messenger.microsoft.com, block port 1863, MSN IP)

/sbin/ipchains -A input -b -d 207.46.183.0/24 -j DENY -l

/sbin/ipchains -A input -p TCP -b --sport 1863 -j DENY -l

/sbin/ipchains -A input -p UDP -b --sport 1863 -j DENY -l

/sbin/ipchains -A input -b -s 64.4.13.0/24 -j DENY -l

 # Deny IRC (Block entire 6660-7001 range)

/sbin/ipchains -A input -p TCP -b --sport 6660:7001 -j DENY -l

/sbin/ipchains -A input -p UDP -b --sport 6667:7001 -j DENY -l