Return ERROR_FCC_NOFILE when the principal cannot be determined during
authorJeffrey Altman <jaltman@secure-endpoints.com>
Fri, 19 Mar 2004 07:25:08 +0000 (07:25 +0000)
committerJeffrey Altman <jaltman@secure-endpoints.com>
Fri, 19 Mar 2004 07:25:08 +0000 (07:25 +0000)
calls to krb5_lcc_resolve()

ticket: 2430

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16186 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/krb5/ccache/ChangeLog
src/lib/krb5/ccache/cc_mslsa.c

index eaff17736d62eeab191558f655749c7e2d770950..631313b290f24b49546f7739cf1eb4e29f738695 100644 (file)
@@ -3,6 +3,9 @@
    * cc_mslsa.c:
      Add missing return statements in krb5_lcc_start_seq_get()
 
+     Return error if principal name cannot be determined during
+     krb5_lcc_resolve()
+
    * cc-int.h:
      New file - Add prototypes for cc internal functions
 
index 96558726d158aca07457ba7162dd5e1a70cdb45f..44ef459390c2d10540ee03d1b7d2c9e10cddbf27 100644 (file)
@@ -1147,6 +1147,11 @@ krb5_lcc_resolve (krb5_context context, krb5_ccache *id, const char *residual)
         krb5_free_cred_contents(context,&creds);
     } else {
         data->princ = 0;
+        krb5_xfree(data->cc_name);
+        krb5_xfree(lid->data);
+        krb5_xfree(lid);
+        CloseHandle(LogonHandle);
+        return KRB5_FCC_NOFILE;
     }
 
     /*