summaryrefslogtreecommitdiff
path: root/source3/rpc_client/cli_connect.c
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-12-08 21:43:03 +0000
committerLuke Leighton <lkcl@samba.org>1999-12-08 21:43:03 +0000
commit4ab9d91428b66bd2fe407b0dba94f4130160b576 (patch)
tree2733683a3097225f44e459d2fe73e1ac880b7aba /source3/rpc_client/cli_connect.c
parenta0ba234cf9b40adf6b5390e4e67730163a42883f (diff)
downloadsamba-4ab9d91428b66bd2fe407b0dba94f4130160b576.tar.gz
samba-4ab9d91428b66bd2fe407b0dba94f4130160b576.tar.bz2
samba-4ab9d91428b66bd2fe407b0dba94f4130160b576.zip
ABOUT TIME!!!!!!!!
damn, this one is bad. started, at least two days ago, to add an authentication mechanism to the smbd<->msrpc redirector/relay, such that sufficient unix / nt information could be transferred across the unix socket to do a become_user() on the other side of the socket. it is necessary that the msrpc daemon inherit the same unix and nt credentials as the smbd process from which it was spawned, until such time as the msrpc daemon receives an authentication request of its own, whereupon the msrpc daemon is responsible for authenticating the new credentials and doing yet another become_user() etc sequence. (This used to be commit 30c7fdd6ef10ecd35594311c1b250b95ff895489)
Diffstat (limited to 'source3/rpc_client/cli_connect.c')
-rw-r--r--source3/rpc_client/cli_connect.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/source3/rpc_client/cli_connect.c b/source3/rpc_client/cli_connect.c
index 147be96ba4..f935b53044 100644
--- a/source3/rpc_client/cli_connect.c
+++ b/source3/rpc_client/cli_connect.c
@@ -24,7 +24,7 @@
#include "includes.h"
-struct user_credentials *usr_creds = NULL;
+struct ntuser_creds *usr_creds = NULL;
extern int DEBUGLEVEL;
extern pstring scope;
@@ -35,7 +35,7 @@ struct cli_connection
uint32 num_connections;
char *srv_name;
char *pipe_name;
- struct user_credentials usr_creds;
+ struct ntuser_creds usr_creds;
struct cli_state *cli;
uint16 fnum;
};
@@ -74,7 +74,7 @@ void free_connections(void)
}
static struct cli_connection *cli_con_get(const char* srv_name,
- const char* pipe_name)
+ const char* pipe_name, BOOL reuse)
{
struct cli_connection *con = NULL;
@@ -96,7 +96,7 @@ static struct cli_connection *cli_con_get(const char* srv_name,
con->pipe_name = strdup(pipe_name);
}
- con->cli = cli_net_use_add(srv_name, usr_creds, True);
+ con->cli = cli_net_use_add(srv_name, usr_creds, True, reuse);
if (con->cli == NULL)
{
@@ -181,12 +181,13 @@ BOOL cli_connection_init(const char* srv_name, const char* pipe_name,
struct cli_connection **con)
{
BOOL res = True;
+ BOOL reuse = False;
/*
* allocate
*/
- *con = cli_con_get(srv_name, pipe_name);
+ *con = cli_con_get(srv_name, pipe_name, reuse);
if ((*con) == NULL)
{