summaryrefslogtreecommitdiff
path: root/source3/nmbd
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-11-15 22:11:10 +0000
committerLuke Leighton <lkcl@samba.org>1999-11-15 22:11:10 +0000
commitb231d2fafaff8dc67ef2dbaec778f716524d4f6a (patch)
tree054f060f9d6cd60535ebee5501177d8b839b7577 /source3/nmbd
parent4c479f0574019afb2fc8a3dbfc802c75fde89244 (diff)
downloadsamba-b231d2fafaff8dc67ef2dbaec778f716524d4f6a.tar.gz
samba-b231d2fafaff8dc67ef2dbaec778f716524d4f6a.tar.bz2
samba-b231d2fafaff8dc67ef2dbaec778f716524d4f6a.zip
- added DCE/RPC "fault" PDU support.
- disabled (AGAIN) the GETDC "if (MAILSLOT\NTLOGON)" code that will get NT5rc2 to work but WILL break win95 (AGAIN). this needs _not_ to be re-enabled but to be replaced with a better mechanism. - added SMBwrite support (note: SMBwriteX already existed) as NT5rc2 is sending DCE/RPC over SMBwrite not SMBwriteX. (This used to be commit 25c70e3c984c4fed19763ed405741e83fe14f87e)
Diffstat (limited to 'source3/nmbd')
-rw-r--r--source3/nmbd/nmbd_processlogon.c26
1 files changed, 21 insertions, 5 deletions
diff --git a/source3/nmbd/nmbd_processlogon.c b/source3/nmbd/nmbd_processlogon.c
index 0fc44a40c9..6ddf47fc5f 100644
--- a/source3/nmbd/nmbd_processlogon.c
+++ b/source3/nmbd/nmbd_processlogon.c
@@ -137,7 +137,9 @@ logons are not enabled.\n", inet_ntoa(p->ip) ));
q = skip_string(q, 1); /* PDC name */
/* PDC and domain name */
+#if 0
if (strcmp(mailslot, NT_LOGON_MAILSLOT)==0)
+#endif
{
q = align2(q, buf);
@@ -179,13 +181,16 @@ reporting %s domain %s 0x%x ntversion=%x lm_nt token=%x lm_20 token=%x\n",
uniuser = skip_unibuf(unicomp, buf+len-q);
getdc = skip_unibuf(uniuser, buf+len-q);
q = skip_string(getdc,1);
- q += 4;
+ q += 4; /* skip Account Control Bits */
domainsidsize = IVAL(q, 0);
q += 4;
- q += domainsidsize;
- q = align4(q, buf);
- q += 2;
+ if (domainsidsize != 0)
+ {
+ q += domainsidsize;
+ q += 2;
+ q = align4(q, buf);
+ }
ntversion = IVAL(q, 0);
q += 4;
@@ -205,6 +210,10 @@ reporting %s domain %s 0x%x ntversion=%x lm_nt token=%x lm_20 token=%x\n",
fstrcpy(reply_name,"\\\\"); /* Here it wants \\LOGONSERVER. */
fstrcpy(reply_name+2,my_name);
+ ntversion = 0x01;
+ lmnttoken = 0xffff;
+ lm20token = 0xffff;
+
if (DEBUGLVL(3))
{
fstring ascuser;
@@ -221,7 +230,14 @@ reporting %s domain %s 0x%x ntversion=%x lm_nt token=%x lm_20 token=%x\n",
/* Construct reply. */
q = outbuf;
- SSVAL(q, 0, SAMLOGON_R);
+ if (uniuser[0] == 0)
+ {
+ SSVAL(q, 0, SAMLOGON_UNK_R); /* user unknown */
+ }
+ else
+ {
+ SSVAL(q, 0, SAMLOGON_R);
+ }
q += 2;
/* Logon server, trust account, domain */