Linux Netfilter discussions
 help / color / mirror / Atom feed
* Transparent proxy single machine question
@ 2004-06-26 21:24 ken scott
  2004-06-26 21:51 ` Dimitar Katerinski
  0 siblings, 1 reply; 7+ messages in thread
From: ken scott @ 2004-06-26 21:24 UTC (permalink / raw)
  To: netfilter

I am trying to build a single machine that  performs web filtering
(using DansGuardian)  for several users.
The box (Morphix/Debian system) will be behind a cable router and has
five users (kids).
I have running Dansguardian and Squid correctly in normal proxy mode.
The next step is to make the proxy transparent
so that users cannot bypass the Danguardian/squid path simply by telling
their browser to connect directly.
I have looked around and see instructions on this at several places
(mostly for non-single machine implementations)
and know I need a line something like like:

iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8181

       where 8181 is where Dansguardian is listening.

I also need to configure squid with (I think) :

http_port 3128     # where squid is listening
httpd_accel_host virtual
httpd_accel_port 80
httpd_accel_with_proxy  on
httpd_accel_uses_host_header on
httpd_accel_single_host off

The question is, on a single machine, will this work?
The part I can't figure out pertains to when squid finally wants to send 
out the actual
request to the internet, isn't that a port 80 request that the above 
iptables rule will
redirect back to Dansguardian??
Please reply all as I am not quite sure than I have joined the list 
correctly.
Thanks in advance
Ken S.







^ permalink raw reply	[flat|nested] 7+ messages in thread
* Transparent proxy single machine question
@ 2004-06-26 21:14 ken scott
  0 siblings, 0 replies; 7+ messages in thread
From: ken scott @ 2004-06-26 21:14 UTC (permalink / raw)
  To: netfilter

I am trying to build a single machine that  performs web filtering 
(using DansGuardian)  for several users.
The box (Morphix/Debian system) will be behind a cable router and has 
five users (kids).  
I have running Dansguardian and Squid correctly in normal proxy mode.  
The next step is to make the proxy transparent
so that users cannot bypass the Danguardian/squid path simply by telling 
their browser to connect directly.
I have looked around and see instructions on this at several places 
(mostly for non-single machine implementations)
and know I need a line something like like:

 iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8181

       where 8181 is where Dansguardian is listening.

I also need to configure squid with (I think) :

 http_port 3128     # where squid is listening
 httpd_accel_host virtual
 httpd_accel_port 80
 httpd_accel_with_proxy  on
 httpd_accel_uses_host_header on        //
 httpd_accel_single_host off

The question is, on a single machine, will this work?  
The part I can't figure out pertains to when squid finally wants to send out the actual
request to the internet, isn't that a port 80 request that the above iptables rule will 
redirect back to Danguardian??
Please reply all as I am not quite sure than I have joined the list correctly.
Thanks in advance
Ken S.


                




                http_port 3128
                httpd_accel_host virtual
                httpd_accel_port 80
                httpd_accel_with_proxy  on
                httpd_accel_uses_host_header on
                

Squid 2.4 needs an /additional/ line added:

                httpd_accel_single_host off
                






^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2004-06-27  1:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-06-26 21:24 Transparent proxy single machine question ken scott
2004-06-26 21:51 ` Dimitar Katerinski
2004-06-26 22:09   ` ken scott
2004-06-26 22:42     ` Dimitar Katerinski
2004-06-27  0:52       ` ken scott
2004-06-27  1:16         ` Dimitar Katerinski
  -- strict thread matches above, loose matches on Subject: below --
2004-06-26 21:14 ken scott

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox