summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2009-07-16 14:34:06 +0200
committerGünther Deschner <gd@samba.org>2011-02-16 11:35:20 +0100
commit39c9f59dbab09fb2ce12218dfe798c169e450490 (patch)
tree24ca7ace8999dc27501248f41209febbb9ffaf0b
parent55bc1cfae38beec6da00c8f6e1d730519e0b7626 (diff)
downloadsamba-39c9f59dbab09fb2ce12218dfe798c169e450490.tar.gz
samba-39c9f59dbab09fb2ce12218dfe798c169e450490.tar.bz2
samba-39c9f59dbab09fb2ce12218dfe798c169e450490.zip
s3-lsa: implement _lsa_CreateTrustedDomain().
Guenther Signed-off-by: Günther Deschner <gd@samba.org>
-rw-r--r--source3/rpc_server/lsa/srv_lsa_nt.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/source3/rpc_server/lsa/srv_lsa_nt.c b/source3/rpc_server/lsa/srv_lsa_nt.c
index d235a6542c..1a43b197aa 100644
--- a/source3/rpc_server/lsa/srv_lsa_nt.c
+++ b/source3/rpc_server/lsa/srv_lsa_nt.c
@@ -1531,12 +1531,32 @@ NTSTATUS _lsa_CreateTrustedDomainEx(struct pipes_struct *p,
}
/***************************************************************************
+ _lsa_CreateTrustedDomain
***************************************************************************/
NTSTATUS _lsa_CreateTrustedDomain(struct pipes_struct *p,
struct lsa_CreateTrustedDomain *r)
{
- return NT_STATUS_ACCESS_DENIED;
+ struct lsa_CreateTrustedDomainEx2 c;
+ struct lsa_TrustDomainInfoInfoEx info;
+ struct lsa_TrustDomainInfoAuthInfoInternal auth_info;
+
+ ZERO_STRUCT(auth_info);
+
+ info.domain_name = r->in.info->name;
+ info.netbios_name = r->in.info->name;
+ info.sid = r->in.info->sid;
+ info.trust_direction = LSA_TRUST_DIRECTION_OUTBOUND;
+ info.trust_type = LSA_TRUST_TYPE_DOWNLEVEL;
+ info.trust_attributes = 0;
+
+ c.in.policy_handle = r->in.policy_handle;
+ c.in.info = &info;
+ c.in.auth_info = &auth_info;
+ c.in.access_mask = r->in.access_mask;
+ c.out.trustdom_handle = r->out.trustdom_handle;
+
+ return _lsa_CreateTrustedDomainEx2(p, &c);
}
/***************************************************************************