svn rev #24607: branches/krb5-1-9/src/lib/gssapi/krb5/

tlyu@MIT.EDU tlyu at MIT.EDU
Mon Jan 31 17:44:13 EST 2011


http://src.mit.edu/fisheye/changelog/krb5/?cs=24607
Commit By: tlyu
Log Message:
ticket: 6675
version_fixed: 1.9.1
status: resolved

pull up r24590 from trunk

 ------------------------------------------------------------------------
 r24590 | ghudson | 2010-12-28 13:27:17 -0500 (Tue, 28 Dec 2010) | 8 lines

 ticket: 6675
 target_version: 1.9.1
 tags: pullup

 Don't attempt to serialize a NULL authdata context when serializing a
 GSSAPI context (most often seen with initiator contexts).  Patch from
 aberry at likewise.com.


Changed Files:
U   branches/krb5-1-9/src/lib/gssapi/krb5/ser_sctx.c
Modified: branches/krb5-1-9/src/lib/gssapi/krb5/ser_sctx.c
===================================================================
--- branches/krb5-1-9/src/lib/gssapi/krb5/ser_sctx.c	2011-01-26 19:48:16 UTC (rev 24606)
+++ branches/krb5-1-9/src/lib/gssapi/krb5/ser_sctx.c	2011-01-31 22:44:13 UTC (rev 24607)
@@ -357,7 +357,7 @@
 
             initiator_name = ctx->initiate ? ctx->here : ctx->there;
 
-            if (initiator_name) {
+            if (initiator_name && initiator_name->ad_context) {
                 kret = krb5_size_opaque(kcontext,
                                         KV5M_AUTHDATA_CONTEXT,
                                         initiator_name->ad_context,
@@ -534,7 +534,7 @@
 
                 initiator_name = ctx->initiate ? ctx->here : ctx->there;
 
-                if (initiator_name) {
+                if (initiator_name && initiator_name->ad_context) {
                     kret = krb5_externalize_opaque(kcontext,
                                                    KV5M_AUTHDATA_CONTEXT,
                                                    initiator_name->ad_context,
@@ -775,6 +775,8 @@
                                                    (krb5_pointer *)&initiator_name->ad_context,
                                                    &bp,
                                                    &remain);
+                    if (kret == EINVAL)
+                        kret = 0;
                 }
             }
             /* Get trailer */




More information about the cvs-krb5 mailing list