From e74b3ed6f195e66cb5fa0f387cea0f59fb66711b Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sun, 9 Jan 2005 11:32:12 +0000 Subject: r4618: - tidied up the alter_context client code a bit - there is no alter_nak or alter_ack packet, its all done in an alter_response - auto-allocated the contex_ids - tried to fix up the dcom code to work again with alter_context. Jelmer, please take a look :) (This used to be commit dd1c54add8884376601f2f8a56c01bfb8add030c) --- source4/torture/rpc/alter_context.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'source4/torture') diff --git a/source4/torture/rpc/alter_context.c b/source4/torture/rpc/alter_context.c index d10604fa04..2c6f209404 100644 --- a/source4/torture/rpc/alter_context.c +++ b/source4/torture/rpc/alter_context.c @@ -49,12 +49,19 @@ BOOL torture_rpc_alter_context(void) } printf("Opening secondary DSSETUP context\n"); - status = dcerpc_secondary_context(p, &p2, 1, DCERPC_DSSETUP_UUID, DCERPC_DSSETUP_VERSION); + status = dcerpc_secondary_context(p, &p2, DCERPC_DSSETUP_UUID, DCERPC_DSSETUP_VERSION); if (!NT_STATUS_IS_OK(status)) { printf("dcerpc_alter_context failed - %s\n", nt_errstr(status)); return False; } + printf("Opening bad secondary connection\n"); + status = dcerpc_secondary_context(p, &p2, DCERPC_DSSETUP_UUID, DCERPC_DSSETUP_VERSION+100); + if (NT_STATUS_IS_OK(status)) { + printf("dcerpc_alter_context with wrong version should fail\n"); + return False; + } + printf("testing DSSETUP pipe operations\n"); ret &= test_DsRoleGetPrimaryDomainInformation(p2, mem_ctx); -- cgit