[PATCH] Setting nTSecurityDescriptor via LDAP fails

Stefan (metze) Metzmacher metze at samba.org
Fri Mar 20 13:48:23 GMT 2009


Jelmer Vernooij schrieb:
> Hi Metze,
> 
> Stefan (metze) Metzmacher wrote:>
>> why does PyObject_AsMessageElement() copy the string for one case but
>> not for the multiple value case.
> Good point; since we borrow the reference to the list, we don't need to
> do a dup there at all.
> 
>> Also why doesn't it use a->syntax->ldif_read_fn() as
>> PyObject_FromLdbValue() also uses a->syntax->ldif_write_fn().
> PyObject_FromLdbValue() probably shouldn't be using
> a->syntax->ldif_write_fn().
> 
>> I wonder why we only handle ldif correctly in samba.Ldb and not in
>> the LDB.Ldb class.
> 
> LDB.Ldb doesn't load any of the Samba-specific code, including nt
> security descriptor handling.
> 
> I'll have a look at Zahari's patches and these issues later today.

But I think LDB.Ldb should detect base64 and only accept valid LDIF.
And no hand made binary strings. Also a->syntax is a plain ldb feature.
only the implementations are samba specific.

metze


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
Url : http://lists.samba.org/archive/samba-technical/attachments/20090320/448b05d1/signature.bin


More information about the samba-technical mailing list