summaryrefslogtreecommitdiff
path: root/source4/torture/rpc
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-10-21 02:34:45 +0200
committerGünther Deschner <gd@samba.org>2008-10-27 19:33:22 +0100
commit7c3d1dd8a978d0cdde74e054e6b3658323b09649 (patch)
tree48bfd8e0aa1e187aa2eaeb0c9144325407c54448 /source4/torture/rpc
parent8bcc939a8c2762abaa31029411e5f2d3e1c385f4 (diff)
downloadsamba-7c3d1dd8a978d0cdde74e054e6b3658323b09649.tar.gz
samba-7c3d1dd8a978d0cdde74e054e6b3658323b09649.tar.bz2
samba-7c3d1dd8a978d0cdde74e054e6b3658323b09649.zip
s4-lsa: merge lsa_QueryTrustedDomainInfoBySid from s3 lsa idl.
Guenther
Diffstat (limited to 'source4/torture/rpc')
-rw-r--r--source4/torture/rpc/lsa.c3
-rw-r--r--source4/torture/rpc/lsa_lookup.c7
2 files changed, 7 insertions, 3 deletions
diff --git a/source4/torture/rpc/lsa.c b/source4/torture/rpc/lsa.c
index e065c294d9..34e3c1b78d 100644
--- a/source4/torture/rpc/lsa.c
+++ b/source4/torture/rpc/lsa.c
@@ -1838,7 +1838,7 @@ static bool test_query_each_TrustDom(struct dcerpc_pipe *p,
for (j=0; j < ARRAY_SIZE(levels); j++) {
struct lsa_QueryTrustedDomainInfoBySid q;
- union lsa_TrustedDomainInfo info;
+ union lsa_TrustedDomainInfo *info = NULL;
if (!domains->domains[i].sid) {
continue;
@@ -1848,6 +1848,7 @@ static bool test_query_each_TrustDom(struct dcerpc_pipe *p,
q.in.dom_sid = domains->domains[i].sid;
q.in.level = levels[j];
q.out.info = &info;
+
status = dcerpc_lsa_QueryTrustedDomainInfoBySid(p, mem_ctx, &q);
if (!NT_STATUS_IS_OK(status) && ok[j]) {
printf("QueryTrustedDomainInfoBySid level %d failed - %s\n",
diff --git a/source4/torture/rpc/lsa_lookup.c b/source4/torture/rpc/lsa_lookup.c
index 9c817a7061..beb299b597 100644
--- a/source4/torture/rpc/lsa_lookup.c
+++ b/source4/torture/rpc/lsa_lookup.c
@@ -192,6 +192,7 @@ static bool get_downleveltrust(struct torture_context *tctx, struct dcerpc_pipe
for (i=0; i<domains.count; i++) {
struct lsa_QueryTrustedDomainInfoBySid q;
+ union lsa_TrustedDomainInfo *info = NULL;
if (domains.domains[i].sid == NULL)
continue;
@@ -199,11 +200,13 @@ static bool get_downleveltrust(struct torture_context *tctx, struct dcerpc_pipe
q.in.handle = handle;
q.in.dom_sid = domains.domains[i].sid;
q.in.level = 6;
+ q.out.info = &info;
+
status = dcerpc_lsa_QueryTrustedDomainInfoBySid(p, tctx, &q);
if (!NT_STATUS_IS_OK(status)) continue;
- if ((q.out.info->info_ex.trust_direction & 2) &&
- (q.out.info->info_ex.trust_type == 1)) {
+ if ((info->info_ex.trust_direction & 2) &&
+ (info->info_ex.trust_type == 1)) {
*sid = domains.domains[i].sid;
return true;
}