Thanks c, but...
I don't have apache::htpasswd module installed, and as I said above, can't install it. Its not really the crux of the problem anyway, as I can handle parsing the htpasswd file.
What really concerns me is how to capture the username and password entered in the authentication dialog box. I'll explain in a bit more depth:
I activate an authentication dialog box by sending the following HTTP headers, using CGI.pm:
print $query->header('WWW-Authenticate: Basic realm="Private"'),
$query->header('HTTP/1.0 401 Unauthorised');
Now, if I were using PHP (!), the user name and password would be stored in $PHP_AUTH_USER and $PHP_AUTH_PW, which I would then try to match against the htpasswd file.
Also, I use these aforementioned variables in PHP with the isset() function to determine whether the
user has logged in yet.
Anything php can do, Perl can do better?.
Of course a proper implementation of htaccess security would not use isset(), but would send some sort of success message back to the client browser, causing the $REMOTE_USER environment variable to be set. But now I am out of my depth.
Any suggestions, O wise ones?
*~-}hotyopa{-~* |