Set up the keyblock's etype field correctly (after copying the
authorTheodore Tso <tytso@mit.edu>
Thu, 9 Feb 1995 22:44:51 +0000 (22:44 +0000)
committerTheodore Tso <tytso@mit.edu>
Thu, 9 Feb 1995 22:44:51 +0000 (22:44 +0000)
keyblock, so it doesn't get overwritten!)

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

src/lib/krb5/krb/ChangeLog
src/lib/krb5/krb/gc_via_tgt.c

index 31131cc1fcd4191fed175f5913dfafc4eeb31e9d..84a18c26c06bbb9c37339eb59174b8fe915d0bfd 100644 (file)
@@ -1,3 +1,9 @@
+Thu Feb  9 17:43:04 1995  Theodore Y. Ts'o  <tytso@dcl>
+
+       * gc_via_tgt.c (krb5_get_cred_via_tgt): Set up the keyblock's
+               etype field correctly (after copying the keyblock, so it
+               doesn't get overwritten!)
+
 Mon Feb 06 17:19:04 1995 Chris Provenzano  (proven@mit.edu)
 
        * get_in_tkt.c (krb5_get_in_tkt())
index 026cf30e0a1847eab867b00340d9a7b3594b95e2..1e9b8da53b0e0716a6cf73c7a0651c0230214e93 100644 (file)
@@ -146,13 +146,12 @@ krb5_get_cred_via_tgt (context, tgt, kdcoptions, sumtype, cred)
        memset(&cred->keyblock.contents, 0, cred->keyblock.length);
        krb5_xfree(cred->keyblock.contents);
     }
-    cred->keyblock.magic = KV5M_KEYBLOCK;
-    cred->keyblock.etype = dec_rep->ticket->enc_part.etype;
     if (retval = krb5_copy_keyblock_contents(context, dec_rep->enc_part2->session,
                                             &cred->keyblock)) {
        cleanup();
        return retval;
     }
+    cred->keyblock.etype = dec_rep->ticket->enc_part.etype;
     memset((char *)dec_rep->enc_part2->session->contents, 0,
          dec_rep->enc_part2->session->length);