mirror of
https://github.com/samba-team/samba.git
synced 2025-08-03 04:22:09 +03:00
s3-rpc_client: Added dcerpc_lsa_open_policy.
Signed-off-by: Günther Deschner <gd@samba.org>
This commit is contained in:
committed by
Günther Deschner
parent
342bb471dc
commit
2f819505af
@ -41,14 +41,12 @@
|
||||
* security authority", which is half of a password database.
|
||||
**/
|
||||
|
||||
/** Open a LSA policy handle
|
||||
*
|
||||
* @param cli Handle on an initialised SMB connection */
|
||||
|
||||
NTSTATUS rpccli_lsa_open_policy(struct rpc_pipe_client *cli,
|
||||
NTSTATUS dcerpc_lsa_open_policy(struct dcerpc_binding_handle *h,
|
||||
TALLOC_CTX *mem_ctx,
|
||||
bool sec_qos, uint32 des_access,
|
||||
struct policy_handle *pol)
|
||||
bool sec_qos,
|
||||
uint32_t des_access,
|
||||
struct policy_handle *pol,
|
||||
NTSTATUS *result)
|
||||
{
|
||||
struct lsa_ObjectAttribute attr;
|
||||
struct lsa_QosInfo qos;
|
||||
@ -67,11 +65,38 @@ NTSTATUS rpccli_lsa_open_policy(struct rpc_pipe_client *cli,
|
||||
attr.sec_qos = &qos;
|
||||
}
|
||||
|
||||
return rpccli_lsa_OpenPolicy(cli, mem_ctx,
|
||||
return dcerpc_lsa_OpenPolicy(h,
|
||||
mem_ctx,
|
||||
&system_name,
|
||||
&attr,
|
||||
des_access,
|
||||
pol);
|
||||
pol,
|
||||
result);
|
||||
}
|
||||
|
||||
/** Open a LSA policy handle
|
||||
*
|
||||
* @param cli Handle on an initialised SMB connection */
|
||||
|
||||
NTSTATUS rpccli_lsa_open_policy(struct rpc_pipe_client *cli,
|
||||
TALLOC_CTX *mem_ctx,
|
||||
bool sec_qos, uint32 des_access,
|
||||
struct policy_handle *pol)
|
||||
{
|
||||
NTSTATUS status;
|
||||
NTSTATUS result = NT_STATUS_UNSUCCESSFUL;
|
||||
|
||||
status = dcerpc_lsa_open_policy(cli->binding_handle,
|
||||
mem_ctx,
|
||||
sec_qos,
|
||||
des_access,
|
||||
pol,
|
||||
&result);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
return status;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
/** Open a LSA policy handle
|
||||
|
Reference in New Issue
Block a user