1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

s4:rpc_server: Move core functions to core library

Signed-off-by: Samuel Cabrero <scabrero@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
This commit is contained in:
Samuel Cabrero 2019-10-03 19:38:31 +02:00 committed by Andreas Schneider
parent 076ec9173e
commit 491102b5b2
7 changed files with 2808 additions and 2807 deletions

View File

@ -1,4 +1,4 @@
/*
/*
Unix SMB/CIFS implementation.
server side dcerpc authentication code
@ -10,25 +10,24 @@
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 "rpc_server/dcerpc_server.h"
#include "rpc_server/dcerpc_server_proto.h"
#include "librpc/rpc/dcesrv_core.h"
#include "librpc/rpc/dcesrv_core_proto.h"
#include "librpc/gen_ndr/ndr_dcerpc.h"
#include "auth/credentials/credentials.h"
#include "auth/gensec/gensec.h"
#include "auth/auth.h"
#include "param/param.h"
#include "librpc/rpc/rpc_common.h"
static NTSTATUS dcesrv_auth_negotiate_hdr_signing(struct dcesrv_call_state *call,
struct ncacn_packet *pkt)
@ -477,7 +476,7 @@ bool dcesrv_auth_prepare_auth3(struct dcesrv_call_state *call)
/*
parse any auth information from a dcerpc alter request
return false if we can't handle the auth request for some
return false if we can't handle the auth request for some
reason (in which case we send a bind_nak (is this true for here?))
*/
bool dcesrv_auth_alter(struct dcesrv_call_state *call)
@ -637,7 +636,7 @@ bool dcesrv_auth_pkt_pull(struct dcesrv_call_state *call,
return true;
}
/*
/*
push a signed or sealed dcerpc request packet into a blob
*/
bool dcesrv_auth_pkt_push(struct dcesrv_call_state *call,

File diff suppressed because it is too large Load Diff

View File

@ -1,27 +1,27 @@
/*
/*
Unix SMB/CIFS implementation.
endpoint server for the mgmt pipe
Copyright (C) Jelmer Vernooij 2006
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 "rpc_server/dcerpc_server.h"
#include "rpc_server/dcerpc_server_proto.h"
#include "librpc/rpc/dcesrv_core.h"
#include "librpc/rpc/dcesrv_core_proto.h"
#include "librpc/gen_ndr/ndr_mgmt.h"
#define DCESRV_INTERFACE_MGMT_BIND(context, iface) \
@ -42,8 +42,8 @@ static NTSTATUS dcesrv_interface_mgmt_bind(struct dcesrv_connection_context *con
return dcesrv_interface_bind_allow_connect(context, iface);
}
/*
mgmt_inq_if_ids
/*
mgmt_inq_if_ids
*/
static WERROR dcesrv_mgmt_inq_if_ids(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx,
struct mgmt_inq_if_ids *r)
@ -64,8 +64,8 @@ static WERROR dcesrv_mgmt_inq_if_ids(struct dcesrv_call_state *dce_call, TALLOC_
}
/*
mgmt_inq_stats
/*
mgmt_inq_stats
*/
static WERROR dcesrv_mgmt_inq_stats(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx,
struct mgmt_inq_stats *r)
@ -85,8 +85,8 @@ static WERROR dcesrv_mgmt_inq_stats(struct dcesrv_call_state *dce_call, TALLOC_C
}
/*
mgmt_is_server_listening
/*
mgmt_is_server_listening
*/
static uint32_t dcesrv_mgmt_is_server_listening(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx,
struct mgmt_is_server_listening *r)
@ -96,8 +96,8 @@ static uint32_t dcesrv_mgmt_is_server_listening(struct dcesrv_call_state *dce_ca
}
/*
mgmt_stop_server_listening
/*
mgmt_stop_server_listening
*/
static WERROR dcesrv_mgmt_stop_server_listening(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx,
struct mgmt_stop_server_listening *r)
@ -106,8 +106,8 @@ static WERROR dcesrv_mgmt_stop_server_listening(struct dcesrv_call_state *dce_ca
}
/*
mgmt_inq_princ_name
/*
mgmt_inq_princ_name
*/
static WERROR dcesrv_mgmt_inq_princ_name(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx,
struct mgmt_inq_princ_name *r)

View File

@ -21,12 +21,11 @@
*/
#include "includes.h"
#include "librpc/rpc/dcesrv_core.h"
#include "librpc/rpc/dcesrv_core_proto.h"
#include "auth/gensec/gensec.h"
#include "lib/util/dlinklist.h"
#include "rpc_server/dcerpc_server.h"
#include "rpc_server/dcerpc_server_proto.h"
#include "param/param.h"
#include "librpc/rpc/rpc_common.h"
/*
move a call from an existing linked list to the specified list. This

View File

@ -635,6 +635,9 @@ bld.SAMBA_LIBRARY('dcerpc-binding',
bld.SAMBA_LIBRARY('dcerpc-server-core',
source='''
rpc/dcesrv_core.c
rpc/dcesrv_auth.c
rpc/dcesrv_mgmt.c
rpc/dcesrv_reply.c
''',
deps='ndr dcerpc-binding',
pc_files=[],

File diff suppressed because it is too large Load Diff

View File

@ -22,7 +22,7 @@ bld.SAMBA_SUBSYSTEM('DCERPC_COMMON',
)
bld.SAMBA_LIBRARY('dcerpc_server',
source='dcerpc_server.c dcesrv_auth.c dcesrv_mgmt.c handles.c dcesrv_reply.c',
source='dcerpc_server.c handles.c',
pc_files='dcerpc_server.pc',
deps='LIBCLI_AUTH ndr samba_server_gensec service auth',
public_deps='dcerpc dcerpc-server-core',