[PATCH] drsuapi.idl: Manage all possible lengths of DsBindInfo

Kamen Mazdrashki kamenim at samba.org
Sun Jul 6 15:00:16 MDT 2014


On Sun, Jul 6, 2014 at 10:21 PM, Samuel Cabrero <scabrero at zentyal.com>
wrote:

> Done. I attach full patch set.
>
> Thanks for review!
>
>
Thanks Samuel.
Looks good
Reviewed-by: Kamen Mazdrashki <kamenim at samba.org>

Cheers,
Kamen


> On 06/07/14 12:08, Stefan (metze) Metzmacher wrote:
>
>> Am 04.07.2014 17:08, schrieb Samuel Cabrero:
>>
>>> Hello,
>>>
>>> we have reports about samba not able to join to domain and crashing with
>>> the following exception:
>>>
>>> 'drsuapi.DsBindInfoFallBack' object has no attribute
>>> 'supported_extensions'
>>>
>>> Digging into the problem it seems to be in the drsuapi IDL. The
>>> DsBindInfo blob returned by the server is decoded in the IDL, based on
>>> the blob length. For some reason, some servers are returning a 32 bytes
>>> length blob, which is not decoded, so it falls into the default case and
>>> python bindings crash.
>>>
>>> Reviewing the documentation [MS-DRSR], it is possible the server not to
>>> push the object GUID of the configuration NC, so I have added that case
>>> and also the one to decode the blob returned by W2K12 R2 which is 52
>>> bytes.
>>>
>>
>> Thanks for the patches!
>>
>> If you don't mind I'd prefer to have the switch statements ordered more
>> consistently.
>> Either:
>>
>> case 24:
>> case 28:
>> case 32:
>> case 48:
>> case 52:
>>
>> or
>>
>> case 52:
>> case 48:
>> case 32:
>> case 28:
>> case 24:
>>
>> But please don't keep
>>
>> case 48:
>> case 28:
>> case 32:
>> case 52:
>>
>> metze
>>
>>
> --
> Samuel Cabrero - Developer
> scabrero at zentyal.com
>
> Zentyal - Active Exchange
> www.zentyal.com
>


More information about the samba-technical mailing list