On Tue, Mar 11, 2008, Niels Provos wrote:
> On Mon, Mar 10, 2008 at 6:24 AM, Lyes Amazouz <[EMAIL PROTECTED]> wrote:
> > I want to know if there is a mean to access the socket descriptor associated
> > with the evhttp_connection object (the field fd i guess), because I want to
> > use it as a key for a hash function.
> >  instead of this, can the server specify, for each client, an independent
> > user environment either the argument given when we set the callback
> > functions of the server object?
> 
> I guess I do not quite understand what you are trying to accomplish.
> In most cases, you will get a different fd for each connection.
> Perhaps, you could explain the reason for hashing on something?  Why
> don't you hash on the remote IP?

I can think of one particular reason - Squid implements "pinned" connections
which pin particular client connections to particular server connections.
This allows for things such as NTLM support to function, which assumes
the underlying connection between client and server stays linked for
the lifetime of the connection.

This upsets normal proxy semantics and, at least in the old Squid versions,
you could probably hijack an NTLM session like this as Squid used to treat
all connections to a remote host as equivalent for selecting persistent 
connections.

2c,


Adrian

-- 
- Xenion - http://www.xenion.com.au/ - VPS Hosting - Commercial Squid Support -
- $25/pm entry-level VPSes w/ capped bandwidth charges available in WA -
_______________________________________________
Libevent-users mailing list
Libevent-users@monkey.org
http://monkeymail.org/mailman/listinfo/libevent-users

Reply via email to