[squid-users] Content Adaptation in Reverse proxy mode
squid3 at treenet.co.nz
Thu Aug 13 10:12:23 UTC 2015
On 13/08/2015 7:02 p.m., joseph jose wrote:
> I have configured squid reverse proxy with eCAP modules.
> I have a client machine in which host file is edited and for
> domain in reverse proxy), it will point to squid reverse proxy machine.
Okay so far.
> What i basically do is like i will append the request url to the cached
> domain url and send it to squid.
No. Just, No.
That is not how HTTP proxying works.
> From client machine if i request www.wiki.org i will send
No. No you will not.
If you request www.wiki.org, you will request http://www.wiki.org/....
If you request www.squid.com, you will request http://www.squid.com/...
"www.squid.com/?url=..." is a request for content from www.squid.com. No
matter what follows the "url=" part.
> so that host file of client will resolve
> and send this to squid reverse proxy machine. From eCAP i will trim the
> first part and take www.wiki.org.
> Say wiki.org is denied, from eCAP i will send back response
> (denied/allowed)back to client.
Take a huge step back and please start by and answering the question:
It is by far away one of the *worst* designs for proxying possible. HTTP
provides specification compliant proxying *natively*.
So WHY ?
> My problem is eCAP modules are loading and working as expected(checked by
Yes. Things working properly is *the problem*. Right. Only when you are
trying to force sftware to do a role it is explicitly designed *not* to do.
In this case Squid is not a web server, it is a proxy.
> But squid always sending server response apache/CentOS not my custom
> response back to the client machine.
More information about the squid-users