Link to home
Start Free TrialLog in
Avatar of chfong98
chfong98

asked on

Setup Squid as a second gateway for internet traffic

I have a need to separate one VLAN 150 internet traffic from the rest of our network.
It will still need normal traffic for login to the domain and receive updates, etc.
We will apply ACL on the CORE to only let it talk to the Domain Controller's network.

I will setup Squid running on a CentOS box.
The Squid server will have 2NIC, one NIC will be on the WAN side and one NIC will be on VLAN 150 to intercept HTTP, HTTPS,FTP traffic.

I need help setting up Squid to
    1. Intercept HTTP, HTTPS, FTP traffic for VLAN 150
    2. Restrict access to only 2-3 external domains.
I need help in CentOS
    1. To route HTTP, HTTPS, FTP traffic IN/OUT of the server.
    2. Tips on securing the Server from attack.

I think I got it all.
Thank you Experts !!!
Gilbert
HTTP-Separation.jpg
Avatar of arnold
arnold
Flag of United States of America image

If you use a router/switch via WCCP, the squid setup should be in transparent mode.
https should not be redirected since it will be seen as a man in the middle attack warning to the user.

Not sure from whom you want to protect the centos box.

Adding squidGuard to your squid setup you can then define rules to restrict what sites users can access.
Avatar of chfong98
chfong98

ASKER

I was able to get this to work as a test (somewhat).
-------------------------------------------------
in /etc/squid/squid.conf
-------------------------------------------------
acl vlan150 src 192.168.150.0/24
acl goodsites dstdomain .google.com .amazon.com .nba.com
(they are only allowed a few sites)
#
#http_access allow localnet
#http_access allow localhost
#
http_access allow vlan150 goodsites
I CAN INCLUDE THE WHOLE FILE IF YOU NEED TO SEE IT.
-------------------------------------------------
On the client I set the proxy on the browser
We will push a policy to the users on that VLAN to have proxy stick
from the client browser I can hit amazon and can login (skip the HTTPS part)
-------------------------------------------------
I will still need the Routing and NAT for IN/OUT traffic of the SquidBox.
I what to lock down CentOS from the outside.

Thanks
Gilbert
I'm not sure on what you mean by lockdown.  You can get bastille which is a good tool to lockdown linux/unix based servers.

http://bastille-linux.sourceforge.net/
I am just looking for confirmation/fix on my Squid config and some Routing and NAT help.
WILL MY DESIGN WORK??  I AM DIGGING WHILE WAITING.
I am not a Linux expert I can follow along on the Routing, Nating and Squid config.
I can turn off ports that are not needed on the CentOS.

WCCP and recompile the kernel with GRE tunnel support is something that I am not too comfortable with and I don't have too much time to research Bastille time. I will definitely
look into it ones I have more time.


So much fun and so little time.
Much appreciated
Gilbert
There is no need to recompile the kernel, the GRE should already be present.
modprobe -l | grep -i gre
which version of IOS do you have?

Your Centos/Squid box will function as a proxy and not as a router.  This is what puzzled me.
If you want all VLAN 150 traffic to stream through the centos/squid box that it is an entirely different matter.
Sorry,

lets just work on setting up Squid as a forwarding proxy.
we will not have this host on the main network at all.
can you help me with the iptable part?

Thanks
Gilbert
ASKER CERTIFIED SOLUTION
Avatar of arnold
arnold
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial