summaryrefslogtreecommitdiff
path: root/source4/lib/http
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib/http')
-rw-r--r--source4/lib/http/http_auth.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/source4/lib/http/http_auth.c b/source4/lib/http/http_auth.c
index d134bd65219..701d9b3bae3 100644
--- a/source4/lib/http/http_auth.c
+++ b/source4/lib/http/http_auth.c
@@ -61,17 +61,19 @@ static NTSTATUS http_parse_auth_response(enum http_auth_method auth,
struct http_header *h;
for (h = auth_response->headers; h != NULL; h = h->next) {
- if (strncasecmp(h->key, "WWW-Authenticate", 16) == 0) {
- switch (auth) {
- case HTTP_AUTH_NTLM:
- if (strncasecmp(h->value, "NTLM ", 5) == 0) {
- *in = data_blob_string_const(h->value);
- return NT_STATUS_OK;
- }
- break;
- default:
- break;
+ if (strncasecmp(h->key, "WWW-Authenticate", 16) != 0) {
+ continue;
+ }
+
+ switch (auth) {
+ case HTTP_AUTH_NTLM:
+ if (strncasecmp(h->value, "NTLM ", 5) == 0) {
+ *in = data_blob_string_const(h->value);
+ return NT_STATUS_OK;
}
+ break;
+ default:
+ break;
}
}