diff options
author | Andrew Tridgell <tridge@samba.org> | 2003-12-02 10:04:10 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2003-12-02 10:04:10 +0000 |
commit | 16c688c9eaa7f4124553872e9d30273c2507df87 (patch) | |
tree | 6c37bd7750a993a9ba400f550aba00e7deb242c8 /source4/torture | |
parent | 9ec42697604b46b7b43919c665e479f105a0226c (diff) | |
download | samba-16c688c9eaa7f4124553872e9d30273c2507df87.tar.gz samba-16c688c9eaa7f4124553872e9d30273c2507df87.tar.bz2 samba-16c688c9eaa7f4124553872e9d30273c2507df87.zip |
added netr_AccountSync(), another NT_STATUS_NOT_IMPLEMENTED call
according to w2k3
(This used to be commit b2ca00ebc57774000af2de6132c29db4c6daae28)
Diffstat (limited to 'source4/torture')
-rw-r--r-- | source4/torture/rpc/netlogon.c | 41 |
1 files changed, 40 insertions, 1 deletions
diff --git a/source4/torture/rpc/netlogon.c b/source4/torture/rpc/netlogon.c index 07776026d0..89f1a0132b 100644 --- a/source4/torture/rpc/netlogon.c +++ b/source4/torture/rpc/netlogon.c @@ -393,6 +393,41 @@ static BOOL test_AccountDeltas(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx) return ret; } +/* + try a netlogon AccountSync +*/ +static BOOL test_AccountSync(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx) +{ + NTSTATUS status; + struct netr_AccountSync r; + struct netr_CredentialState creds; + BOOL ret = True; + + if (!test_SetupCredentials(p, mem_ctx, &creds)) { + return False; + } + + r.in.logonserver = talloc_asprintf(mem_ctx, "\\\\%s", dcerpc_server_name(p)); + r.in.computername = lp_netbios_name(); + ZERO_STRUCT(r.in.return_authenticator); + creds_client_authenticator(&creds, &r.in.credential); + ZERO_STRUCT(r.in.recordid); + r.in.reference=0; + r.in.level=0; + r.in.buffersize=100; + + printf("Testing AccountSync\n"); + + /* w2k3 returns "NOT IMPLEMENTED" for this call */ + status = dcerpc_netr_AccountSync(p, mem_ctx, &r); + if (!NT_STATUS_EQUAL(status, NT_STATUS_NOT_IMPLEMENTED)) { + printf("AccountSync - %s\n", nt_errstr(status)); + ret = False; + } + + return ret; +} + BOOL torture_rpc_netlogon(int dummy) { @@ -413,7 +448,7 @@ BOOL torture_rpc_netlogon(int dummy) p->flags |= DCERPC_DEBUG_PRINT_BOTH; - if (!test_AccountDeltas(p, mem_ctx)) { + if (!test_AccountSync(p, mem_ctx)) { ret = False; } return ret; @@ -442,6 +477,10 @@ BOOL torture_rpc_netlogon(int dummy) ret = False; } + if (!test_AccountDeltas(p, mem_ctx)) { + ret = False; + } + torture_rpc_close(p); return ret; |