From: Timo Sirainen Date: Tue, 17 Jul 2012 13:20:20 +0000 (+0300) Subject: auth: Fixed error handling in GSSAPI when __gss_userok() was used. X-Git-Tag: 2.1.9~24 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b1f02eab20719cda8ec4efe229dfd3c6967970f1;p=thirdparty%2Fdovecot%2Fcore.git auth: Fixed error handling in GSSAPI when __gss_userok() was used. An invalid username would have been treated as successful and auth process probably would have crashed. --- diff --git a/src/auth/mech-gssapi.c b/src/auth/mech-gssapi.c index 73fc0c8f41..de59bf5580 100644 --- a/src/auth/mech-gssapi.c +++ b/src/auth/mech-gssapi.c @@ -416,8 +416,8 @@ mech_gssapi_krb5_userok(struct gssapi_auth_request *request, bool ret = FALSE; /* Parse out the principal's username */ - if (!get_display_name(&request->auth_request, name, &name_type, - &princ_display_name) < 0) + if (get_display_name(&request->auth_request, name, &name_type, + &princ_display_name) < 0) return FALSE; if (!mech_gssapi_oid_cmp(name_type, GSS_KRB5_NT_PRINCIPAL_NAME) &&