kinit: Work again w/o -c or KRB5CCNAME

This commit is contained in:
Nicolas Williams
2020-08-27 23:53:54 -05:00
parent a14a0545c1
commit f47e64bb5a

View File

@@ -1570,7 +1570,8 @@ main(int argc, char **argv)
* default credential
*/
type = krb5_cc_get_type(context, ccache);
if (krb5_cc_support_switch(context, type)) {
if (krb5_cc_support_switch(context, type) &&
strcmp(type, "FILE")) {
krb5_cc_close(context, ccache);
ret = get_switched_ccache(context, type, principal,
&ccache);