Forum Moderators: phranque

Message Too Old, No Replies

AOL and bogus IP addresses

Aol Users Unique ip Address

         

exclick

9:22 pm on May 30, 2003 (gmt 0)

10+ Year Member



AOL STATEMENT:
Q. Can I use the IP address of the request to track a member's access to my site?

A. No. Because AOL uses proxy servers to service the requests made by members, webmasters see the IP address of the gr server, not the DAHA of the member in their web site log files. The problem with trying to use the IP address to track access is that there may easily be multiple members assigned to a proxy server. All of the member requests would appear to be coming from one member if you assumed a relationship between member and IP address. In addition, members may be reassigned to a different proxy server during a session. See also Network Info.
reference: [webmaster.info.aol.com...]

NOW HERE'S MY QUESTION:

I have a website with 10,000 users and am using
$my_variable = $ENV{REMOTE_ADDR};
to differentiate between users at login time, as well as to report (who's) online at a given time....

Unfortunately, AOL, COMPUSERV AND WEBTV don't seem to provide a true IP address unique to each user... The result is that AOL users are not able to LOGIN to my site.....

SO do you know of another PERL language CGI command, or variable that I can reference that is common and always available from Netscape, IE, AOL, COMPUSERV etc.? - other than cookies .........

bdp / exclick /

bcolflesh

9:25 pm on May 30, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



IMHO it is a recipe for disaster to rely on that info - too easily faked... Why not use a username/password/session combo?

Regards,
Brent

pixel_juice

9:27 pm on May 30, 2003 (gmt 0)

10+ Year Member



IMO, you need to use cookies and not IP addresses to track a unique user. AOL are not the only ISP using proxies with ridiculous numbers of IP addresses (one for each request).

jdMorgan

9:28 pm on May 30, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You might want to look into the {HTTP_PROXY_CONNECTION} and {HTTP_FORWARDED} variables, too.

I have not done so myself, but maybe it'll be useful.

Jim

exclick

12:45 am on Jun 14, 2003 (gmt 0)

10+ Year Member



I appreciate the advice... in fact, I've taken the advice and have modified a cookie cgi that will solve my problem... THANK YOU!

.... however, now I have another question... This cookie file works fine with Mozilla and Netscape, however, with IE, I have not been able to get it to work...

In NETSCAPE, I type in a name... say, BOB...
when I run the (get cookie) it returns:

Hello BOB! See, I remembered your name!

When I run the same code on IE, it returns,

The cookie must have expired...

********************************************************
HERE'S MY QUESTION: code works fine in Netscape and Mozilla.
Why doesn't the code work in IE - which is configured to accept cookies...
********************************************************

Here is a copy of the code for anyone who has solutions ...

THE GET COOKIE FILE:
####################

#!/usr/bin/perl -w
# cookie-get.cgi - fetch the value of a cookie
use CGI qw(:standard);

$name = cookie("username");
my $ipaddy = $name;
print "<p><b>The ipaddy swiped from comments of the cookie.html file...:</b> $ipaddy\n";
print
header(),
start_html("Hello $name"),
h1("Hello " . $name ¦¦ "Stranger");
if ($name) {
print p("See, I remembered your name!");
} else {
print p("The cookie must have expired.");
}
print end_html();

### END ###

SET COOKIE FILE
###############
#!/usr/bin/perl -w
# cookie-set.cgi - set a cookie

use CGI qw(:standard);

unless (param()) {
# display form
print
header(),
start_html("Cookie Baker"),
h1("Cookie Baker"),
start_form(),
p("What's your name?", textfield("NAME")),
submit(),
end_form(),
end_html();
# cookie-set.cgi will be continued ...

#Setting a cookie is a two-part process: first, create it with the cookie() function, then pass it to the browser when you send the HTTP header. In the remaining code, $to_set holds the cookie we create, and the -cookie argument to the header() function passes it to the browser.

# cookie-set.cgi continues ...
} else {
# process form and set cookie
$name = param("NAME");
$to_set = cookie(-name => "username",
-value => $name,
-expires => "+59s",
# -path => "/survey/surveybin",
-path => "/",
);
print
header(-cookie => $to_set),
start_html("Thanks!"),
h1("Thanks for using the Cookie Baker"),
p("I set your name to ", b($name),
" and I will remember this if you visit ",
a({-href => "cookie-get.cgi"}, "here"),
" within the next 59 seconds."),
end_html();
}

Mike_Mackin

8:46 am on Jun 14, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



This is the Overture Pay Per Click fora!

>moving this thread to FOO

exclick

12:46 pm on Jun 14, 2003 (gmt 0)

10+ Year Member



Regarding:

This is the Overture Pay Per Click fora!

========================================

And so what does this mean?

This is where I located the original code:
[webbuilder.netscape.com...]

Although it works on Netscape, I don't know why it won't set a cookie on IE.

:)

Mike_Mackin

12:54 pm on Jun 14, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld exclick

You posted in the Overture forum and I moved it to Foo. After some discussion between the Moderatores it was moved to Website Technology Issues.