From fcef0db6d630ccadaa65138b77eac5fce16a13c9 Mon Sep 17 00:00:00 2001 From: Steve French Date: Sat, 19 May 2018 20:45:27 -0500 Subject: smb3: add support for posix negotiate context Unlike CIFS where UNIX/POSIX extensions had been negotiatable, SMB3 did not have POSIX extensions yet. Add the new SMB3.11 POSIX negotiate context to ask the server whether it can support POSIX (and thus whether we can send the new POSIX open context). Signed-off-by: Steve French --- fs/cifs/smb2pdu.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'fs/cifs/smb2pdu.h') diff --git a/fs/cifs/smb2pdu.h b/fs/cifs/smb2pdu.h index d28f358022c5..853e5a707276 100644 --- a/fs/cifs/smb2pdu.h +++ b/fs/cifs/smb2pdu.h @@ -300,6 +300,14 @@ struct smb2_encryption_neg_context { __le16 Ciphers[1]; /* Ciphers[0] since only one used now */ } __packed; +#define POSIX_CTXT_DATA_LEN 8 +struct smb2_posix_neg_context { + __le16 ContextType; /* 0x100 */ + __le16 DataLength; + __le32 Reserved; + __le64 Reserved1; /* In case needed for future (eg version or caps) */ +} __packed; + struct smb2_negotiate_rsp { struct smb2_hdr hdr; __le16 StructureSize; /* Must be 65 */ -- cgit v1.2.3