svn rev #23856: branches/iakerb/src/lib/gssapi/krb5/

ghudson@MIT.EDU ghudson at MIT.EDU
Sun Apr 4 13:52:03 EDT 2010


http://src.mit.edu/fisheye/changelog/krb5/?cs=23856
Commit By: ghudson
Log Message:
In the GSSAPI IAKERB code, fix the sense of the flags expected from
krb5_init_creds_step and krb5_tkt_creds_step.



Changed Files:
U   branches/iakerb/src/lib/gssapi/krb5/iakerb.c
Modified: branches/iakerb/src/lib/gssapi/krb5/iakerb.c
===================================================================
--- branches/iakerb/src/lib/gssapi/krb5/iakerb.c	2010-04-04 17:20:50 UTC (rev 23855)
+++ branches/iakerb/src/lib/gssapi/krb5/iakerb.c	2010-04-04 17:52:03 UTC (rev 23856)
@@ -599,7 +599,7 @@
                                     &flags);
         if (code != 0)
             goto cleanup;
-        if (flags != 0) {
+        if ((flags & 1) != 1) {
             krb5_init_creds_get_times(ctx->k5c, ctx->u.icc, &times);
             cred->tgt_expire = times.endtime;
 
@@ -609,6 +609,7 @@
             ctx->state = IAKERB_TGS_REQ;
         } else
             break;
+        in = empty_data();
     case IAKERB_TGS_REQ:
         if (ctx->u.tcc == NULL) {
             code = iakerb_tkt_creds_ctx(ctx, cred, name, time_req);
@@ -618,7 +619,7 @@
 
         code = krb5_tkt_creds_step(ctx->k5c,
                                    ctx->u.tcc,
-                                   flags ? NULL : &in,
+                                   &in,
                                    &out,
                                    &realm,
                                    &flags);
@@ -627,7 +628,7 @@
             krb5_tkt_creds_store_creds(ctx->k5c, ctx->u.tcc, NULL);
             goto cleanup;
         }
-        if (flags != 0) {
+        if ((flags & 1) != 1) {
             code = krb5_tkt_creds_store_creds(ctx->k5c, ctx->u.tcc, NULL);
             if (code != 0)
                 goto cleanup;




More information about the cvs-krb5 mailing list