ber_read_OID_String patch

Stefan (metze) Metzmacher metze at
Tue Sep 8 04:33:14 MDT 2009

Kamen Mazdrashki schrieb:
> Hi again,
> On Mon, Sep 7, 2009 at 15:33, Kamen Mazdrashki<kamen.mazdrashki at> wrote:
>> Please see the attached log file - it is produced by extending the
>> DSSYNC test a little bit and by tuning the drsuapi.idl file a little
>> bit (I will publish the branch tomorrow so you could play with it if
>> you wish to).
> The branch is published at:

-       typedef [nopush,nopull] struct {
[range(0,10000),value(ndr_size_drsuapi_DsReplicaOID_oid(oid, 0))] uint32
-               [size_is(__ndr_size),charset(DOS)] uint8 *oid; /* it's
encoded with asn1_write_OID_String() */
+       typedef [noprint] struct {
+               [range(0,10000)] uint32 length;
+               [size_is(length)] uint8 *oid;
        } drsuapi_DsReplicaOID;

please rename oid to binary_oid and fix all callers to cope with binary
data. With this patch you'll generate some compilers and bugs,
because we now pass a binary buffer as string
(while casting uint8_t * to char *).

I fear the patch will be much larger...


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
URL: <>

More information about the samba-technical mailing list