summaryrefslogtreecommitdiff
path: root/source3/rpc_server/srv_netlog_nt.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2001-08-12 11:19:57 +0000
committerAndrew Bartlett <abartlet@samba.org>2001-08-12 11:19:57 +0000
commit6ad80352dd2523c310258de3211a2af0f1763d2a (patch)
tree7058ea9d3faf2c4f72a9b7edcca6d4ac856108b9 /source3/rpc_server/srv_netlog_nt.c
parent9644bf74bd90ef5b9c016434408be1acaa311978 (diff)
downloadsamba-6ad80352dd2523c310258de3211a2af0f1763d2a.tar.gz
samba-6ad80352dd2523c310258de3211a2af0f1763d2a.tar.bz2
samba-6ad80352dd2523c310258de3211a2af0f1763d2a.zip
This patch does a number of things, mostly smaller than they look :-)
In particuar, it moves the domain_client_validate stuff out of auth_domain.c to somwhere where they (I hope) they can be shared with winbind better. (This may need some work) The main purpose of this patch was however to improve some of the internal documentation and to correctly place become_root()/unbecome_root() calls within the code. Finally this patch moves some more of auth.c into other files, auth_unix.c in this case. Andrew Bartlett (This used to be commit ea1c547ac880def29f150de2172c95213509350e)
Diffstat (limited to 'source3/rpc_server/srv_netlog_nt.c')
-rw-r--r--source3/rpc_server/srv_netlog_nt.c25
1 files changed, 5 insertions, 20 deletions
diff --git a/source3/rpc_server/srv_netlog_nt.c b/source3/rpc_server/srv_netlog_nt.c
index b7e1d3538d..5cf8f6732e 100644
--- a/source3/rpc_server/srv_netlog_nt.c
+++ b/source3/rpc_server/srv_netlog_nt.c
@@ -446,7 +446,6 @@ uint32 _net_sam_logoff(pipes_struct *p, NET_Q_SAM_LOGOFF *q_u, NET_R_SAM_LOGOFF
static uint32 _net_logon_any(NET_ID_INFO_CTR *ctr, char *user, char *domain, char *sess_key)
{
-
uint32 nt_status = NT_STATUS_LOGON_FAILURE;
unsigned char local_lm_response[24];
@@ -490,6 +489,8 @@ static uint32 _net_logon_any(NET_ID_INFO_CTR *ctr, char *user, char *domain, cha
DEBUG(10,("_net_logon_any: Attempting validation level %d.\n", ctr->switch_value));
switch (ctr->switch_value) {
case NET_LOGON_TYPE:
+ /* Standard challange/response authenticaion */
+
user_info.lm_resp.buffer = (uint8 *)ctr->auth.id2.lm_chal_resp.buffer;
user_info.lm_resp.len = ctr->auth.id2.lm_chal_resp.str_str_len;
user_info.nt_resp.buffer = (uint8 *)ctr->auth.id2.nt_chal_resp.buffer;
@@ -497,6 +498,9 @@ static uint32 _net_logon_any(NET_ID_INFO_CTR *ctr, char *user, char *domain, cha
memcpy(user_info.chal, ctr->auth.id2.lm_chal, 8);
break;
case INTERACTIVE_LOGON_TYPE:
+ /* 'Interactive' autheticaion, supplies the password in its MD4 form, encrypted
+ with the session key. We will convert this to challange/responce for the
+ auth subsystem to chew on */
{
char nt_pwd[16];
char lm_pwd[16];
@@ -539,25 +543,6 @@ static uint32 _net_logon_any(NET_ID_INFO_CTR *ctr, char *user, char *domain, cha
user_info.nt_resp.len = 24;
break;
}
-#if 0
- case GENERAL_LOGON_TYPE:
- /* plaintext login. plaintext username and password */
-
- /*
- * Not encrypted - do so.
- */
-
- SMBencrypt( (uchar *)ctr->auth.id4....., user_info.chal, local_lm_response);
- SMBNTencrypt((uchar *)ctr->auth.id4......., user_info.chal, local_nt_response);
- user_info.lm_resp.buffer = (uint8 *)local_lm_response;
- user_info.lm_resp.len = 24;
- user_info.nt_resp.buffer = (uint8 *)local_nt_response;
- user_info.nt_resp.len = 24;
-
- user_info.plaintext_password.str = ;
- user_info.plaintext_password.len = ;
- break;
-#endif
default:
DEBUG(2,("SAM Logon: unsupported switch value\n"));
return NT_STATUS_INVALID_INFO_CLASS;