summaryrefslogtreecommitdiff
path: root/source4/torture
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2003-11-23 21:51:24 +0000
committerAndrew Tridgell <tridge@samba.org>2003-11-23 21:51:24 +0000
commit27b1dbaea64e02eccf07ff6643bffc2991264533 (patch)
treec29400229869335b2812f7686615538c83c010d7 /source4/torture
parent3d0e6b3835379d545189563ce25ffe37ed340703 (diff)
downloadsamba-27b1dbaea64e02eccf07ff6643bffc2991264533.tar.gz
samba-27b1dbaea64e02eccf07ff6643bffc2991264533.tar.bz2
samba-27b1dbaea64e02eccf07ff6643bffc2991264533.zip
* better diagnostics in ndrdump
* added samr_Connect2() (This used to be commit 6b262ca37ca3fc0e3210b4379b2d9e46e1a2d336)
Diffstat (limited to 'source4/torture')
-rw-r--r--source4/torture/rpc/samr.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/source4/torture/rpc/samr.c b/source4/torture/rpc/samr.c
index 07faf2c165..f7006241b5 100644
--- a/source4/torture/rpc/samr.c
+++ b/source4/torture/rpc/samr.c
@@ -857,7 +857,9 @@ static BOOL test_Connect(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
{
NTSTATUS status;
struct samr_Connect r;
+ struct samr_Connect2 r2;
struct samr_Connect4 r4;
+ BOOL ret = True;
r.in.system_name = 0;
r.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
@@ -866,7 +868,17 @@ static BOOL test_Connect(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
status = dcerpc_samr_Connect(p, mem_ctx, &r);
if (!NT_STATUS_IS_OK(status)) {
printf("Connect failed - %s\n", nt_errstr(status));
- return False;
+ ret = False;
+ }
+
+ r2.in.system_name = "";
+ r2.in.access_mask = SEC_RIGHTS_MAXIMUM_ALLOWED;
+ r2.out.handle = handle;
+
+ status = dcerpc_samr_Connect2(p, mem_ctx, &r2);
+ if (!NT_STATUS_IS_OK(status)) {
+ printf("Connect2 failed - %s\n", nt_errstr(status));
+ ret = False;
}
r4.in.system_name = "";
@@ -877,10 +889,10 @@ static BOOL test_Connect(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
status = dcerpc_samr_Connect4(p, mem_ctx, &r4);
if (!NT_STATUS_IS_OK(status)) {
printf("Connect4 failed - %s\n", nt_errstr(status));
- return False;
+ ret = False;
}
- return True;
+ return ret;
}