mirror of
https://github.com/samba-team/samba.git
synced 2025-10-22 07:33:16 +03:00
r24606: move librpc/rpc/table.c -> librpc/ndr/ndr_table.c
and rename the containing functions to have a ndr_ prefix metze
This commit is contained in:
committed by
Gerald (Jerry) Carter
parent
fa577a1294
commit
cb234d43ae
@@ -287,8 +287,8 @@ librpc/gen_ndr/tables.c: $(IDL_NDR_PARSE_H_FILES)
|
|||||||
mv librpc/gen_ndr/tables.x librpc/gen_ndr/tables.c
|
mv librpc/gen_ndr/tables.x librpc/gen_ndr/tables.c
|
||||||
|
|
||||||
[SUBSYSTEM::NDR_TABLE]
|
[SUBSYSTEM::NDR_TABLE]
|
||||||
OBJ_FILES = rpc/table.o gen_ndr/tables.o
|
OBJ_FILES = ndr/ndr_table.o gen_ndr/tables.o
|
||||||
PRIVATE_PROTO_HEADER = rpc/dcerpc_table.h
|
PRIVATE_PROTO_HEADER = ndr/ndr_table.h
|
||||||
PUBLIC_DEPENDENCIES = \
|
PUBLIC_DEPENDENCIES = \
|
||||||
NDR_AUDIOSRV NDR_ECHO NDR_DCERPC \
|
NDR_AUDIOSRV NDR_ECHO NDR_DCERPC \
|
||||||
NDR_DSBACKUP NDR_EFS NDR_MISC NDR_LSA NDR_DFS NDR_DRSUAPI \
|
NDR_DSBACKUP NDR_EFS NDR_MISC NDR_LSA NDR_DFS NDR_DRSUAPI \
|
||||||
|
@@ -22,31 +22,31 @@
|
|||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
#include "lib/util/dlinklist.h"
|
#include "lib/util/dlinklist.h"
|
||||||
#include "librpc/rpc/dcerpc.h"
|
#include "librpc/ndr/libndr.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
|
|
||||||
struct ndr_interface_list *dcerpc_pipes = NULL;
|
static struct ndr_interface_list *ndr_interfaces;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
register a dcerpc client interface
|
register a ndr interface table
|
||||||
*/
|
*/
|
||||||
NTSTATUS librpc_register_interface(const struct ndr_interface_table *interface)
|
NTSTATUS ndr_table_register(const struct ndr_interface_table *table)
|
||||||
{
|
{
|
||||||
struct ndr_interface_list *l;
|
struct ndr_interface_list *l;
|
||||||
|
|
||||||
for (l = dcerpc_pipes; l; l = l->next) {
|
for (l = ndr_interfaces; l; l = l->next) {
|
||||||
if (GUID_equal(&interface->syntax_id.uuid, &l->table->syntax_id.uuid)) {
|
if (GUID_equal(&table->syntax_id.uuid, &l->table->syntax_id.uuid)) {
|
||||||
DEBUG(0, ("Attempt to register interface %s which has the "
|
DEBUG(0, ("Attempt to register interface %s which has the "
|
||||||
"same UUID as already registered interface %s\n",
|
"same UUID as already registered interface %s\n",
|
||||||
interface->name, l->table->name));
|
table->name, l->table->name));
|
||||||
return NT_STATUS_OBJECT_NAME_COLLISION;
|
return NT_STATUS_OBJECT_NAME_COLLISION;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
l = talloc(talloc_autofree_context(), struct ndr_interface_list);
|
l = talloc(talloc_autofree_context(), struct ndr_interface_list);
|
||||||
l->table = interface;
|
l->table = table;
|
||||||
|
|
||||||
DLIST_ADD(dcerpc_pipes, l);
|
DLIST_ADD(ndr_interfaces, l);
|
||||||
|
|
||||||
return NT_STATUS_OK;
|
return NT_STATUS_OK;
|
||||||
}
|
}
|
||||||
@@ -54,10 +54,10 @@ NTSTATUS librpc_register_interface(const struct ndr_interface_table *interface)
|
|||||||
/*
|
/*
|
||||||
find the pipe name for a local IDL interface
|
find the pipe name for a local IDL interface
|
||||||
*/
|
*/
|
||||||
const char *idl_pipe_name(const struct GUID *uuid, uint32_t if_version)
|
const char *ndr_interface_name(const struct GUID *uuid, uint32_t if_version)
|
||||||
{
|
{
|
||||||
const struct ndr_interface_list *l;
|
const struct ndr_interface_list *l;
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_table_list();l;l=l->next) {
|
||||||
if (GUID_equal(&l->table->syntax_id.uuid, uuid) &&
|
if (GUID_equal(&l->table->syntax_id.uuid, uuid) &&
|
||||||
l->table->syntax_id.if_version == if_version) {
|
l->table->syntax_id.if_version == if_version) {
|
||||||
return l->table->name;
|
return l->table->name;
|
||||||
@@ -69,10 +69,10 @@ const char *idl_pipe_name(const struct GUID *uuid, uint32_t if_version)
|
|||||||
/*
|
/*
|
||||||
find the number of calls defined by local IDL
|
find the number of calls defined by local IDL
|
||||||
*/
|
*/
|
||||||
int idl_num_calls(const struct GUID *uuid, uint32_t if_version)
|
int ndr_interface_num_calls(const struct GUID *uuid, uint32_t if_version)
|
||||||
{
|
{
|
||||||
const struct ndr_interface_list *l;
|
const struct ndr_interface_list *l;
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next){
|
for (l=ndr_interfaces;l;l=l->next){
|
||||||
if (GUID_equal(&l->table->syntax_id.uuid, uuid) &&
|
if (GUID_equal(&l->table->syntax_id.uuid, uuid) &&
|
||||||
l->table->syntax_id.if_version == if_version) {
|
l->table->syntax_id.if_version == if_version) {
|
||||||
return l->table->num_calls;
|
return l->table->num_calls;
|
||||||
@@ -85,10 +85,10 @@ int idl_num_calls(const struct GUID *uuid, uint32_t if_version)
|
|||||||
/*
|
/*
|
||||||
find a dcerpc interface by name
|
find a dcerpc interface by name
|
||||||
*/
|
*/
|
||||||
const struct ndr_interface_table *idl_iface_by_name(const char *name)
|
const struct ndr_interface_table *ndr_table_by_name(const char *name)
|
||||||
{
|
{
|
||||||
const struct ndr_interface_list *l;
|
const struct ndr_interface_list *l;
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_interfaces;l;l=l->next) {
|
||||||
if (strcasecmp(l->table->name, name) == 0) {
|
if (strcasecmp(l->table->name, name) == 0) {
|
||||||
return l->table;
|
return l->table;
|
||||||
}
|
}
|
||||||
@@ -99,10 +99,10 @@ const struct ndr_interface_table *idl_iface_by_name(const char *name)
|
|||||||
/*
|
/*
|
||||||
find a dcerpc interface by uuid
|
find a dcerpc interface by uuid
|
||||||
*/
|
*/
|
||||||
const struct ndr_interface_table *idl_iface_by_uuid(const struct GUID *uuid)
|
const struct ndr_interface_table *ndr_table_by_uuid(const struct GUID *uuid)
|
||||||
{
|
{
|
||||||
const struct ndr_interface_list *l;
|
const struct ndr_interface_list *l;
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_interfaces;l;l=l->next) {
|
||||||
if (GUID_equal(&l->table->syntax_id.uuid, uuid)) {
|
if (GUID_equal(&l->table->syntax_id.uuid, uuid)) {
|
||||||
return l->table;
|
return l->table;
|
||||||
}
|
}
|
||||||
@@ -113,13 +113,13 @@ const struct ndr_interface_table *idl_iface_by_uuid(const struct GUID *uuid)
|
|||||||
/*
|
/*
|
||||||
return the list of registered dcerpc_pipes
|
return the list of registered dcerpc_pipes
|
||||||
*/
|
*/
|
||||||
const struct ndr_interface_list *librpc_dcerpc_pipes(void)
|
const struct ndr_interface_list *ndr_table_list(void)
|
||||||
{
|
{
|
||||||
return dcerpc_pipes;
|
return ndr_interfaces;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
NTSTATUS dcerpc_register_builtin_interfaces(void);
|
NTSTATUS ndr_table_register_builtin_tables(void);
|
||||||
|
|
||||||
NTSTATUS ndr_table_init(void)
|
NTSTATUS ndr_table_init(void)
|
||||||
{
|
{
|
||||||
@@ -128,7 +128,7 @@ NTSTATUS ndr_table_init(void)
|
|||||||
if (initialized) return NT_STATUS_OK;
|
if (initialized) return NT_STATUS_OK;
|
||||||
initialized = True;
|
initialized = True;
|
||||||
|
|
||||||
dcerpc_register_builtin_interfaces();
|
ndr_table_register_builtin_tables();
|
||||||
|
|
||||||
return NT_STATUS_OK;
|
return NT_STATUS_OK;
|
||||||
}
|
}
|
@@ -20,7 +20,7 @@ my $opt_help = 0;
|
|||||||
sub ShowHelp()
|
sub ShowHelp()
|
||||||
{
|
{
|
||||||
print "
|
print "
|
||||||
perl DCE/RPC interface table generator
|
perl NDR interface table generator
|
||||||
Copyright (C) tridge\@samba.org
|
Copyright (C) tridge\@samba.org
|
||||||
|
|
||||||
Usage: tables.pl [options] <idlfile>
|
Usage: tables.pl [options] <idlfile>
|
||||||
@@ -53,7 +53,7 @@ sub process_file($)
|
|||||||
while (my $line = <FILE>) {
|
while (my $line = <FILE>) {
|
||||||
if ($line =~ /extern const struct ndr_interface_table (\w+);/) {
|
if ($line =~ /extern const struct ndr_interface_table (\w+);/) {
|
||||||
$found = 1;
|
$found = 1;
|
||||||
$init_fns.="\tstatus = librpc_register_interface(&$1);\n";
|
$init_fns.="\tstatus = ndr_table_register(&$1);\n";
|
||||||
$init_fns.="\tif (NT_STATUS_IS_ERR(status)) return status;\n\n";
|
$init_fns.="\tif (NT_STATUS_IS_ERR(status)) return status;\n\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -70,15 +70,15 @@ print <<EOF;
|
|||||||
/* Automatically generated by tables.pl. DO NOT EDIT */
|
/* Automatically generated by tables.pl. DO NOT EDIT */
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
#include "librpc/rpc/dcerpc.h"
|
#include "librpc/ndr/libndr.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
process_file($_) foreach (@ARGV);
|
process_file($_) foreach (@ARGV);
|
||||||
|
|
||||||
print <<EOF;
|
print <<EOF;
|
||||||
|
|
||||||
NTSTATUS dcerpc_register_builtin_interfaces(void)
|
NTSTATUS ndr_table_register_builtin_tables(void)
|
||||||
{
|
{
|
||||||
NTSTATUS status;
|
NTSTATUS status;
|
||||||
|
|
||||||
|
@@ -23,8 +23,8 @@
|
|||||||
#include "lib/cmdline/popt_common.h"
|
#include "lib/cmdline/popt_common.h"
|
||||||
#include "system/filesys.h"
|
#include "system/filesys.h"
|
||||||
#include "system/locale.h"
|
#include "system/locale.h"
|
||||||
#include "librpc/rpc/dcerpc.h"
|
#include "librpc/ndr/libndr.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static const struct ndr_interface_call *find_function(
|
static const struct ndr_interface_call *find_function(
|
||||||
@@ -55,7 +55,7 @@ static void show_pipes(void)
|
|||||||
const struct ndr_interface_list *l;
|
const struct ndr_interface_list *l;
|
||||||
printf("\nYou must specify a pipe\n");
|
printf("\nYou must specify a pipe\n");
|
||||||
printf("known pipes are:\n");
|
printf("known pipes are:\n");
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_table_list();l;l=l->next) {
|
||||||
if(l->table->helpstring) {
|
if(l->table->helpstring) {
|
||||||
printf("\t%s - %s\n", l->table->name, l->table->helpstring);
|
printf("\t%s - %s\n", l->table->name, l->table->helpstring);
|
||||||
} else {
|
} else {
|
||||||
@@ -218,7 +218,7 @@ const struct ndr_interface_table *load_iface_from_plugin(const char *plugin, con
|
|||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
if (!p) {
|
if (!p) {
|
||||||
p = idl_iface_by_name(pipe_name);
|
p = ndr_table_by_name(pipe_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!p) {
|
if (!p) {
|
||||||
@@ -227,7 +227,7 @@ const struct ndr_interface_table *load_iface_from_plugin(const char *plugin, con
|
|||||||
status = GUID_from_string(pipe_name, &uuid);
|
status = GUID_from_string(pipe_name, &uuid);
|
||||||
|
|
||||||
if (NT_STATUS_IS_OK(status)) {
|
if (NT_STATUS_IS_OK(status)) {
|
||||||
p = idl_iface_by_uuid(&uuid);
|
p = ndr_table_by_uuid(&uuid);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
#include "rpc_server/dcerpc_server.h"
|
#include "rpc_server/dcerpc_server.h"
|
||||||
#include "auth/auth.h"
|
#include "auth/auth.h"
|
||||||
#include "auth/credentials/credentials.h"
|
#include "auth/credentials/credentials.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
|
|
||||||
|
|
||||||
struct dcesrv_remote_private {
|
struct dcesrv_remote_private {
|
||||||
@@ -63,7 +63,7 @@ static NTSTATUS remote_op_bind(struct dcesrv_call_state *dce_call, const struct
|
|||||||
pass = lp_parm_string(-1, "dcerpc_remote", "password");
|
pass = lp_parm_string(-1, "dcerpc_remote", "password");
|
||||||
domain = lp_parm_string(-1, "dceprc_remote", "domain");
|
domain = lp_parm_string(-1, "dceprc_remote", "domain");
|
||||||
|
|
||||||
table = idl_iface_by_uuid(&iface->syntax_id.uuid); /* FIXME: What about if_version ? */
|
table = ndr_table_by_uuid(&iface->syntax_id.uuid); /* FIXME: What about if_version ? */
|
||||||
if (!table) {
|
if (!table) {
|
||||||
dce_call->fault_code = DCERPC_FAULT_UNK_IF;
|
dce_call->fault_code = DCERPC_FAULT_UNK_IF;
|
||||||
return NT_STATUS_NET_WRITE_FAULT;
|
return NT_STATUS_NET_WRITE_FAULT;
|
||||||
@@ -274,7 +274,7 @@ static BOOL remote_op_interface_by_uuid(struct dcesrv_interface *iface, const st
|
|||||||
{
|
{
|
||||||
const struct ndr_interface_list *l;
|
const struct ndr_interface_list *l;
|
||||||
|
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_table_list();l;l=l->next) {
|
||||||
if (l->table->syntax_id.if_version == if_version &&
|
if (l->table->syntax_id.if_version == if_version &&
|
||||||
GUID_equal(&l->table->syntax_id.uuid, uuid)==0) {
|
GUID_equal(&l->table->syntax_id.uuid, uuid)==0) {
|
||||||
return remote_fill_interface(iface, l->table);
|
return remote_fill_interface(iface, l->table);
|
||||||
@@ -286,7 +286,7 @@ static BOOL remote_op_interface_by_uuid(struct dcesrv_interface *iface, const st
|
|||||||
|
|
||||||
static BOOL remote_op_interface_by_name(struct dcesrv_interface *iface, const char *name)
|
static BOOL remote_op_interface_by_name(struct dcesrv_interface *iface, const char *name)
|
||||||
{
|
{
|
||||||
const struct ndr_interface_table *tbl = idl_iface_by_name(name);
|
const struct ndr_interface_table *tbl = ndr_table_by_name(name);
|
||||||
|
|
||||||
if (tbl)
|
if (tbl)
|
||||||
return remote_fill_interface(iface, tbl);
|
return remote_fill_interface(iface, tbl);
|
||||||
|
@@ -28,7 +28,7 @@
|
|||||||
#include "scripting/ejs/ejsrpc.h"
|
#include "scripting/ejs/ejsrpc.h"
|
||||||
#include "lib/util/dlinklist.h"
|
#include "lib/util/dlinklist.h"
|
||||||
#include "lib/events/events.h"
|
#include "lib/events/events.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "auth/credentials/credentials.h"
|
#include "auth/credentials/credentials.h"
|
||||||
#include "librpc/rpc/dcerpc.h"
|
#include "librpc/rpc/dcerpc.h"
|
||||||
#include "cluster/cluster.h"
|
#include "cluster/cluster.h"
|
||||||
@@ -136,7 +136,7 @@ static int ejs_rpc_connect(MprVarHandle eid, int argc, char **argv)
|
|||||||
pipe_name = mprToString(mprGetProperty(this, "pipe_name", NULL));
|
pipe_name = mprToString(mprGetProperty(this, "pipe_name", NULL));
|
||||||
}
|
}
|
||||||
|
|
||||||
iface = idl_iface_by_name(pipe_name);
|
iface = ndr_table_by_name(pipe_name);
|
||||||
if (iface == NULL) {
|
if (iface == NULL) {
|
||||||
status = NT_STATUS_OBJECT_NAME_INVALID;
|
status = NT_STATUS_OBJECT_NAME_INVALID;
|
||||||
goto done;
|
goto done;
|
||||||
|
@@ -23,7 +23,7 @@
|
|||||||
#include "torture/torture.h"
|
#include "torture/torture.h"
|
||||||
#include "librpc/gen_ndr/ndr_drsuapi_c.h"
|
#include "librpc/gen_ndr/ndr_drsuapi_c.h"
|
||||||
#include "librpc/gen_ndr/ndr_misc.h"
|
#include "librpc/gen_ndr/ndr_misc.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "torture/rpc/rpc.h"
|
#include "torture/rpc/rpc.h"
|
||||||
|
|
||||||
|
|
||||||
@@ -264,7 +264,7 @@ BOOL torture_rpc_autoidl(struct torture_context *torture)
|
|||||||
TALLOC_CTX *mem_ctx;
|
TALLOC_CTX *mem_ctx;
|
||||||
const struct ndr_interface_table *iface;
|
const struct ndr_interface_table *iface;
|
||||||
|
|
||||||
iface = idl_iface_by_name("drsuapi");
|
iface = ndr_table_by_name("drsuapi");
|
||||||
if (!iface) {
|
if (!iface) {
|
||||||
printf("Unknown interface!\n");
|
printf("Unknown interface!\n");
|
||||||
return False;
|
return False;
|
||||||
|
@@ -22,8 +22,8 @@
|
|||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
#include "torture/torture.h"
|
#include "torture/torture.h"
|
||||||
#include "librpc/rpc/dcerpc.h"
|
#include "librpc/ndr/libndr.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "torture/rpc/rpc.h"
|
#include "torture/rpc/rpc.h"
|
||||||
|
|
||||||
|
|
||||||
@@ -112,7 +112,7 @@ BOOL torture_rpc_countcalls(struct torture_context *torture)
|
|||||||
}
|
}
|
||||||
iface_name = lp_parm_string(-1, "countcalls", "interface");
|
iface_name = lp_parm_string(-1, "countcalls", "interface");
|
||||||
if (iface_name != NULL) {
|
if (iface_name != NULL) {
|
||||||
iface = idl_iface_by_name(iface_name);
|
iface = ndr_table_by_name(iface_name);
|
||||||
if (!iface) {
|
if (!iface) {
|
||||||
printf("Unknown interface '%s'\n", iface_name);
|
printf("Unknown interface '%s'\n", iface_name);
|
||||||
return False;
|
return False;
|
||||||
@@ -120,7 +120,7 @@ BOOL torture_rpc_countcalls(struct torture_context *torture)
|
|||||||
return count_calls(mem_ctx, iface, False);
|
return count_calls(mem_ctx, iface, False);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_table_list();l;l=l->next) {
|
||||||
TALLOC_CTX *loop_ctx;
|
TALLOC_CTX *loop_ctx;
|
||||||
loop_ctx = talloc_named(mem_ctx, 0, "torture_rpc_councalls loop context");
|
loop_ctx = talloc_named(mem_ctx, 0, "torture_rpc_councalls loop context");
|
||||||
ret &= count_calls(loop_ctx, l->table, True);
|
ret &= count_calls(loop_ctx, l->table, True);
|
||||||
|
@@ -21,7 +21,7 @@
|
|||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
#include "torture/torture.h"
|
#include "torture/torture.h"
|
||||||
#include "librpc/gen_ndr/ndr_epmapper_c.h"
|
#include "librpc/gen_ndr/ndr_epmapper_c.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "torture/rpc/rpc.h"
|
#include "torture/rpc/rpc.h"
|
||||||
|
|
||||||
|
|
||||||
@@ -63,7 +63,7 @@ static BOOL test_Map(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
|
|||||||
dcerpc_floor_get_lhs_data(&twr->tower.floors[0], &syntax);
|
dcerpc_floor_get_lhs_data(&twr->tower.floors[0], &syntax);
|
||||||
|
|
||||||
printf("epm_Map results for '%s':\n",
|
printf("epm_Map results for '%s':\n",
|
||||||
idl_pipe_name(&syntax.uuid, syntax.if_version));
|
ndr_interface_name(&syntax.uuid, syntax.if_version));
|
||||||
|
|
||||||
twr->tower.floors[2].lhs.protocol = EPM_PROTOCOL_NCACN;
|
twr->tower.floors[2].lhs.protocol = EPM_PROTOCOL_NCACN;
|
||||||
twr->tower.floors[2].lhs.lhs_data = data_blob(NULL, 0);
|
twr->tower.floors[2].lhs.lhs_data = data_blob(NULL, 0);
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
#include "torture/torture.h"
|
#include "torture/torture.h"
|
||||||
#include "librpc/gen_ndr/ndr_mgmt_c.h"
|
#include "librpc/gen_ndr/ndr_mgmt_c.h"
|
||||||
#include "auth/gensec/gensec.h"
|
#include "auth/gensec/gensec.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "torture/rpc/rpc.h"
|
#include "torture/rpc/rpc.h"
|
||||||
|
|
||||||
|
|
||||||
@@ -65,7 +65,8 @@ BOOL test_inq_if_ids(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
|
|||||||
|
|
||||||
printf("\tuuid %s version 0x%08x '%s'\n",
|
printf("\tuuid %s version 0x%08x '%s'\n",
|
||||||
GUID_string(mem_ctx, &id->uuid),
|
GUID_string(mem_ctx, &id->uuid),
|
||||||
id->if_version, idl_pipe_name(&id->uuid, id->if_version));
|
id->if_version,
|
||||||
|
ndr_interface_name(&id->uuid, id->if_version));
|
||||||
|
|
||||||
if (per_id_test) {
|
if (per_id_test) {
|
||||||
per_id_test(priv, mem_ctx, id);
|
per_id_test(priv, mem_ctx, id);
|
||||||
@@ -211,7 +212,7 @@ BOOL torture_rpc_mgmt(struct torture_context *torture)
|
|||||||
return False;
|
return False;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_table_list();l;l=l->next) {
|
||||||
loop_ctx = talloc_named(mem_ctx, 0, "torture_rpc_mgmt loop context");
|
loop_ctx = talloc_named(mem_ctx, 0, "torture_rpc_mgmt loop context");
|
||||||
|
|
||||||
/* some interfaces are not mappable */
|
/* some interfaces are not mappable */
|
||||||
|
@@ -24,7 +24,7 @@
|
|||||||
#include "librpc/rpc/dcerpc.h"
|
#include "librpc/rpc/dcerpc.h"
|
||||||
#include "torture/rpc/rpc.h"
|
#include "torture/rpc/rpc.h"
|
||||||
#include "torture/torture.h"
|
#include "torture/torture.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "lib/util/dlinklist.h"
|
#include "lib/util/dlinklist.h"
|
||||||
|
|
||||||
/* open a rpc connection to the chosen binding string */
|
/* open a rpc connection to the chosen binding string */
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
#include "torture/torture.h"
|
#include "torture/torture.h"
|
||||||
#include "librpc/gen_ndr/ndr_mgmt_c.h"
|
#include "librpc/gen_ndr/ndr_mgmt_c.h"
|
||||||
#include "librpc/rpc/dcerpc_table.h"
|
#include "librpc/ndr/ndr_table.h"
|
||||||
#include "torture/rpc/rpc.h"
|
#include "torture/rpc/rpc.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -76,7 +76,7 @@ static BOOL test_num_calls(const struct ndr_interface_table *iface,
|
|||||||
}
|
}
|
||||||
|
|
||||||
printf("\t%d calls available\n", i);
|
printf("\t%d calls available\n", i);
|
||||||
idl_calls = idl_num_calls(&id->uuid, id->if_version);
|
idl_calls = ndr_interface_num_calls(&id->uuid, id->if_version);
|
||||||
if (idl_calls == -1) {
|
if (idl_calls == -1) {
|
||||||
printf("\tinterface not known in local IDL\n");
|
printf("\tinterface not known in local IDL\n");
|
||||||
} else if (i != idl_calls) {
|
} else if (i != idl_calls) {
|
||||||
@@ -117,7 +117,7 @@ BOOL torture_rpc_scanner(struct torture_context *torture)
|
|||||||
return False;
|
return False;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (l=librpc_dcerpc_pipes();l;l=l->next) {
|
for (l=ndr_table_list();l;l=l->next) {
|
||||||
loop_ctx = talloc_named(mem_ctx, 0, "torture_rpc_scanner loop context");
|
loop_ctx = talloc_named(mem_ctx, 0, "torture_rpc_scanner loop context");
|
||||||
/* some interfaces are not mappable */
|
/* some interfaces are not mappable */
|
||||||
if (l->table->num_calls == 0 ||
|
if (l->table->num_calls == 0 ||
|
||||||
|
Reference in New Issue
Block a user