Do any of you CGI wizards know why (env "REMOTE_ADDR") in a CGI environment sometimes returns two IP addresses rather than one?
Proxy servers? I don't know. Maybe it's an error :)
I've never seen such a thing. Are you able to elaborate - safely -
without leaving anything open to exploit?
tim
Well, the matching entry in the Apache log is like this:
64.27.13.129, 217.219.95.60 - - [05/Jun/2008:02:17:37 -0700] "POST /comment.cgi HTTP/1.0" 200 59498 ...
- that's a spammer caught in the act of posting some spam. :) My code is using (env REMOTE_ADDR) and therefore picking up two IP addresses ...
Since these double IPs appear a lot in the log, I had presumed they're something well known..
if you always have double IP's then the first is the Apache-Server the second the client.
If you have it randomly it could be a redirect..from source..
Like from google -> destination..
But thats all i know...
What's your apache log format string?
It seems to be this:
clientip - username [time] "request" status bytes "referer" "useragent"
I think your 'proxy server' suggestion is right, Jeff. In that case, which one would identify that user again?
No idea. That was a complete shot in the dark. :)