diff options
Diffstat (limited to 'source4/auth')
-rw-r--r-- | source4/auth/credentials/credentials_krb5.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/source4/auth/credentials/credentials_krb5.c b/source4/auth/credentials/credentials_krb5.c index 58b5c1df3b..2188bf6ad8 100644 --- a/source4/auth/credentials/credentials_krb5.c +++ b/source4/auth/credentials/credentials_krb5.c @@ -247,6 +247,9 @@ int cli_credentials_new_ccache(struct cli_credentials *cred, struct ccache_conta *_ccc = ccc; } + cred->ccache_obtained = (MAX(MAX(cred->principal_obtained, + cred->username_obtained), + cred->password_obtained)); return ret; } @@ -259,8 +262,9 @@ int cli_credentials_get_ccache(struct cli_credentials *cred, cli_credentials_set_machine_account(cred); } - if (cred->ccache_obtained >= (MAX(cred->principal_obtained, - cred->username_obtained))) { + if (cred->ccache_obtained >=(MAX(MAX(cred->principal_obtained, + cred->username_obtained), + cred->password_obtained))) { *ccc = cred->ccache; return 0; } |