summaryrefslogtreecommitdiff
path: root/source4/librpc/rpc/dcerpc_auth.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2009-09-17 09:09:48 -0700
committerAndrew Tridgell <tridge@samba.org>2009-09-17 15:19:27 -0700
commitc9b0b89cc06531cb57f89b9f98d33d6e0c300957 (patch)
treee09108a31dae6fa1cef5b7337a6ff1233d3a0443 /source4/librpc/rpc/dcerpc_auth.c
parent056cbf7f816a6d01bc0ef3105eca43b4aeee9116 (diff)
downloadsamba-c9b0b89cc06531cb57f89b9f98d33d6e0c300957.tar.gz
s4-rpc: added NDR64 support
This adds support for the nd464 binding string option
Diffstat (limited to 'source4/librpc/rpc/dcerpc_auth.c')
-rw-r--r--source4/librpc/rpc/dcerpc_auth.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/source4/librpc/rpc/dcerpc_auth.c b/source4/librpc/rpc/dcerpc_auth.c
index 14f0f9deb4b..bca7a8d1860 100644
--- a/source4/librpc/rpc/dcerpc_auth.c
+++ b/source4/librpc/rpc/dcerpc_auth.c
@@ -32,13 +32,18 @@
return the rpc syntax and transfer syntax given the pipe uuid and version
*/
static NTSTATUS dcerpc_init_syntaxes(const struct ndr_interface_table *table,
- struct ndr_syntax_id *syntax,
- struct ndr_syntax_id *transfer_syntax)
+ uint32_t pipe_flags,
+ struct ndr_syntax_id *syntax,
+ struct ndr_syntax_id *transfer_syntax)
{
syntax->uuid = table->syntax_id.uuid;
syntax->if_version = table->syntax_id.if_version;
- *transfer_syntax = ndr_transfer_syntax;
+ if (pipe_flags & DCERPC_NDR64) {
+ *transfer_syntax = ndr64_transfer_syntax;
+ } else {
+ *transfer_syntax = ndr_transfer_syntax;
+ }
return NT_STATUS_OK;
}
@@ -59,7 +64,7 @@ struct composite_context *dcerpc_bind_auth_none_send(TALLOC_CTX *mem_ctx,
c = composite_create(mem_ctx, p->conn->event_ctx);
if (c == NULL) return NULL;
- c->status = dcerpc_init_syntaxes(table,
+ c->status = dcerpc_init_syntaxes(table, p->conn->flags,
&syntax, &transfer_syntax);
if (!NT_STATUS_IS_OK(c->status)) {
DEBUG(2,("Invalid uuid string in "
@@ -242,7 +247,7 @@ struct composite_context *dcerpc_bind_auth_send(TALLOC_CTX *mem_ctx,
state->pipe = p;
- c->status = dcerpc_init_syntaxes(table,
+ c->status = dcerpc_init_syntaxes(table, p->conn->flags,
&syntax,
&transfer_syntax);
if (!composite_is_ok(c)) return c;