summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-02-05 11:16:58 +0100
committerGünther Deschner <gd@samba.org>2008-02-05 13:19:47 +0100
commitca772c8b18db3bbe0ef6ff9be0c29d3ac732fbe7 (patch)
tree7d9c8bf0ed55a46b47c488c748b2118fd749d13b /source3/rpc_server
parent6e36f72ce67e38272fc75cf8cbb764252359770b (diff)
downloadsamba-ca772c8b18db3bbe0ef6ff9be0c29d3ac732fbe7.tar.gz
samba-ca772c8b18db3bbe0ef6ff9be0c29d3ac732fbe7.tar.bz2
samba-ca772c8b18db3bbe0ef6ff9be0c29d3ac732fbe7.zip
Use pidl for _samr_RemoveMemberFromForeignDomain().
Guenther (This used to be commit ab344dea9689ffc191110de0eca0d43b7221f7ee)
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/srv_samr.c23
-rw-r--r--source3/rpc_server/srv_samr_nt.c29
2 files changed, 10 insertions, 42 deletions
diff --git a/source3/rpc_server/srv_samr.c b/source3/rpc_server/srv_samr.c
index bc7fd0e175..e6207c812a 100644
--- a/source3/rpc_server/srv_samr.c
+++ b/source3/rpc_server/srv_samr.c
@@ -835,28 +835,7 @@ static bool api_samr_open_group(pipes_struct *p)
static bool api_samr_remove_sid_foreign_domain(pipes_struct *p)
{
- SAMR_Q_REMOVE_SID_FOREIGN_DOMAIN q_u;
- SAMR_R_REMOVE_SID_FOREIGN_DOMAIN r_u;
-
- prs_struct *data = &p->in_data.data;
- prs_struct *rdata = &p->out_data.rdata;
-
- ZERO_STRUCT(q_u);
- ZERO_STRUCT(r_u);
-
- if (!samr_io_q_remove_sid_foreign_domain("", &q_u, data, 0)) {
- DEBUG(0,("api_samr_remove_sid_foreign_domain: unable to unmarshall SAMR_Q_REMOVE_SID_FOREIGN_DOMAIN.\n"));
- return False;
- }
-
- r_u.status = _samr_remove_sid_foreign_domain(p, &q_u, &r_u);
-
- if (!samr_io_r_remove_sid_foreign_domain("", &r_u, rdata, 0)) {
- DEBUG(0,("api_samr_remove_sid_foreign_domain: unable to marshall SAMR_R_REMOVE_SID_FOREIGN_DOMAIN.\n"));
- return False;
- }
-
- return True;
+ return proxy_samr_call(p, NDR_SAMR_REMOVEMEMBERFROMFOREIGNDOMAIN);
}
/*******************************************************************
diff --git a/source3/rpc_server/srv_samr_nt.c b/source3/rpc_server/srv_samr_nt.c
index 586d2225e2..e321d75626 100644
--- a/source3/rpc_server/srv_samr_nt.c
+++ b/source3/rpc_server/srv_samr_nt.c
@@ -4931,36 +4931,35 @@ NTSTATUS _samr_OpenGroup(pipes_struct *p,
}
/*********************************************************************
- _samr_remove_sid_foreign_domain
+ _samr_RemoveMemberFromForeignDomain
*********************************************************************/
-NTSTATUS _samr_remove_sid_foreign_domain(pipes_struct *p,
- SAMR_Q_REMOVE_SID_FOREIGN_DOMAIN *q_u,
- SAMR_R_REMOVE_SID_FOREIGN_DOMAIN *r_u)
+NTSTATUS _samr_RemoveMemberFromForeignDomain(pipes_struct *p,
+ struct samr_RemoveMemberFromForeignDomain *r)
{
DOM_SID delete_sid, domain_sid;
uint32 acc_granted;
NTSTATUS result;
DISP_INFO *disp_info = NULL;
- sid_copy( &delete_sid, &q_u->sid.sid );
+ sid_copy( &delete_sid, r->in.sid );
- DEBUG(5,("_samr_remove_sid_foreign_domain: removing SID [%s]\n",
+ DEBUG(5,("_samr_RemoveMemberFromForeignDomain: removing SID [%s]\n",
sid_string_dbg(&delete_sid)));
/* Find the policy handle. Open a policy on it. */
- if (!get_lsa_policy_samr_sid(p, &q_u->dom_pol, &domain_sid,
+ if (!get_lsa_policy_samr_sid(p, r->in.domain_handle, &domain_sid,
&acc_granted, &disp_info))
return NT_STATUS_INVALID_HANDLE;
result = access_check_samr_function(acc_granted, STD_RIGHT_DELETE_ACCESS,
- "_samr_remove_sid_foreign_domain");
+ "_samr_RemoveMemberFromForeignDomain");
if (!NT_STATUS_IS_OK(result))
return result;
- DEBUG(8, ("_samr_remove_sid_foreign_domain:sid is %s\n",
+ DEBUG(8, ("_samr_RemoveMemberFromForeignDomain: sid is %s\n",
sid_string_dbg(&domain_sid)));
/* we can only delete a user from a group since we don't have
@@ -4978,7 +4977,7 @@ NTSTATUS _samr_remove_sid_foreign_domain(pipes_struct *p,
* other cases. */
if (!sid_check_is_builtin(&domain_sid)) {
- DEBUG(1,("_samr_remove_sid_foreign_domain: domain_sid = %s, "
+ DEBUG(1,("_samr_RemoveMemberFromForeignDomain: domain_sid = %s, "
"global_sam_sid() = %s\n",
sid_string_dbg(&domain_sid),
sid_string_dbg(get_global_sam_sid())));
@@ -5319,16 +5318,6 @@ NTSTATUS _samr_TestPrivateFunctionsUser(pipes_struct *p,
/****************************************************************
****************************************************************/
-NTSTATUS _samr_RemoveMemberFromForeignDomain(pipes_struct *p,
- struct samr_RemoveMemberFromForeignDomain *r)
-{
- p->rng_fault_state = true;
- return NT_STATUS_NOT_IMPLEMENTED;
-}
-
-/****************************************************************
-****************************************************************/
-
NTSTATUS _samr_QueryDomainInfo2(pipes_struct *p,
struct samr_QueryDomainInfo2 *r)
{