r3572: Thanks to tridge for his patience with my build breakage.
authorAndrew Bartlett <abartlet@samba.org>
Sat, 6 Nov 2004 05:40:34 +0000 (05:40 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:05:33 +0000 (13:05 -0500)
This concludes the proper fixes.

Andrew Bartlett
(This used to be commit c1d025793f2994c8f1cab304c3394ab186654071)

source4/lib/data_blob.c
source4/libcli/auth/gensec_krb5.c
source4/librpc/idl/krb5pac.idl

index d2147be6b275e7893adddf69d14f421fbffbfcd6..c5f15f12710809bae299106ae365b1e305625065 100644 (file)
@@ -63,13 +63,18 @@ DATA_BLOB data_blob_talloc_named(TALLOC_CTX *mem_ctx, const void *p, size_t leng
 
 
 /*******************************************************************
- construct a data blob which is a reference to another blob, in 
-the given mem context
+ reference a data blob, to the supplied TALLOC_CTX.  
+ Returns a NULL DATA_BLOB on failure
 *******************************************************************/
 DATA_BLOB data_blob_talloc_reference(TALLOC_CTX *mem_ctx, DATA_BLOB *blob)
 {
        DATA_BLOB ret = *blob;
-       ret.data = talloc_reference(mem_ctx, ret.data);
+
+       ret.data = talloc_reference(mem_ctx, blob->data);
+
+       if (!ret.data) {
+               return data_blob(NULL, 0);
+       }
        return ret;
 }
 
index a95780236ea51fe015a97ccdbc9ea55ee6bedf85..37e96cf9dce64352a6cfbfec2bc043d2db0e3a4b 100644 (file)
@@ -668,9 +668,7 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
                server_info->logon_count = logon_info->logon_count;
                /* TODO: bad password count */
 
-#if ABARTLET_HAS_FIXED_BUILD
                server_info->acct_flags = logon_info->acct_flags;
-#endif
 
                if (!server_info->domain || !server_info->account_name || !server_info->realm) {
                        free_server_info(&server_info);
index 4e3fee4b512315abb9eb7e86293fef9accbf40a7..d3a28df27bcd547379c925f50a4c29c9aa1ae847 100644 (file)
@@ -75,7 +75,7 @@ interface krb5pac
                dom_sid2 *dom_sid;
 
                uint32 reserved16[2];
-               uint32 reserved17;      /* looks like it may be acb_info */
+               uint32 acct_flags;      /* looks like it may be acb_info */
                uint32 reserved18[7];
 
                uint32 extra_sids_count;