On 03.05.2011 00:13, Ben Noordhuis wrote:
On Mon, May 2, 2011 at 20:51, Hardy Griech<[email protected]>  wrote:
Now my concern is, how can I reliably catch the condition that the
connection has been initiated by mod_proxy.  Any ideas?

r->proxyreq != PROXYREQ_NONE? Does 'initiated' mean 'request from an
external reverse proxy' or 'request handled by mod_proxy'?

Sorry, I forgot to mention that the code is in the pre-connection hook. So no proxyreq available :-(

Also my previous patch does not work, if the destination server is on another machine.

Currently I'm checking (c->sbh == NULL) to detect the mod_proxy request (yes, I meant a mod_proxy request).

In mod_ssl they seem to have a similar problem with mod_proxy: mod_proxy calls some mod_ssl functions (ssl_proxy_enable() and ssl_engine_disable()) to signal a request handled by mod_proxy.

I've tried to implement also these two functions - without success, they are never called also I've tried to register them just like mod_ssl does (mod_ssl is not loaded BTW).

Anyone has an idea how to correctly detect a proxy handled connection?

Thanks

Hardy

Reply via email to