pull up r22183 from trunk
authorTom Yu <tlyu@mit.edu>
Wed, 15 Apr 2009 20:07:42 +0000 (20:07 +0000)
committerTom Yu <tlyu@mit.edu>
Wed, 15 Apr 2009 20:07:42 +0000 (20:07 +0000)
 ------------------------------------------------------------------------
 r22183 | epeisach | 2009-04-08 11:25:43 -0400 (Wed, 08 Apr 2009) | 11 lines
 Changed paths:
    M /trunk/src/kdc/do_as_req.c

 ticket: 6449
 subject: Fall through on error return

 If decoding the encoded_req_body fails, proceed goto errout instead of falling
 through to fast handling.

 Looks like a merge error.

 Reindented code.

ticket: 6449
version_fixed: 1.7

git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-7@22253 dc483132-0cff-0310-8789-dd5450dbe970

src/kdc/do_as_req.c

index 4f1715d678ade8ce03e77dc82337cd4efdf01df1..0c4c923597f55f57deaa34bda09f12dbb05fafea 100644 (file)
@@ -144,9 +144,10 @@ process_as_req(krb5_kdc_req *request, krb5_data *req_pkt,
     }
     if (fetch_asn1_field((unsigned char *) req_pkt->data,
                         1, 4, &encoded_req_body) != 0) {
-    errcode = ASN1_BAD_ID;
-    status = "Finding req_body";
-}
+        errcode = ASN1_BAD_ID;
+        status = "Finding req_body";
+       goto errout;
+    }
     errcode = kdc_find_fast(&request, &encoded_req_body, NULL /*TGS key*/, NULL, state);
     if (errcode) {
        status = "error decoding FAST";