summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-12-12 20:03:42 +0000
committerLuke Leighton <lkcl@samba.org>1999-12-12 20:03:42 +0000
commit4f8a24522c683761c6f2ee23dba56f6c7913377b (patch)
treefef9baa89fc7695fe462cbace85a0f4276845d53 /source3/rpc_server
parent0ce128e3550794d4dbbd1def00e87c020f72c992 (diff)
downloadsamba-4f8a24522c683761c6f2ee23dba56f6c7913377b.tar.gz
samba-4f8a24522c683761c6f2ee23dba56f6c7913377b.tar.bz2
samba-4f8a24522c683761c6f2ee23dba56f6c7913377b.zip
final part of "first" phase converting over to msrpc daemon architecture.
done a minimal amout of clean-up in the Makefile, removing unnecessary modules from the link stage. this is not complete, yet, and will involve some changes, for example to smbd, to remove dependencies on the password database API that shouldn't be there. for example, smbd should not ever call getsmbpwXXX() it should call the Samr or Lsa API. this first implementation has minor problems with not reinstantiating the same services as the caller. the "homes" service is a good example. (This used to be commit caa50525220b0d0250fa139367593c2de2c12135)
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/srv_brs.c2
-rw-r--r--source3/rpc_server/srv_netlog.c7
-rw-r--r--source3/rpc_server/srv_pipe.c30
-rw-r--r--source3/rpc_server/srv_pipe_hnd.c14
4 files changed, 19 insertions, 34 deletions
diff --git a/source3/rpc_server/srv_brs.c b/source3/rpc_server/srv_brs.c
index cde5a79beb..c9abab20be 100644
--- a/source3/rpc_server/srv_brs.c
+++ b/source3/rpc_server/srv_brs.c
@@ -93,6 +93,6 @@ struct api_struct api_brs_cmds[] =
********************************************************************/
BOOL api_brs_rpc(rpcsrv_struct *p, prs_struct *data)
{
- return api_rpcTNP(p, "api_brssvc_rpc", api_brs_cmds, data);
+ return api_rpcTNP(p, "api_brs_rpc", api_brs_cmds, data);
}
diff --git a/source3/rpc_server/srv_netlog.c b/source3/rpc_server/srv_netlog.c
index 22788508eb..9721b3bf00 100644
--- a/source3/rpc_server/srv_netlog.c
+++ b/source3/rpc_server/srv_netlog.c
@@ -334,6 +334,13 @@ static BOOL get_md4pw(char *md4pw, char *mach_name, char *mach_acct)
return True;
}
+ if (strequal(mach_name, global_myname))
+ {
+ DEBUG(0,("get_md4pw: *** LOOPBACK DETECTED - USING NULL KEY ***\n"));
+ memset(md4pw, 0, 16);
+ return True;
+ }
+
DEBUG(0,("get_md4pw: Workstation %s: no account in domain\n", mach_acct));
return False;
}
diff --git a/source3/rpc_server/srv_pipe.c b/source3/rpc_server/srv_pipe.c
index 73a06b208c..d15cc1248c 100644
--- a/source3/rpc_server/srv_pipe.c
+++ b/source3/rpc_server/srv_pipe.c
@@ -231,8 +231,6 @@ static BOOL api_pipe_ntlmssp_verify(rpcsrv_struct *l)
size_t wks_len;
BOOL anonymous = False;
- struct smb_passwd *smb_pass = NULL;
-
memset(null_pwd, 0, sizeof(null_pwd));
DEBUG(5,("api_pipe_ntlmssp_verify: checking user details\n"));
@@ -304,19 +302,13 @@ static BOOL api_pipe_ntlmssp_verify(rpcsrv_struct *l)
else
{
DEBUG(5,("user: %s domain: %s wks: %s\n", l->user_name, l->domain, l->wks));
- become_root(True);
- smb_pass = getsmbpwnam(l->user_name);
- l->ntlmssp_validated = pass_check_smb(smb_pass, l->domain,
+ become_root(False);
+ l->ntlmssp_validated = check_domain_security(l->user_name, l->domain,
(uchar*)l->ntlmssp_chal.challenge,
lm_owf, lm_owf_len,
nt_owf, nt_owf_len,
- NULL, l->user_sess_key);
- unbecome_root(True);
-
- if (smb_pass != NULL)
- {
- pwd = smb_pass->smb_passwd;
- }
+ l->user_sess_key);
+ unbecome_root(False);
}
if (l->ntlmssp_validated && pwd != NULL)
@@ -463,20 +455,6 @@ static struct api_cmd* add_api_cmd_to_array(uint32 *len,
}
-#if 0
-{
- { "lsarpc", "lsass", api_ntlsa_rpc },
- { "samr", "lsass", api_samr_rpc },
- { "srvsvc", "ntsvcs", api_srvsvc_rpc },
- { "wkssvc", "ntsvcs", api_wkssvc_rpc },
- { "browser", "ntsvcs", api_brs_rpc },
- { "svcctl", "ntsvcs", api_svcctl_rpc },
- { "NETLOGON", "lsass", api_netlog_rpc },
- { "winreg", "winreg", api_reg_rpc },
- { "spoolss", "spoolss", api_spoolss_rpc },
- { NULL, NULL, NULL }
-};
-#endif
void close_msrpc_command_processor(void)
{
diff --git a/source3/rpc_server/srv_pipe_hnd.c b/source3/rpc_server/srv_pipe_hnd.c
index 8a28674d3d..f8bde1bf9b 100644
--- a/source3/rpc_server/srv_pipe_hnd.c
+++ b/source3/rpc_server/srv_pipe_hnd.c
@@ -135,14 +135,13 @@ pipes_struct *open_rpc_pipe_p(char *pipe_name,
DEBUG(5,("open pipes: name %s pnum=%x\n", p->name, p->pnum));
}
- if (strequal(pipe_name, "lsarpc"))
+ m = msrpc_use_add(pipe_name, &usr, False);
+ if (m == NULL)
{
- m = msrpc_use_add(pipe_name, &usr, False);
- if (m == NULL)
- {
- DEBUG(5,("open pipes: msrpc redirect failed\n"));
- return NULL;
- }
+ DEBUG(5,("open pipes: msrpc redirect failed\n"));
+ return NULL;
+ }
+#if 0
}
else
{
@@ -164,6 +163,7 @@ pipes_struct *open_rpc_pipe_p(char *pipe_name,
memcpy(l->user_sess_key, vuser->user_sess_key,
sizeof(l->user_sess_key));
}
+#endif
p = (pipes_struct *)malloc(sizeof(*p));
if (!p) return NULL;