p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

beginning_php thread: Proxy Servers


Message #1 by "KayKay-GG \(E-mail\)" <kaykay@g...> on Fri, 20 Sep 2002 20:11:57 +0530
Hey there,
	How can you find out whether a user to your site is behind a proxy server
or not...? Or in better words... if a user visiting your site is behind a
proxy server, how can you log his original IP? I thought it was impossible
but I've seen a few sites that log your actual IP...
TIA,
:)
-K
P.S I suppose this also depends on how anonymous the proxy is.... but just
wondering :)



Message #2 by "KayKay-GG \(E-mail\)" <kaykay@g...> on Sat, 21 Sep 2002 10:17:25 +0530
Well... I found a  site that does this: http://www.showmyip.com/
Any ideas how they do it? I assume it's an in-built function.. but I don't
have a clue what it is...

TIA
-K

>>>>-----Original Message-----
>>>>From: KayKay [mailto:kkumar@b...]On Behalf Of
>>>>KayKay-GG (E-mail)
>>>>Sent: 20 September 2002 20:12
>>>>To: beginning php
>>>>Subject: [beginning_php] Proxy Servers
>>>>
>>>>
>>>>Hey there,
>>>>	How can you find out whether a user to your site is
>>>>behind a proxy server
>>>>or not...? Or in better words... if a user visiting your
>>>>site is behind a
>>>>proxy server, how can you log his original IP? I thought it
>>>>was impossible
>>>>but I've seen a few sites that log your actual IP...
>>>>TIA,
>>>>:)
>>>>-K
>>>>P.S I suppose this also depends on how anonymous the proxy
>>>>is.... but just
>>>>wondering :)



Message #3 by "Nikolai Devereaux" <yomama@u...> on Mon, 23 Sep 2002 11:51:04 -0700
> Well... I found a  site that does this: http://www.showmyip.com/
> Any ideas how they do it? I assume it's an in-built function.. but I don't
> have a clue what it is...

FYI, the IP that this site shows me is the IP address of my router/firewall.
The only thing you really have access to is, i belive, $_SERVER['REMOTE_ADDR'].


take care,

nik

Message #4 by "KayKay-GG \(E-mail\)" <kaykay@g...> on Tue, 24 Sep 2002 02:04:44 +0530
Good timing :) I finally got off my arse and searched the web for some
answers and came with the same thing - but it doesn't seem to work all the
time though - A more "reliable" option I found was
_SERVER[HTTP_X_FORWARDED_FOR] - That seems to do teh trick everytime :) Just
curious why most access loggers don't use it *shrug*
Thanks for the reply :)
-K

>>>>-----Original Message-----
>>>>From: Nikolai Devereaux [mailto:yomama@u...]
>>>>Sent: 24 September 2002 00:21
>>>>To: beginning php
>>>>Subject: [beginning_php] RE: Proxy Servers
>>>>
>>>>
>>>>
>>>>> Well... I found a  site that does this: http://www.showmyip.com/
>>>>> Any ideas how they do it? I assume it's an in-built
>>>>function.. but I don't
>>>>> have a clue what it is...
>>>>
>>>>FYI, the IP that this site shows me is the IP address of my
>>>>router/firewall.
>>>>The only thing you really have access to is, i belive,
>>>>$_SERVER['REMOTE_ADDR'].
>>>>
>>>>
>>>>take care,
>>>>
>>>>nik



Message #5 by "KayKay-GG \(E-mail\)" <kaykay@g...> on Tue, 24 Sep 2002 02:07:57 +0530
oh and _SERVER[HTTP_VIA] gives details about the proxy type etc. (for those
who are interested:)
-K

>>>>-----Original Message-----
>>>>From: Nikolai Devereaux [mailto:yomama@u...]
>>>>Sent: 24 September 2002 00:21
>>>>To: beginning php
>>>>Subject: [beginning_php] RE: Proxy Servers
>>>>
>>>>
>>>>
>>>>> Well... I found a  site that does this: http://www.showmyip.com/
>>>>> Any ideas how they do it? I assume it's an in-built
>>>>function.. but I don't
>>>>> have a clue what it is...
>>>>
>>>>FYI, the IP that this site shows me is the IP address of my
>>>>router/firewall.
>>>>The only thing you really have access to is, i belive,
>>>>$_SERVER['REMOTE_ADDR'].
>>>>
>>>>
>>>>take care,
>>>>
>>>>nik




  Return to Index