# how can I install squid transparent way?



## Gerardo (Mar 1, 2009)

I installed squid but I can not do that operate transparent as I can do to make it work well?


----------



## mickey (Mar 1, 2009)

Have a look at these:

http://www.deckle.co.za/squid-users-guide/Transparent_Caching/Proxy
http://wiki.squid-cache.org/SquidFaq/InterceptionProxy


----------



## DutchDaemon (Mar 1, 2009)

It is explained unequivocally (and transparently) in the /usr/local/etc/squid/squid.conf.default file, really.


----------



## DutchDaemon (Mar 1, 2009)

By the way, did you pick the correct tranparent option in make config?


----------



## Gerardo (Mar 5, 2009)

yes transparts is active my network is:



CableModem (10.X.X.X)

         |

FreeBSD / Proxy (192.168.0.1)

         |

Linksys with DD-WRT (192.168.1.1)

         |

   Clients (192.168.1.X)


my clients no have ineternet conexion only with set proxy settings


----------



## DutchDaemon (Mar 5, 2009)

What firewall settings are you using to redirect traffic to the proxy?


----------



## Gerardo (Mar 5, 2009)

my rules is! 

IPFW=/sbin/ipfw

${IPFW} -f flush
${IPFW} add 60000 permit ip from any to any
${IPFW} add 100 fwd 192.168.0.1,3128 tcp from any to any 80 recv xl0

rl0 = conected to cablemodem
xl0 = conected to local network


----------



## DutchDaemon (Mar 5, 2009)

I advise you to run the proxy on localhost:3128 (http_port 127.0.0.1:3128 transparent) and redirect to there. I don't use ipfw myself, so someone else will have to step in to check the validity. Using pf it is simple enough:


```
rdr on $int_if proto tcp from any to any port 80 -> 127.0.0.1 port 3128
```


----------



## Gerardo (Mar 5, 2009)

of which another way I can redirect the traffic? 



what you recommend to me?


----------



## DutchDaemon (Mar 5, 2009)

I'm sure ipfw is as fine as anything; I just haven't used it in a long long while.


----------



## Gerardo (Mar 5, 2009)

it will try if it works


----------



## Gerardo (Mar 5, 2009)

that optional configurations I must to him add to kernel?


----------



## DutchDaemon (Mar 5, 2009)

:q Sorry?


----------



## DutchDaemon (Mar 5, 2009)

http://wiki.squid-cache.org/ConfigExamples/Intercept/FreeBsdIpfw

You may need to use 'intercept' instead of 'transparent' (Squid 3.1 / IPFW)


----------



## Gerardo (Mar 7, 2009)

it wOrks ThAnks!!!


----------



## cktan981212 (Jun 26, 2009)

Squid in Freebsd is not really support for true transparent proxy. Linux did.


----------



## SirDice (Jun 26, 2009)

cktan981212 said:
			
		

> Squid in Freebsd is not really support for true transparent proxy. Linux did.



What makes you say that?


----------



## DutchDaemon (Jun 26, 2009)

Bullshit. FreeBSD is Squid's reference platform! I've configured Squid transparently on gateways, bridges, and weird hybrid setups. It works flawlessly. Period.


----------



## cktan981212 (Jun 27, 2009)

DutchDaemon said:
			
		

> Bullshit. FreeBSD is Squid's reference platform! I've configured Squid transparently on gateways, bridges, and weird hybrid setups. It works flawlessly. Period.



In freebsd you can't archive true transparent proxy this is the fact. It was transparent to the client but not to the destination server. For example, if you try to query google.com, google will not see your IP but your squid IP address. Where else in Linux you can archive the true transparent for both client and server and it is only supported in linux. You may google around and see. I've 3 squids serving for thousand of the users for years. Just to share with you.


----------

