summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-05-01 01:41:28 +0000
committerLuke Leighton <lkcl@samba.org>1999-05-01 01:41:28 +0000
commit89d51caba5bed5c3329b3776e15fce2bb41f7592 (patch)
tree80f224b8c41750abf5b619782ef1192037c7f087 /source3/smbd
parentd6ba4580d76aeb52c6fd7376e4c7f4d5f5f1a15a (diff)
downloadsamba-89d51caba5bed5c3329b3776e15fce2bb41f7592.tar.gz
samba-89d51caba5bed5c3329b3776e15fce2bb41f7592.tar.bz2
samba-89d51caba5bed5c3329b3776e15fce2bb41f7592.zip
added server ntlmv2 false/auto/true parameter, defaults to off.
(This used to be commit 209944dabc764c6ea0c471e7868306c7d8d020d4)
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/negprot.c33
1 files changed, 20 insertions, 13 deletions
diff --git a/source3/smbd/negprot.c b/source3/smbd/negprot.c
index d4e6180261..e66bf9f163 100644
--- a/source3/smbd/negprot.c
+++ b/source3/smbd/negprot.c
@@ -159,16 +159,6 @@ reply for the nt protocol
static int reply_nt1(char *outbuf)
{
/* dual names + lock_and_read + nt SMBs + remote API calls */
- int capabilities = CAP_NT_FIND|CAP_LOCK_AND_READ|
- (lp_nt_smb_support() ? CAP_NT_SMBS | CAP_RPC_REMOTE_APIS : 0) |
- (SMB_OFF_T_BITS == 64 ? CAP_LARGE_FILES : 0);
-
-
-/*
- other valid capabilities which we may support at some time...
- CAP_LARGE_READX|CAP_STATUS32|CAP_LEVEL_II_OPLOCKS;
- */
-
int secword=0;
BOOL doencrypt = SMBENCRYPT();
time_t t = time(NULL);
@@ -177,9 +167,26 @@ static int reply_nt1(char *outbuf)
char cryptkey[8];
char crypt_len = 0;
- if (lp_security() == SEC_SERVER) {
- cli = server_cryptkey();
- }
+ int capabilities = CAP_NT_FIND|CAP_LOCK_AND_READ;
+
+ if (lp_nt_smb_support())
+ {
+ capabilities |= CAP_NT_SMBS | CAP_RPC_REMOTE_APIS;
+ }
+
+ if (SMB_OFF_T_BITS == 64)
+ {
+ capabilities |= CAP_LARGE_FILES;
+ }
+/*
+ other valid capabilities which we may support at some time...
+ CAP_LARGE_READX|CAP_STATUS32|CAP_LEVEL_II_OPLOCKS;
+ */
+
+ if (lp_security() == SEC_SERVER)
+ {
+ cli = server_cryptkey();
+ }
if (cli) {
DEBUG(3,("using password server validation\n"));