summaryrefslogtreecommitdiff
path: root/fs/cifs/cifssmb.c
diff options
context:
space:
mode:
authorSteve French <sfrench@us.ibm.com>2006-02-09 21:12:47 +0000
committerSteve French <sfrench@us.ibm.com>2006-02-09 21:12:47 +0000
commit12b3b8ffb5fd591df41f658d6068b76f7a58e710 (patch)
tree7034f4aed6f90d00cd24d8548c6df229aae2d22c /fs/cifs/cifssmb.c
parente3f749c4af69c4344d89f11e2293e3790eb4eaca (diff)
downloadlinux-3.10-12b3b8ffb5fd591df41f658d6068b76f7a58e710.tar.gz
linux-3.10-12b3b8ffb5fd591df41f658d6068b76f7a58e710.tar.bz2
linux-3.10-12b3b8ffb5fd591df41f658d6068b76f7a58e710.zip
[CIFS] Cleanup NTLMSSP session setup handling
Fix to hash NTLMv2 properly will follow. Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifssmb.c')
-rw-r--r--fs/cifs/cifssmb.c27
1 files changed, 26 insertions, 1 deletions
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c
index 217323b0c89..d69b835c12e 100644
--- a/fs/cifs/cifssmb.c
+++ b/fs/cifs/cifssmb.c
@@ -1,7 +1,7 @@
/*
* fs/cifs/cifssmb.c
*
- * Copyright (C) International Business Machines Corp., 2002,2005
+ * Copyright (C) International Business Machines Corp., 2002,2006
* Author(s): Steve French (sfrench@us.ibm.com)
*
* Contains the routines for constructing the SMB PDUs themselves
@@ -187,6 +187,31 @@ small_smb_init(int smb_command, int wct, struct cifsTconInfo *tcon,
return rc;
}
+int
+small_smb_init_no_tcon(int smb_command, int wct, struct cifsSesInfo *ses,
+ void **request_buf)
+{
+ int rc;
+ struct smb_hdr * buffer;
+
+ rc = small_smb_init(smb_command, wct, 0, request_buf);
+ if(rc)
+ return rc;
+
+ buffer->Mid = GetNextMid(ses->server);
+ if (ses->capabilities & CAP_UNICODE)
+ buffer->Flags2 |= SMBFLG2_UNICODE;
+ if (ses->capabilities & CAP_STATUS32) {
+ buffer->Flags2 |= SMBFLG2_ERR_STATUS;
+
+ /* uid, tid can stay at zero as set in header assemble */
+
+ /* BB add support for turning on the signing when
+ this function is used after 1st of session setup requests */
+
+ return rc;
+}
+
/* If the return code is zero, this function must fill in request_buf pointer */
static int