summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/Makefile.in3
-rw-r--r--source3/include/proto.h24
-rw-r--r--source3/include/rpc_dce.h16
-rw-r--r--source3/rpc_parse/parse_misc.c28
-rw-r--r--source3/rpc_parse/parse_rpc.c110
5 files changed, 6 insertions, 175 deletions
diff --git a/source3/Makefile.in b/source3/Makefile.in
index b980b7f25c..a4b71f0765 100644
--- a/source3/Makefile.in
+++ b/source3/Makefile.in
@@ -356,8 +356,7 @@ LIBNDR_GEN_OBJ = librpc/gen_ndr/ndr_wkssvc.o \
# that requires knowledge of security contexts
RPC_PARSE_OBJ1 = rpc_parse/parse_prs.o rpc_parse/parse_misc.o
-RPC_PARSE_OBJ2 = rpc_parse/parse_rpc.o \
- rpc_client/init_netlogon.o \
+RPC_PARSE_OBJ2 = rpc_client/init_netlogon.o \
rpc_client/init_lsa.o
LIBREPLACE_OBJ = @LIBREPLACE_OBJS@
diff --git a/source3/include/proto.h b/source3/include/proto.h
index cfa68da723..4e36052b19 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -4838,6 +4838,11 @@ void set_profile_level(int level, struct server_id src);
bool profile_setup(struct messaging_context *msg_ctx, bool rdonly);
/* The following definitions come from rpc_client/cli_pipe.c */
+bool smb_register_ndr_interface(const struct ndr_interface_table *interface);
+const struct ndr_interface_table *get_iface_from_syntax(
+ const struct ndr_syntax_id *syntax);
+const char *get_pipe_name_from_syntax(TALLOC_CTX *mem_ctx,
+ const struct ndr_syntax_id *syntax);
struct tevent_req *rpc_api_pipe_req_send(TALLOC_CTX *mem_ctx,
struct event_context *ev,
@@ -5045,8 +5050,6 @@ NTSTATUS cli_do_rpc_ndr(struct rpc_pipe_client *cli,
/* The following definitions come from rpc_parse/parse_misc.c */
bool smb_io_time(const char *desc, NTTIME *nttime, prs_struct *ps, int depth);
-bool smb_io_uuid(const char *desc, struct GUID *uuid,
- prs_struct *ps, int depth);
/* The following definitions come from rpc_parse/parse_prs.c */
@@ -5096,23 +5099,6 @@ bool prs_uint32s(bool charmode, const char *name, prs_struct *ps, int depth, uin
bool prs_init_data_blob(prs_struct *prs, DATA_BLOB *blob, TALLOC_CTX *mem_ctx);
bool prs_data_blob(prs_struct *prs, DATA_BLOB *blob, TALLOC_CTX *mem_ctx);
-/* The following definitions come from rpc_parse/parse_rpc.c */
-
-bool smb_register_ndr_interface(const struct ndr_interface_table *interface);
-const struct ndr_interface_table *get_iface_from_syntax(
- const struct ndr_syntax_id *syntax);
-const char *get_pipe_name_from_syntax(TALLOC_CTX *mem_ctx,
- const struct ndr_syntax_id *syntax);
-NTSTATUS dcerpc_pull_dcerpc_bind(TALLOC_CTX *mem_ctx,
- const DATA_BLOB *blob,
- struct dcerpc_bind *r);
-bool smb_io_rpc_hdr_resp(const char *desc, RPC_HDR_RESP *rpc, prs_struct *ps, int depth);
-void init_rpc_hdr_auth(RPC_HDR_AUTH *rai,
- uint8 auth_type, uint8 auth_level,
- uint8 auth_pad_len,
- uint32 auth_context_id);
-bool smb_io_rpc_hdr_auth(const char *desc, RPC_HDR_AUTH *rai, prs_struct *ps, int depth);
-
/* The following definitions come from rpc_server/srv_eventlog_nt.c */
/* The following definitions come from rpc_server/rpc_handles.c */
diff --git a/source3/include/rpc_dce.h b/source3/include/rpc_dce.h
index 202382781e..e663a56ad6 100644
--- a/source3/include/rpc_dce.h
+++ b/source3/include/rpc_dce.h
@@ -37,24 +37,8 @@
#define RPC_HDR_REQ_LEN 8
-/* RPC_HDR_RESP - ms response rpc header */
-typedef struct rpc_hdr_resp_info {
- uint32 alloc_hint; /* allocation hint - data size (bytes) minus header and tail. */
- uint16 context_id; /* 0 - presentation context identifier */
- uint8 cancel_count; /* 0 - cancel count */
- uint8 reserved; /* 0 - reserved. */
-} RPC_HDR_RESP;
-
#define RPC_HDR_RESP_LEN 8
-/* RPC_HDR_AUTH */
-typedef struct rpc_hdr_auth_info {
- uint8 auth_type; /* See XXX_AUTH_TYPE above. */
- uint8 auth_level; /* See RPC_PIPE_AUTH_XXX_LEVEL above. */
- uint8 auth_pad_len;
- uint8 auth_reserved;
- uint32 auth_context_id;
-} RPC_HDR_AUTH;
#define RPC_HDR_AUTH_LEN 8
diff --git a/source3/rpc_parse/parse_misc.c b/source3/rpc_parse/parse_misc.c
index c000923b9e..21b4e56e54 100644
--- a/source3/rpc_parse/parse_misc.c
+++ b/source3/rpc_parse/parse_misc.c
@@ -57,31 +57,3 @@ bool smb_io_time(const char *desc, NTTIME *nttime, prs_struct *ps, int depth)
return True;
}
-
-/*******************************************************************
- Reads or writes a struct GUID
-********************************************************************/
-
-bool smb_io_uuid(const char *desc, struct GUID *uuid,
- prs_struct *ps, int depth)
-{
- if (uuid == NULL)
- return False;
-
- prs_debug(ps, depth, desc, "smb_io_uuid");
- depth++;
-
- if(!prs_uint32 ("data ", ps, depth, &uuid->time_low))
- return False;
- if(!prs_uint16 ("data ", ps, depth, &uuid->time_mid))
- return False;
- if(!prs_uint16 ("data ", ps, depth, &uuid->time_hi_and_version))
- return False;
-
- if(!prs_uint8s (False, "data ", ps, depth, uuid->clock_seq, sizeof(uuid->clock_seq)))
- return False;
- if(!prs_uint8s (False, "data ", ps, depth, uuid->node, sizeof(uuid->node)))
- return False;
-
- return True;
-}
diff --git a/source3/rpc_parse/parse_rpc.c b/source3/rpc_parse/parse_rpc.c
deleted file mode 100644
index 8ece183251..0000000000
--- a/source3/rpc_parse/parse_rpc.c
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Unix SMB/CIFS implementation.
- * RPC Pipe client / server routines
- * Copyright (C) Andrew Tridgell 1992-1997,
- * Copyright (C) Luke Kenneth Casson Leighton 1996-1997,
- * Copyright (C) Paul Ashton 1997.
- * Copyright (C) Jeremy Allison 1999.
- * Copyright (C) Simo Sorce 2010
- *
- * 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/>.
- */
-
-#include "includes.h"
-#include "librpc/gen_ndr/ndr_dcerpc.h"
-
-#undef DBGC_CLASS
-#define DBGC_CLASS DBGC_RPC_PARSE
-
-NTSTATUS dcerpc_pull_dcerpc_bind(TALLOC_CTX *mem_ctx,
- const DATA_BLOB *blob,
- struct dcerpc_bind *r)
-{
- enum ndr_err_code ndr_err;
-
- ndr_err = ndr_pull_struct_blob(blob, mem_ctx, r,
- (ndr_pull_flags_fn_t)ndr_pull_dcerpc_bind);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- return ndr_map_error2ntstatus(ndr_err);
- }
-
- return NT_STATUS_OK;
-}
-
-/*******************************************************************
- Reads or writes an RPC_HDR_RESP structure.
-********************************************************************/
-
-bool smb_io_rpc_hdr_resp(const char *desc, RPC_HDR_RESP *rpc, prs_struct *ps, int depth)
-{
- if (rpc == NULL)
- return False;
-
- prs_debug(ps, depth, desc, "smb_io_rpc_hdr_resp");
- depth++;
-
- if(!prs_uint32("alloc_hint", ps, depth, &rpc->alloc_hint))
- return False;
- if(!prs_uint16("context_id", ps, depth, &rpc->context_id))
- return False;
- if(!prs_uint8 ("cancel_ct ", ps, depth, &rpc->cancel_count))
- return False;
- if(!prs_uint8 ("reserved ", ps, depth, &rpc->reserved))
- return False;
- return True;
-}
-
-/*******************************************************************
- Inits an RPC_HDR_AUTH structure.
-********************************************************************/
-
-void init_rpc_hdr_auth(RPC_HDR_AUTH *rai,
- uint8 auth_type, uint8 auth_level,
- uint8 auth_pad_len,
- uint32 auth_context_id)
-{
- rai->auth_type = auth_type;
- rai->auth_level = auth_level;
- rai->auth_pad_len = auth_pad_len;
- rai->auth_reserved = 0;
- rai->auth_context_id = auth_context_id;
-}
-
-/*******************************************************************
- Reads or writes an RPC_HDR_AUTH structure.
- NB This writes UNALIGNED. Ensure you're correctly aligned before
- calling.
-********************************************************************/
-
-bool smb_io_rpc_hdr_auth(const char *desc, RPC_HDR_AUTH *rai, prs_struct *ps, int depth)
-{
- if (rai == NULL)
- return False;
-
- prs_debug(ps, depth, desc, "smb_io_rpc_hdr_auth");
- depth++;
-
- if(!prs_uint8 ("auth_type ", ps, depth, &rai->auth_type))
- return False;
- if(!prs_uint8 ("auth_level ", ps, depth, &rai->auth_level))
- return False;
- if(!prs_uint8 ("auth_pad_len ", ps, depth, &rai->auth_pad_len))
- return False;
- if(!prs_uint8 ("auth_reserved", ps, depth, &rai->auth_reserved))
- return False;
- if(!prs_uint32("auth_context_id", ps, depth, &rai->auth_context_id))
- return False;
-
- return True;
-}