General Support - squid, iptables LRC - 05.06.2006, 01:51 Uhr Titel: squid, iptables
I am trying to setup dansguardian which needs squid. I have squid to listen on port 3128 and use ip 127.0.0.1. I thought I cut/pasted the iptable instructions correctly , and squid is up and running, but when I configure browsers for 127.0.0.1 3128 nothing happens. Is there any way to find out what is going in the iptables, or is there a way to start with a clean slate and reimput the commands in case a conflict was imputted by mistake? (Me cause conflicts, I just wreck haveck, so that I can have the joy of doing everything all over from scratch, after all that is sooo much fun.)
ironwalker - 05.06.2006, 02:05 Uhr Titel: RE: squid, iptables
May want to try looking in access.log in /var/log/squid.
It might tell ya what ya need.
shame - 05.06.2006, 11:55 Uhr Titel:
What do you mean by nothing happens, do you mean dansguardian isn't blocking anything?
If you are using dansguardian you would want to point your browser to the port dansguardian is listening to (8080 or something), by pointing the browser to the port squid is listening to it is bypassing dansguardian.
ironwalker - 05.06.2006, 21:34 Uhr Titel:
I am not useing dansguardian myself but what shame mentions makes sense.My squid proxy is on my firewall box and even though its the standard port you are useing my browser uses 800 for use of the proxy.
LRC - 06.06.2006, 06:14 Uhr Titel:
I am trying to make Dansguardian run ontop of squid, but when I try to start DG I get Restarting DansGuardian: Error connecting to parent proxy. Now I have read that if squid is setup right without any filter ontop of it, if you point your browser to the reroute (127.0.0.1:3128) you should get through and a log of what is going on will appear in access.log. Well I setup squid as directed and setup the iptables as directed and no access to internet and nothing shows up in access.log. here is both what I did in konsole and squid and DG. There has to be an answer out there somewhere, I am a newbie to Linux, but I have visited dozens of sites, they all say basically the same thing, but I must be missing something or have something else configured wrong, because although squid is loaded, it is not doing anything. Is their anyone who knows something that can help. This is the first time I have come across anything that no one seems to know the answer.
# iptables -F
# iptables -X
# iptables -t nat -F
# iptables -t nat -X
# iptables -t mangle -F
# iptables -t mangle -X
# iptables -t nat -A OUTPUT -p tcp --dport 80 -m owner --uid-owner squid -j ACCEPT
# iptables -t nat -A OUTPUT -p tcp --dport 3128 -m owner --uid-owner squid -j ACCEPT
# iptables -t nat -A OUTPUT -p tcp --dport 80 -j REDIRECT --to-ports 8080
# iptables -t nat -A OUTPUT -p tcp --dport 3128 -j REDIRECT --to-ports 8080
# iptables-save > /etc/sysconfig/iptables
# /etc/init.d/squid restart
Restarting Squid HTTP proxy: squid.
# /etc/init.d/dansguardian restart
Restarting DansGuardian: Error connecting to parent proxy