Age | Commit message (Collapse) | Author | Files | Lines |
|
This change addresses bug 9026.
There are 3 use cases for DATA_BLOB marshalling/unmarshalling:
1)
ndr_push_DATA_BLOB and ndr_pull_DATA_BLOB when called with
LIBNDR_FLAG_ALIGN* alignment flags set, are used to push/pull padding
bytes _only_. The length is determined by the alignment required and
the current ndr offset.
e.g. dcerpc.idl:
typedef struct {
...
[flag(NDR_ALIGN8)] DATA_BLOB _pad;
} dcerpc_request;
2)
When called with the LIBNDR_FLAG_REMAINING flag, all remaining bytes in
the ndr buffer are pushed/pulled.
e.g. dcerpc.idl:
typedef struct {
...
[flag(NDR_REMAINING)] DATA_BLOB stub_and_verifier;
} dcerpc_request;
3)
When called without alignment flags, push/pull a uint32 length _and_ a
corresponding byte array to/from the ndr buffer.
e.g. drsblobs.idl
typedef [public] struct {
...
DATA_BLOB data;
} DsCompressedChunk;
The fix for bug 8373 changed the definition of "alignment flags", such
that when called with LIBNDR_FLAG_NOALIGN ndr_push/pull_DATA_BLOB
behaves as (1: padding bytes) rather than (3: uint32 length + byte
array).
This breaks marshalling/unmarshalling for the following structures.
eventlog.idl:
typedef [flag(NDR_NOALIGN|NDR_PAHEX),public] struct {
...
DATA_BLOB sid;
...
} eventlog_Record_tdb;
ntprinting.idl:
typedef [flag(NDR_NOALIGN),public] struct {
...
DATA_BLOB *nt_dev_private;
} ntprinting_devicemode;
typedef [flag(NDR_NOALIGN),public] struct {
...
DATA_BLOB data;
} ntprinting_printer_data;
Signed-off-by: Günther Deschner <gd@samba.org>
|
|
Autobuild-User: Volker Lendecke <vl@samba.org>
Autobuild-Date: Mon Feb 13 15:06:29 CET 2012 on sn-devel-104
|
|
|
|
|
|
this checks that the passed in ndr_flags are valid
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
|
|
This has 8 byte alignment, which is what was specified in pidl for
these types.
Andrew Bartlett
Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Wed Mar 9 09:03:09 CET 2011 on sn-devel-104
|
|
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Mar 1 17:11:03 CET 2011 on sn-devel-104
|
|
These are mapped to uint64_t, which should be big enough. This is
proposed to be used for internal Samba representations, where it would
be more painful to convert all the callers to an uint64_t calling
convention.
Andrew Bartlett
|
|
LIBNDR_FLAG_REMAINING before LIBNDR_ALIGN_FLAGS
metze
|
|
Guenther
|
|
Guenther
|
|
Signed-off-by: Matthieu Patou <mat@matws.net>
Autobuild-User: Matthieu Patou <mat@samba.org>
Autobuild-Date: Wed Dec 8 10:26:00 CET 2010 on sn-devel-104
|
|
Kai, please check.
Autobuild-User: Björn Jacke <bj@sernet.de>
Autobuild-Date: Fri Nov 26 03:07:21 CET 2010 on sn-devel-104
|
|
Thanks to Julien Kerihuel for providing the patch that pushed me to
finish my own IPv6 patches.
|
|
|
|
when using ndrdump you can get uninitialised structures containing
pointers. Don't segfault when trying to print them
|
|
|
|
this prints DATA_BLOB structures using the ndr->print() calls
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
|
|
Will not harm anyone, is only used for rare short (2byte) relative pointers, and
relative_rap_convert is always 0 so far (as all init functions using struct
ndr_pull will zero the struct).
Guenther
|
|
These were causing thousands of warnings on solaris8
|
|
relative_short is like relative but instead of having the offset coded on 4 bytes
it's coded on 2 bytes. Such things happen in GET_DFS_REFERAL messages.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
|
|
The default enum in NDR63 is 32 bits, not 16 bits. We need a uint1632
type to get the alignment right.
|
|
This is the type used for a variable that is 32 bits for NDR32 and 64
bits for NDR64
|
|
NDR64 has a 'trailing gap' alignment, which aligns the end of a
structure on the overall structure alignment.
This explains the discrepancy we had with the RPC-SAMR test and NDR64
|
|
This fixes the problem with samr UserInfo16 when NDR64 is enabled
|
|
This allows for easier implementation of the NDR32/NDR64 split
|
|
This adds NDR64 support for the push functions in libndr
|
|
Jeremy.
|
|
This only does pull, but it is useful for w2k8-r2 <-> w2k8-r2 ndrdump
usage, which is always 64bit.
|
|
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
|
|
|
|
cc: "../librpc/ndr/ndr_basic.c", line 572: warning 604: Pointers are not assignment-compatible.
Apparently in_addr.s_addr is not compatible to uint32_t, maybe a 32-bit signed
int.
|
|
Jeremy.
|
|
Jeremy.
|
|
|