mirror of
https://github.com/git/git.git
synced 2026-01-10 01:56:42 +00:00
Merge branch 'cs/http-use-basic-after-failed-negotiate'
Regression fix for a change made during this cycle. * cs/http-use-basic-after-failed-negotiate: Revert "remote-curl: fall back to basic auth if Negotiate fails" t5551: test http interaction with credential helpers
This commit is contained in:
15
http.c
15
http.c
@@ -1650,18 +1650,17 @@ static int handle_curl_result(struct slot_results *results)
|
||||
} else if (missing_target(results))
|
||||
return HTTP_MISSING_TARGET;
|
||||
else if (results->http_code == 401) {
|
||||
#ifdef LIBCURL_CAN_HANDLE_AUTH_ANY
|
||||
http_auth_methods &= ~CURLAUTH_GSSNEGOTIATE;
|
||||
if (results->auth_avail) {
|
||||
http_auth_methods &= results->auth_avail;
|
||||
http_auth_methods_restricted = 1;
|
||||
return HTTP_REAUTH;
|
||||
}
|
||||
#endif
|
||||
if (http_auth.username && http_auth.password) {
|
||||
credential_reject(&http_auth);
|
||||
return HTTP_NOAUTH;
|
||||
} else {
|
||||
#ifdef LIBCURL_CAN_HANDLE_AUTH_ANY
|
||||
http_auth_methods &= ~CURLAUTH_GSSNEGOTIATE;
|
||||
if (results->auth_avail) {
|
||||
http_auth_methods &= results->auth_avail;
|
||||
http_auth_methods_restricted = 1;
|
||||
}
|
||||
#endif
|
||||
return HTTP_REAUTH;
|
||||
}
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user