svn rev #22137: branches/fast/src/kdc/

hartmans@MIT.EDU hartmans at MIT.EDU
Thu Mar 26 01:37:15 EDT 2009


http://src.mit.edu/fisheye/changelog/krb5/?cs=22137
Commit By: hartmans
Log Message:
do_as_req: decode kdc_req_body

Pull the kdc_req_body out of the ASN.1 packet and pass in to be
checksummed; the code previously incorrectly passed in the entire
kdc_req.


Changed Files:
U   branches/fast/src/kdc/do_as_req.c
Modified: branches/fast/src/kdc/do_as_req.c
===================================================================
--- branches/fast/src/kdc/do_as_req.c	2009-03-26 05:37:12 UTC (rev 22136)
+++ branches/fast/src/kdc/do_as_req.c	2009-03-26 05:37:15 UTC (rev 22137)
@@ -118,6 +118,7 @@
     const char *emsg = 0;
     krb5_keylist_node *tmp_mkey_list;
     struct kdc_request_state *state = NULL;
+    krb5_data encoded_req_body;
     
 
 #if APPLE_PKINIT
@@ -140,7 +141,12 @@
 	status = "constructing state";
 	goto errout;
     }
-    errcode = kdc_find_fast(&request, req_pkt, NULL /*TGS key*/, state);
+    if (fetch_asn1_field((unsigned char *) req_pkt->data,
+			 1, 4, &encoded_req_body) != 0) {
+    errcode = ASN1_BAD_ID;
+    status = "Finding req_body";
+}
+    errcode = kdc_find_fast(&request, &encoded_req_body, NULL /*TGS key*/, state);
     if (errcode) {
 	status = "error decoding FAST";
 	goto errout;




More information about the cvs-krb5 mailing list