summaryrefslogtreecommitdiff
path: root/source4/torture
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-05-27 04:13:58 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:56:19 -0500
commitdb3c011977e9aad535be298d64fa63af61c0669c (patch)
tree0add1b6fa4d8e2433caede7654a8c727ee4c5995 /source4/torture
parent39a236883ee4015980ff3d3cab8a8e5fec858502 (diff)
downloadsamba-db3c011977e9aad535be298d64fa63af61c0669c.tar.gz
samba-db3c011977e9aad535be298d64fa63af61c0669c.tar.bz2
samba-db3c011977e9aad535be298d64fa63af61c0669c.zip
r917: - added the start of a LSA server to samba4.
- added start of QueryDomainInfo in samr server "net rpc info" from samba3 now works against a samba4 server. I suspect join will work fairly soon. (This used to be commit 0a2c6a1062d0e364356853001f5f39bdb542f453)
Diffstat (limited to 'source4/torture')
-rw-r--r--source4/torture/rpc/lsa.c14
-rw-r--r--source4/torture/rpc/samr.c11
2 files changed, 13 insertions, 12 deletions
diff --git a/source4/torture/rpc/lsa.c b/source4/torture/rpc/lsa.c
index 306197dcf2..031070caa6 100644
--- a/source4/torture/rpc/lsa.c
+++ b/source4/torture/rpc/lsa.c
@@ -51,7 +51,7 @@ static BOOL test_OpenPolicy(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
r.in.system_name = &system_name;
r.in.attr = &attr;
- r.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r.out.handle = &handle;
status = dcerpc_lsa_OpenPolicy(p, mem_ctx, &r);
@@ -88,7 +88,7 @@ static BOOL test_OpenPolicy2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
r.in.system_name = "\\";
r.in.attr = &attr;
- r.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r.out.handle = handle;
status = dcerpc_lsa_OpenPolicy2(p, mem_ctx, &r);
@@ -267,7 +267,7 @@ static BOOL test_CreateAccount(struct dcerpc_pipe *p,
r.in.handle = handle;
r.in.sid = newsid;
- r.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r.out.acct_handle = &acct_handle;
status = dcerpc_lsa_CreateAccount(p, mem_ctx, &r);
@@ -303,7 +303,7 @@ static BOOL test_CreateTrustedDomain(struct dcerpc_pipe *p,
r.in.handle = handle;
r.in.info = &trustinfo;
- r.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r.out.dom_handle = &dom_handle;
status = dcerpc_lsa_CreateTrustedDomain(p, mem_ctx, &r);
@@ -348,7 +348,7 @@ static BOOL test_CreateSecret(struct dcerpc_pipe *p,
init_lsa_Name(&r.in.name, secname);
r.in.handle = handle;
- r.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r.out.sec_handle = &sec_handle;
status = dcerpc_lsa_CreateSecret(p, mem_ctx, &r);
@@ -358,7 +358,7 @@ static BOOL test_CreateSecret(struct dcerpc_pipe *p,
}
r2.in.handle = handle;
- r2.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r2.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r2.in.name = r.in.name;
r2.out.sec_handle = &sec_handle2;
@@ -501,7 +501,7 @@ static BOOL test_OpenAccount(struct dcerpc_pipe *p,
r.in.handle = handle;
r.in.sid = sid;
- r.in.desired_access = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
r.out.acct_handle = &acct_handle;
status = dcerpc_lsa_OpenAccount(p, mem_ctx, &r);
diff --git a/source4/torture/rpc/samr.c b/source4/torture/rpc/samr.c
index 9d90a8b136..a1b01b533f 100644
--- a/source4/torture/rpc/samr.c
+++ b/source4/torture/rpc/samr.c
@@ -2562,7 +2562,8 @@ static BOOL test_CreateDomainGroup(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
return True;
}
- if (NT_STATUS_EQUAL(status, NT_STATUS_GROUP_EXISTS)) {
+ if (NT_STATUS_EQUAL(status, NT_STATUS_GROUP_EXISTS) ||
+ NT_STATUS_EQUAL(status, NT_STATUS_USER_EXISTS)) {
if (!test_DeleteGroup_byname(p, mem_ctx, domain_handle, r.in.name->name)) {
return False;
}
@@ -2639,6 +2640,10 @@ static BOOL test_OpenDomain(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
return False;
}
+ if (!test_QuerySecurity(p, mem_ctx, &domain_handle)) {
+ ret = False;
+ }
+
if (!test_RemoveMemberFromForeignDomain(p, mem_ctx, &domain_handle)) {
ret = False;
}
@@ -2659,10 +2664,6 @@ static BOOL test_OpenDomain(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
ret = False;
}
- if (!test_QuerySecurity(p, mem_ctx, &domain_handle)) {
- ret = False;
- }
-
if (!test_QueryDomainInfo(p, mem_ctx, &domain_handle)) {
ret = False;
}