Fossil SCM
In http_build_login_card(), send no login card when a sync started from the /xfersetup page has a user name in its URL and no saved password. The missing password was passed on as a null pointer.
Commit
ea6766e3ae748d0d3e96487f45e3755f5a6d530757c1adb0b57876680c4f2cea
Parent
464ec546f1cf9f1…
1 file changed
+3
-1
+3
-1
| --- src/http.c | ||
| +++ src/http.c | ||
| @@ -86,11 +86,13 @@ | ||
| 86 | 86 | if( g.url.passwd ){ |
| 87 | 87 | zPw = g.url.passwd; |
| 88 | 88 | }else if( g.cgiOutput ){ |
| 89 | 89 | /* Password failure while doing a sync from the web interface */ |
| 90 | 90 | cgi_printf("*** incorrect or missing password for user %h\n", zLogin); |
| 91 | - zPw = 0; | |
| 91 | + blob_reset(&pw); | |
| 92 | + blob_reset(&nonce); | |
| 93 | + return; | |
| 92 | 94 | }else{ |
| 93 | 95 | /* Password failure while doing a sync from the command-line interface */ |
| 94 | 96 | url_prompt_for_password(); |
| 95 | 97 | zPw = g.url.passwd; |
| 96 | 98 | } |
| 97 | 99 |
| --- src/http.c | |
| +++ src/http.c | |
| @@ -86,11 +86,13 @@ | |
| 86 | if( g.url.passwd ){ |
| 87 | zPw = g.url.passwd; |
| 88 | }else if( g.cgiOutput ){ |
| 89 | /* Password failure while doing a sync from the web interface */ |
| 90 | cgi_printf("*** incorrect or missing password for user %h\n", zLogin); |
| 91 | zPw = 0; |
| 92 | }else{ |
| 93 | /* Password failure while doing a sync from the command-line interface */ |
| 94 | url_prompt_for_password(); |
| 95 | zPw = g.url.passwd; |
| 96 | } |
| 97 |
| --- src/http.c | |
| +++ src/http.c | |
| @@ -86,11 +86,13 @@ | |
| 86 | if( g.url.passwd ){ |
| 87 | zPw = g.url.passwd; |
| 88 | }else if( g.cgiOutput ){ |
| 89 | /* Password failure while doing a sync from the web interface */ |
| 90 | cgi_printf("*** incorrect or missing password for user %h\n", zLogin); |
| 91 | blob_reset(&pw); |
| 92 | blob_reset(&nonce); |
| 93 | return; |
| 94 | }else{ |
| 95 | /* Password failure while doing a sync from the command-line interface */ |
| 96 | url_prompt_for_password(); |
| 97 | zPw = g.url.passwd; |
| 98 | } |
| 99 |