At 03:07 PM 02/05/00 +0100, Rene' Seindal wrote:
>Below is a small test program, which manages to send back a 401 response
>to get the browser to prompt for a password, and to extract the username
>and password on the following request. The program works as expected,
>except that the entries in the access_log give a status code of 200 for
>both requests, even though the first returns a 401.  I have tested with
>lynx -trace and manually, and the servers does reply with a 401, only it
>logs a 200.
>       print $q->header(-type=>'text/plain',
>                        -nph=>1,
>                        -status=>'401 Unauthorized',
>                       -WWW_Authenticate=>'Basic realm="hej"');

Instead of the above, try setting $r->status(AUTH_REQUIRED) and then call
exit.

There's also the special %>s custom log format.  Check that out in the
Apache docs, but I'm not sure if it will work here.


Bill Moseley
mailto:[EMAIL PROTECTED]

Reply via email to