summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--librpc/ndr/libndr.h6
-rw-r--r--librpc/ndr/ndr.c15
-rw-r--r--librpc/rpc/binding.c6
-rw-r--r--source3/rpc_client/cli_pipe.c6
-rw-r--r--source3/rpc_server/epmapper/srv_epmapper.c4
-rw-r--r--source3/rpc_server/rpc_ncacn_np.c4
-rw-r--r--source3/rpc_server/srv_pipe.c6
-rw-r--r--source4/librpc/rpc/dcerpc_auth.c4
-rw-r--r--source4/librpc/rpc/pyrpc.c5
-rw-r--r--source4/rpc_server/dcerpc_server.c12
-rw-r--r--source4/rpc_server/epmapper/rpc_epmapper.c4
-rw-r--r--source4/torture/rpc/epmapper.c2
12 files changed, 37 insertions, 37 deletions
diff --git a/librpc/ndr/libndr.h b/librpc/ndr/libndr.h
index 36adae91c0..dafce6451a 100644
--- a/librpc/ndr/libndr.h
+++ b/librpc/ndr/libndr.h
@@ -353,9 +353,9 @@ typedef void (*ndr_print_function_t)(struct ndr_print *, const char *, int, cons
#include "../libcli/util/error.h"
#include "librpc/gen_ndr/misc.h"
-extern const struct ndr_syntax_id ndr_transfer_syntax;
-extern const struct ndr_syntax_id ndr64_transfer_syntax;
-extern const struct ndr_syntax_id null_ndr_syntax_id;
+extern const struct ndr_syntax_id ndr_transfer_syntax_ndr;
+extern const struct ndr_syntax_id ndr_transfer_syntax_ndr64;
+extern const struct ndr_syntax_id ndr_syntax_id_null;
struct ndr_interface_call_pipe {
const char *name;
diff --git a/librpc/ndr/ndr.c b/librpc/ndr/ndr.c
index 7cb6e214ba..2279d1c1c3 100644
--- a/librpc/ndr/ndr.c
+++ b/librpc/ndr/ndr.c
@@ -1,20 +1,21 @@
-/*
+/*
Unix SMB/CIFS implementation.
libndr interface
Copyright (C) Andrew Tridgell 2003
-
+ Copyright (C) Jelmer Vernooij 2005-2008
+
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
-
+
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@@ -33,17 +34,17 @@
#define NDR_BASE_MARSHALL_SIZE 1024
/* this guid indicates NDR encoding in a protocol tower */
-const struct ndr_syntax_id ndr_transfer_syntax = {
+const struct ndr_syntax_id ndr_transfer_syntax_ndr = {
{ 0x8a885d04, 0x1ceb, 0x11c9, {0x9f, 0xe8}, {0x08,0x00,0x2b,0x10,0x48,0x60} },
2
};
-const struct ndr_syntax_id ndr64_transfer_syntax = {
+const struct ndr_syntax_id ndr_transfer_syntax_ndr64 = {
{ 0x71710533, 0xbeba, 0x4937, {0x83, 0x19}, {0xb5,0xdb,0xef,0x9c,0xcc,0x36} },
1
};
-const struct ndr_syntax_id null_ndr_syntax_id = {
+const struct ndr_syntax_id ndr_syntax_id_null = {
{ 0, 0, 0, { 0, 0 }, { 0, 0, 0, 0, 0, 0 } },
0
};
diff --git a/librpc/rpc/binding.c b/librpc/rpc/binding.c
index 381e3aedb5..f7fbbbc548 100644
--- a/librpc/rpc/binding.c
+++ b/librpc/rpc/binding.c
@@ -105,11 +105,11 @@ const char *epm_floor_string(TALLOC_CTX *mem_ctx, struct epm_floor *epm_floor)
/* lhs is used: UUID */
char *uuidstr;
- if (GUID_equal(&syntax.uuid, &ndr_transfer_syntax.uuid)) {
+ if (GUID_equal(&syntax.uuid, &ndr_transfer_syntax_ndr.uuid)) {
return "NDR";
}
- if (GUID_equal(&syntax.uuid, &ndr64_transfer_syntax.uuid)) {
+ if (GUID_equal(&syntax.uuid, &ndr_transfer_syntax_ndr64.uuid)) {
return "NDR64";
}
@@ -838,7 +838,7 @@ _PUBLIC_ NTSTATUS dcerpc_binding_build_tower(TALLOC_CTX *mem_ctx,
tower->floors[1].lhs.protocol = EPM_PROTOCOL_UUID;
tower->floors[1].lhs.lhs_data = dcerpc_floor_pack_lhs_data(tower->floors,
- &ndr_transfer_syntax);
+ &ndr_transfer_syntax_ndr);
tower->floors[1].rhs.uuid.unknown = data_blob_talloc_zero(tower->floors, 2);
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c
index 12f911b9fd..db89b3165b 100644
--- a/source3/rpc_client/cli_pipe.c
+++ b/source3/rpc_client/cli_pipe.c
@@ -2280,7 +2280,7 @@ static NTSTATUS rpc_pipe_open_tcp_port(TALLOC_CTX *mem_ctx, const char *host,
}
result->abstract_syntax = *abstract_syntax;
- result->transfer_syntax = ndr_transfer_syntax;
+ result->transfer_syntax = ndr_transfer_syntax_ndr;
result->desthost = talloc_strdup(result, host);
result->srv_name_slash = talloc_asprintf_strupper_m(
@@ -2509,7 +2509,7 @@ NTSTATUS rpc_pipe_open_ncalrpc(TALLOC_CTX *mem_ctx, const char *socket_path,
}
result->abstract_syntax = *abstract_syntax;
- result->transfer_syntax = ndr_transfer_syntax;
+ result->transfer_syntax = ndr_transfer_syntax_ndr;
result->desthost = get_myname(result);
result->srv_name_slash = talloc_asprintf_strupper_m(
@@ -2605,7 +2605,7 @@ static NTSTATUS rpc_pipe_open_np(struct cli_state *cli,
}
result->abstract_syntax = *abstract_syntax;
- result->transfer_syntax = ndr_transfer_syntax;
+ result->transfer_syntax = ndr_transfer_syntax_ndr;
result->desthost = talloc_strdup(result, cli_state_remote_name(cli));
result->srv_name_slash = talloc_asprintf_strupper_m(
result, "\\\\%s", result->desthost);
diff --git a/source3/rpc_server/epmapper/srv_epmapper.c b/source3/rpc_server/epmapper/srv_epmapper.c
index 58f2220264..cb99bde528 100644
--- a/source3/rpc_server/epmapper/srv_epmapper.c
+++ b/source3/rpc_server/epmapper/srv_epmapper.c
@@ -904,8 +904,8 @@ error_status_t _epm_Map(struct pipes_struct *p,
dcerpc_floor_get_lhs_data(&floors[1], &ifid);
if (floors[1].lhs.protocol != EPM_PROTOCOL_UUID ||
- !GUID_equal(&ifid.uuid, &ndr_transfer_syntax.uuid) ||
- ifid.if_version != ndr_transfer_syntax.if_version) {
+ !GUID_equal(&ifid.uuid, &ndr_transfer_syntax_ndr.uuid) ||
+ ifid.if_version != ndr_transfer_syntax_ndr.if_version) {
rc = EPMAPPER_STATUS_NO_MORE_ENTRIES;
goto done;
}
diff --git a/source3/rpc_server/rpc_ncacn_np.c b/source3/rpc_server/rpc_ncacn_np.c
index 37c30791b2..f1b7b43b46 100644
--- a/source3/rpc_server/rpc_ncacn_np.c
+++ b/source3/rpc_server/rpc_ncacn_np.c
@@ -477,7 +477,7 @@ NTSTATUS rpc_pipe_open_internal(TALLOC_CTX *mem_ctx,
}
result->abstract_syntax = *abstract_syntax;
- result->transfer_syntax = ndr_transfer_syntax;
+ result->transfer_syntax = ndr_transfer_syntax_ndr;
if (remote_address == NULL) {
struct tsocket_address *local;
@@ -675,7 +675,7 @@ static NTSTATUS rpc_pipe_open_external(TALLOC_CTX *mem_ctx,
}
result->abstract_syntax = *abstract_syntax;
- result->transfer_syntax = ndr_transfer_syntax;
+ result->transfer_syntax = ndr_transfer_syntax_ndr;
result->desthost = get_myname(result);
result->srv_name_slash = talloc_asprintf_strupper_m(
diff --git a/source3/rpc_server/srv_pipe.c b/source3/rpc_server/srv_pipe.c
index 4330a7ddc3..0bc48b1a06 100644
--- a/source3/rpc_server/srv_pipe.c
+++ b/source3/rpc_server/srv_pipe.c
@@ -341,7 +341,7 @@ static bool check_bind_req(struct pipes_struct *p,
/* we have to check all now since win2k introduced a new UUID on the lsaprpc pipe */
if (rpc_srv_pipe_exists_by_id(abstract) &&
- ndr_syntax_id_equal(transfer, &ndr_transfer_syntax)) {
+ ndr_syntax_id_equal(transfer, &ndr_transfer_syntax_ndr)) {
DEBUG(3, ("check_bind_req: %s -> %s rpc service\n",
rpc_srv_get_pipe_cli_name(abstract),
rpc_srv_get_pipe_srv_name(abstract)));
@@ -759,7 +759,7 @@ static bool api_pipe_bind_req(struct pipes_struct *p,
/* Rejection reason: abstract syntax not supported */
bind_ack_ctx.result = DCERPC_BIND_PROVIDER_REJECT;
bind_ack_ctx.reason = DCERPC_BIND_REASON_ASYNTAX;
- bind_ack_ctx.syntax = null_ndr_syntax_id;
+ bind_ack_ctx.syntax = ndr_syntax_id_null;
}
/*
@@ -1107,7 +1107,7 @@ static bool api_pipe_alter_context(struct pipes_struct *p,
/* Rejection reason: abstract syntax not supported */
bind_ack_ctx.result = DCERPC_BIND_PROVIDER_REJECT;
bind_ack_ctx.reason = DCERPC_BIND_REASON_ASYNTAX;
- bind_ack_ctx.syntax = null_ndr_syntax_id;
+ bind_ack_ctx.syntax = ndr_syntax_id_null;
}
/*
diff --git a/source4/librpc/rpc/dcerpc_auth.c b/source4/librpc/rpc/dcerpc_auth.c
index f119b426d9..cedcdd1bec 100644
--- a/source4/librpc/rpc/dcerpc_auth.c
+++ b/source4/librpc/rpc/dcerpc_auth.c
@@ -41,9 +41,9 @@ static NTSTATUS dcerpc_init_syntaxes(const struct ndr_interface_table *table,
syntax->if_version = table->syntax_id.if_version;
if (pipe_flags & DCERPC_NDR64) {
- *transfer_syntax = ndr64_transfer_syntax;
+ *transfer_syntax = ndr_transfer_syntax_ndr64;
} else {
- *transfer_syntax = ndr_transfer_syntax;
+ *transfer_syntax = ndr_transfer_syntax_ndr;
}
return NT_STATUS_OK;
diff --git a/source4/librpc/rpc/pyrpc.c b/source4/librpc/rpc/pyrpc.c
index 23961e7a07..67462f18f3 100644
--- a/source4/librpc/rpc/pyrpc.c
+++ b/source4/librpc/rpc/pyrpc.c
@@ -262,10 +262,9 @@ static PyObject *py_iface_alter_context(PyObject *self, PyObject *args, PyObject
return NULL;
if (py_transfer_syntax == Py_None) {
- transfer_syntax = ndr_transfer_syntax;
+ transfer_syntax = ndr_transfer_syntax_ndr;
} else {
- if (!ndr_syntax_from_py_object(py_transfer_syntax,
- &transfer_syntax))
+ if (!ndr_syntax_from_py_object(py_transfer_syntax, &transfer_syntax))
return NULL;
}
diff --git a/source4/rpc_server/dcerpc_server.c b/source4/rpc_server/dcerpc_server.c
index a16e6ac9d5..389cbe3666 100644
--- a/source4/rpc_server/dcerpc_server.c
+++ b/source4/rpc_server/dcerpc_server.c
@@ -544,8 +544,8 @@ static NTSTATUS dcesrv_bind(struct dcesrv_call_state *call)
transfer_syntax_version = call->pkt.u.bind.ctx_list[0].transfer_syntaxes[0].if_version;
transfer_syntax_uuid = &call->pkt.u.bind.ctx_list[0].transfer_syntaxes[0].uuid;
- if (!GUID_equal(&ndr_transfer_syntax.uuid, transfer_syntax_uuid) != 0 ||
- ndr_transfer_syntax.if_version != transfer_syntax_version) {
+ if (!GUID_equal(&ndr_transfer_syntax_ndr.uuid, transfer_syntax_uuid) != 0 ||
+ ndr_transfer_syntax_ndr.if_version != transfer_syntax_version) {
char *uuid_str = GUID_string(call, transfer_syntax_uuid);
/* we only do NDR encoded dcerpc */
DEBUG(0,("Non NDR transfer syntax requested - %s\n", uuid_str));
@@ -657,7 +657,7 @@ static NTSTATUS dcesrv_bind(struct dcesrv_call_state *call)
}
pkt.u.bind_ack.ctx_list[0].result = result;
pkt.u.bind_ack.ctx_list[0].reason = reason;
- pkt.u.bind_ack.ctx_list[0].syntax = ndr_transfer_syntax;
+ pkt.u.bind_ack.ctx_list[0].syntax = ndr_transfer_syntax_ndr;
pkt.u.bind_ack.auth_info = data_blob(NULL, 0);
status = dcesrv_auth_bind_ack(call, &pkt);
@@ -731,8 +731,8 @@ static NTSTATUS dcesrv_alter_new_context(struct dcesrv_call_state *call, uint32_
transfer_syntax_version = call->pkt.u.alter.ctx_list[0].transfer_syntaxes[0].if_version;
transfer_syntax_uuid = &call->pkt.u.alter.ctx_list[0].transfer_syntaxes[0].uuid;
- if (!GUID_equal(transfer_syntax_uuid, &ndr_transfer_syntax.uuid) ||
- ndr_transfer_syntax.if_version != transfer_syntax_version) {
+ if (!GUID_equal(transfer_syntax_uuid, &ndr_transfer_syntax_ndr.uuid) ||
+ ndr_transfer_syntax_ndr.if_version != transfer_syntax_version) {
/* we only do NDR encoded dcerpc */
return NT_STATUS_RPC_PROTSEQ_NOT_SUPPORTED;
}
@@ -846,7 +846,7 @@ static NTSTATUS dcesrv_alter(struct dcesrv_call_state *call)
}
pkt.u.alter_resp.ctx_list[0].result = result;
pkt.u.alter_resp.ctx_list[0].reason = reason;
- pkt.u.alter_resp.ctx_list[0].syntax = ndr_transfer_syntax;
+ pkt.u.alter_resp.ctx_list[0].syntax = ndr_transfer_syntax_ndr;
pkt.u.alter_resp.auth_info = data_blob(NULL, 0);
pkt.u.alter_resp.secondary_address = "";
diff --git a/source4/rpc_server/epmapper/rpc_epmapper.c b/source4/rpc_server/epmapper/rpc_epmapper.c
index 87bfee6dc3..371a3b5dd5 100644
--- a/source4/rpc_server/epmapper/rpc_epmapper.c
+++ b/source4/rpc_server/epmapper/rpc_epmapper.c
@@ -201,8 +201,8 @@ static error_status_t dcesrv_epm_Map(struct dcesrv_call_state *dce_call, TALLOC_
dcerpc_floor_get_lhs_data(&r->in.map_tower->tower.floors[1], &ndr_syntax);
if (floors[1].lhs.protocol != EPM_PROTOCOL_UUID ||
- !GUID_equal(&ndr_syntax.uuid, &ndr_transfer_syntax.uuid) ||
- ndr_syntax.if_version != ndr_transfer_syntax.if_version) {
+ !GUID_equal(&ndr_syntax.uuid, &ndr_transfer_syntax_ndr.uuid) ||
+ ndr_syntax.if_version != ndr_transfer_syntax_ndr.if_version) {
goto failed;
}
diff --git a/source4/torture/rpc/epmapper.c b/source4/torture/rpc/epmapper.c
index fad6abecf7..c0d8c44e02 100644
--- a/source4/torture/rpc/epmapper.c
+++ b/source4/torture/rpc/epmapper.c
@@ -204,7 +204,7 @@ static bool test_Map_tcpip(struct torture_context *tctx,
ndr_interface_name(&syntax.uuid, syntax.if_version));
dcerpc_floor_get_lhs_data(&t.floors[1], &syntax);
- torture_assert(tctx, ndr_syntax_id_equal(&syntax, &ndr_transfer_syntax),
+ torture_assert(tctx, ndr_syntax_id_equal(&syntax, &ndr_transfer_syntax_ndr),
"epm_Map_tcpip failed: floor 2 is not NDR encoded");
torture_assert(tctx, t.floors[2].lhs.protocol == EPM_PROTOCOL_NCACN,