cvs: php4 /sapi/thttpd thttpd.c
| From: | Sascha Schumann | Date: | Fri, 27 Oct 2000 10:19:07 +0000 |
| Subject: | cvs: php4 /sapi/thttpd thttpd.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-2290@lists.php.net to get a copy of this message | ||
sas Fri Oct 27 03:19:07 2000 EDT
Modified files:
/php4/sapi/thttpd thttpd.c
Log:
Use php_handle_auth_data
Index: php4/sapi/thttpd/thttpd.c
diff -u php4/sapi/thttpd/thttpd.c:1.24 php4/sapi/thttpd/thttpd.c:1.25
--- php4/sapi/thttpd/thttpd.c:1.24 Wed Oct 11 12:40:56 2000
+++ php4/sapi/thttpd/thttpd.c Fri Oct 27 03:19:06 2000
@@ -241,22 +241,7 @@
SG(request_info).auth_user = NULL;
SG(request_info).auth_password = NULL;
- if (TG(hc)->authorization[0] != '\0'
- && strncmp(TG(hc)->authorization, "Basic ", 6) == 0) {
- char *pass;
- char *user;
-
- user = php_base64_decode(TG(hc)->authorization + 6, strlen(TG(hc)->authorization) - 6,
NULL);
- if (user) {
- pass = strchr(user, ':');
- if (pass) {
- *pass++ = '\0';
- SG(request_info).auth_user = user;
- SG(request_info).auth_password = estrdup(pass);
- } else
- efree(user);
- }
- }
+ php_handle_auth_data(TG(hc)->authorization SLS_CC);
TG(post_off) = TG(hc)->read_idx - TG(hc)->checked_idx;