diff options
author | Gerald Carter <jerry@samba.org> | 2007-02-22 20:52:27 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:18:09 -0500 |
commit | 6a69caf6907fad01b13aa4358ce5c62506f98495 (patch) | |
tree | 31ad02ff1bcecf8cce5275bb1d56c14bed022bb7 /source/rpc_parse | |
parent | 5cd9a2e25872db1881f2f67026bfcd52d060fc4b (diff) | |
download | samba-6a69caf6907fad01b13aa4358ce5c62506f98495.tar.gz samba-6a69caf6907fad01b13aa4358ce5c62506f98495.tar.xz samba-6a69caf6907fad01b13aa4358ce5c62506f98495.zip |
r21507: Fix some "cannot access LDAP when no root" bugs.
The two culprits were
* pdb_get_account_policy()
* pdb_get_group_sid()
Diffstat (limited to 'source/rpc_parse')
-rw-r--r-- | source/rpc_parse/parse_samr.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/rpc_parse/parse_samr.c b/source/rpc_parse/parse_samr.c index 5b276d98702..e0f5f7f294c 100644 --- a/source/rpc_parse/parse_samr.c +++ b/source/rpc_parse/parse_samr.c @@ -6331,8 +6331,10 @@ NTSTATUS init_sam_user_info21A(SAM_USER_INFO_21 *usr, struct samu *pw, DOM_SID * return NT_STATUS_UNSUCCESSFUL; } + become_root(); group_sid = pdb_get_group_sid(pw); - + unbecome_root(); + if (!sid_peek_check_rid(domain_sid, group_sid, &group_rid)) { fstring group_sid_string; fstring domain_sid_string; |