Tracking Users By IP Address
Nick Craig-Wood
nick at craig-wood.com
Thu Oct 7 12:29:57 EDT 2004
Paul McNett <p at ulmcnett.com> wrote:
> > Some (many? all? negligibly few? I don't know) proxy
> > firewalls will tell you which internal address the request
> > came from, so you can combine the two to get a unique address
> > for that user.
>
> I'd say "negligibly few", since there really isn't good reason
> to give the world your internal ip address. Anyway, you can't
> count on it, and you wouldn't have a basis to know what
> percentage weren't unique.
An awful lot of proxies do do exactly that (I used this technique
before).
HTTP_X_FORWARDED_FOR and REMOTE_ADDR are the headers you want
Its not safe to use this as a unique address for a user but if you are
interested in exactly where your users are (for fraud checking
purposes) its a useful technique.
--
Nick Craig-Wood <nick at craig-wood.com> -- http://www.craig-wood.com/nick
More information about the Python-list
mailing list