Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Do not retry authentication methods which failed
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
  • Loading branch information
David Woodhouse authored and David Woodhouse committed Jun 19, 2014
1 parent 8dc151e commit 4d95974
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions http.c
Expand Up @@ -1754,10 +1754,14 @@ static void clear_auth_state(struct proxy_auth_state *auth, int reset)
to fully reset the state to allow another connection to start
again. Otherwise, we need to remember which auth methods have
been tried and should not be attempted again. */
if (reset || auth->state == AUTH_AVAILABLE)
auth->state = AUTH_UNSEEN;

free(auth->challenge);
auth->challenge = NULL;
/* If it *failed* don't try it again even next time */
if (auth->state == AUTH_FAILED)
return;
if (reset || auth->state == AUTH_AVAILABLE)
auth->state = AUTH_UNSEEN;
}


Expand Down

0 comments on commit 4d95974

Please sign in to comment.