2 Copyright (C) 2006 OpenWrt.org
4 Index: busybox-1.4.2/networking/httpd.c
5 ===================================================================
6 --- busybox-1.4.2.orig/networking/httpd.c 2007-06-04 13:21:32.190083032 +0200
7 +++ busybox-1.4.2/networking/httpd.c 2007-06-04 13:21:34.401746808 +0200
8 @@ -1402,12 +1402,26 @@
9 if (ENABLE_FEATURE_HTTPD_AUTH_MD5) {
13 + struct passwd *pwd = NULL;
15 if (strncmp(p, request, u-request) != 0) {
20 + if(pp && pp[1] == '$' && pp[2] == 'p' &&
21 + pp[3] == '$' && pp[4] &&
22 + (pwd = getpwnam(&pp[4])) != NULL) {
23 + if(pwd->pw_passwd && pwd->pw_passwd[0] == '!') {
27 + ppnew = xrealloc(ppnew, 5 + strlen(pwd->pw_passwd));
29 + strcpy(ppnew + 1, pwd->pw_passwd);
32 if (pp && pp[1] == '$' && pp[2] == '1' &&
33 pp[3] == '$' && pp[4]) {
35 @@ -1417,6 +1431,10 @@
45 if (strcmp(p, request) == 0) {