cvs: php4 /sapi/apache mod_php4.c
| From: | Rasmus Lerdorf | Date: | Wed, 05 Jul 2000 18:02:43 +0000 |
| Subject: | cvs: php4 /sapi/apache mod_php4.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-629@lists.php.net to get a copy of this message | ||
rasmus Wed Jul 5 11:02:43 2000 EDT
Modified files:
/php4/sapi/apache mod_php4.c
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
@- 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)
Index: php4/sapi/apache/mod_php4.c
diff -u php4/sapi/apache/mod_php4.c:1.54 php4/sapi/apache/mod_php4.c:1.55
--- php4/sapi/apache/mod_php4.c:1.54 Fri Jun 30 10:39:21 2000
+++ php4/sapi/apache/mod_php4.c Wed Jul 5 11:02:42 2000
@@ -17,7 +17,7 @@
| PHP 4.0 patches by Zeev Suraski <zeev@zend.com> |
+----------------------------------------------------------------------+
*/
-/* $Id: mod_php4.c,v 1.54 2000/06/30 17:39:21 rasmus Exp $ */
+/* $Id: mod_php4.c,v 1.55 2000/07/05 18:02:42 rasmus Exp $ */
#define NO_REGEX_EXTRA_H
#ifdef WIN32
@@ -399,6 +399,8 @@
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;