diff options
author | Rasmus Lerdorf <rasmus@php.net> | 2000-07-05 18:02:42 +0000 |
---|---|---|
committer | Rasmus Lerdorf <rasmus@php.net> | 2000-07-05 18:02:42 +0000 |
commit | f2348a482604595f18a11740d70c0cd587f9336c (patch) | |
tree | 487f0cef82fb39c0dccbae884a92fd93d606cb1d | |
parent | 057264d6ed148d9933b9eb3681911cde7bffd6dc (diff) | |
download | php-git-f2348a482604595f18a11740d70c0cd587f9336c.tar.gz |
When using HTTP auth from PHP, fill in the %u custom log field so the
authenticated used id will get logged in the Apache access_log
@- When using HTTP auth from PHP, fill in the %u custom log field so the
@ authenticated used id will get logged in the Apache access_log (Rasmus)
-rw-r--r-- | sapi/apache/mod_php4.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sapi/apache/mod_php4.c b/sapi/apache/mod_php4.c index eb21b675c7..774769eb04 100644 --- a/sapi/apache/mod_php4.c +++ b/sapi/apache/mod_php4.c @@ -399,6 +399,8 @@ static void init_request_info(SLS_D) tmp = uudecode(r->pool, authorization); SG(request_info).auth_user = getword_nulls_nc(r->pool, &tmp, ':'); if (SG(request_info).auth_user) { + r->connection->user = pstrdup(r->connection->pool,SG(request_info).auth_user); + r->connection->ap_auth_type = "Basic"; SG(request_info).auth_user = estrdup(SG(request_info).auth_user); } SG(request_info).auth_password = tmp; |