[PLUG] REMOTE_USER
Randal L. Schwartz
merlyn at stonehenge.com
Tue May 13 03:11:02 UTC 2003
>>>>> "Billy" == Billy Dimaculangan <bmdimaculangan at bhpi.com.ph> writes:
Billy> Were running our intranet on Linux web server, I was task
Billy> to monitor the users that are accessing the page. I already
Billy> got the IP add, and the url the client is browsing but not the
Billy> REMOTE_USER. I used perl cgi to this, but the REMOTE_USER
Billy> variable always ends up empty. The remote client OS is
Billy> windows, how do I capture the windows user via perl? Is this
Billy> possible
.
REMOTE_USER will be empty unless the script is protected by some
authentication step. Have you protected the script with something
like "BasicAuth"?
And, it has nothing to do with the "remote" "user". It's just the
name of the user as authenticated to the webserver. If you've visited
a web site, gotten a pop-up box that described a "realm" and wanted a
"username" and "password", it's like that.
If you're creating a new application, "BasicAuth" while being simple,
basically sucks. Since you're hacking Perl, look at my article at
<http://www.stonehenge.com/merlyn/WebTechniques/col61.html> on how to
do proper login/logout with simple cookies.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn at stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
More information about the PLUG
mailing list