diff options
author | Andrew Tridgell <tridge@samba.org> | 2011-09-02 12:01:19 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2011-09-05 11:19:25 +0200 |
commit | 7d94c8ae198e3342d039d6e5dd8c6cdaa2622ebf (patch) | |
tree | ec858494a1da14e2a26018b8ca0d710a8270b93d /librpc | |
parent | cd8dcf6d61a554ddac1a632f5bea855c4af1d558 (diff) | |
download | samba-7d94c8ae198e3342d039d6e5dd8c6cdaa2622ebf.tar.gz |
drsblobs: fixed alignment of drs blobs authentication information
the two types of ndr flags were being mixed up, so NDR_BUFFERS was
being interpreted as LIBNDR_FLAG_NOALIGN
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'librpc')
-rw-r--r-- | librpc/ndr/ndr_drsblobs.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/librpc/ndr/ndr_drsblobs.c b/librpc/ndr/ndr_drsblobs.c index 32176a7bf9f..1392b987951 100644 --- a/librpc/ndr/ndr_drsblobs.c +++ b/librpc/ndr/ndr_drsblobs.c @@ -32,7 +32,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_AuthenticationInformationArray(struct ndr_pu for (cntr_array_0 = 0; cntr_array_0 < r->count; cntr_array_0++) { NDR_CHECK(ndr_push_AuthenticationInformation(ndr, NDR_SCALARS, &r->array[cntr_array_0])); } - NDR_CHECK(ndr_push_trailer_align(ndr, 4)); + NDR_CHECK(ndr_push_align(ndr, 4)); } if (ndr_flags & NDR_BUFFERS) { } @@ -51,7 +51,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_AuthenticationInformationArray(struct ndr_pu NDR_CHECK(ndr_pull_AuthenticationInformation(ndr, NDR_SCALARS, &r->array[r->count])); r->count++; } - NDR_CHECK(ndr_pull_trailer_align(ndr, 4)); + NDR_CHECK(ndr_pull_align(ndr, 4)); } if (ndr_flags & NDR_BUFFERS) { } @@ -64,12 +64,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_trustAuthInOutBlob(struct ndr_push *ndr, int NDR_CHECK(ndr_push_align(ndr, 4)); NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count)); NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (r->count > 0)?12:0)); - NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (r->count > 0)?12 + ndr_size_AuthenticationInformationArray(&r->current, ndr_flags):0)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (r->count > 0)?12 + ndr_size_AuthenticationInformationArray(&r->current, 0):0)); { struct ndr_push *_ndr_current; - NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_current, 0, ((r->count > 0)?12 + ndr_size_AuthenticationInformationArray(&r->current, ndr_flags):0) - ((r->count > 0)?12:0))); + NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_current, 0, ((r->count > 0)?12 + ndr_size_AuthenticationInformationArray(&r->current, 0):0) - ((r->count > 0)?12:0))); NDR_CHECK(ndr_push_AuthenticationInformationArray(_ndr_current, NDR_SCALARS, &r->current)); - NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_current, 0, ((r->count > 0)?12 + ndr_size_AuthenticationInformationArray(&r->current, ndr_flags):0) - ((r->count > 0)?12:0))); + NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_current, 0, ((r->count > 0)?12 + ndr_size_AuthenticationInformationArray(&r->current, 0):0) - ((r->count > 0)?12:0))); } { uint32_t _flags_save_AuthenticationInformationArray = ndr->flags; |