mirror of
https://github.com/samba-team/samba.git
synced 2025-11-08 16:23:49 +03:00
r6817: - fixed empty ldap search elements in filters
- added support for guids in cldap netlogon searches. the cldap server now passes the LDAP-CLDAP torture test
This commit is contained in:
committed by
Gerald (Jerry) Carter
parent
7d19eb9433
commit
eb7979d9de
@@ -74,3 +74,19 @@ const char *ldap_encode_ndr_GUID(TALLOC_CTX *mem_ctx, struct GUID *guid)
|
||||
data_blob_free(&blob);
|
||||
return ret;
|
||||
}
|
||||
|
||||
/*
|
||||
decode a NDR GUID from a ldap filter element
|
||||
*/
|
||||
NTSTATUS ldap_decode_ndr_GUID(TALLOC_CTX *mem_ctx, struct ldap_val val, struct GUID *guid)
|
||||
{
|
||||
DATA_BLOB blob;
|
||||
NTSTATUS status;
|
||||
|
||||
blob.data = val.data;
|
||||
blob.length = val.length;
|
||||
status = ndr_pull_struct_blob(&blob, mem_ctx, guid,
|
||||
(ndr_pull_flags_fn_t)ndr_pull_GUID);
|
||||
talloc_free(val.data);
|
||||
return status;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user