Lines Matching +full:0 +full:x103

30 #define LANMAN_PROT 0
34 #define CIFS_PROT 0
37 #define BAD_PROT 0xFFFF
40 * Note some commands have minimal (wct=0,bcc=0), or uninteresting, responses
44 #define SMB_COM_CREATE_DIRECTORY 0x00 /* trivial response */
45 #define SMB_COM_DELETE_DIRECTORY 0x01 /* trivial response */
46 #define SMB_COM_CLOSE 0x04 /* triv req/rsp, timestamp ignored */
47 #define SMB_COM_FLUSH 0x05 /* triv req/rsp */
48 #define SMB_COM_DELETE 0x06 /* trivial response */
49 #define SMB_COM_RENAME 0x07 /* trivial response */
50 #define SMB_COM_QUERY_INFORMATION 0x08 /* aka getattr */
51 #define SMB_COM_SETATTR 0x09 /* trivial response */
52 #define SMB_COM_LOCKING_ANDX 0x24 /* trivial response */
53 #define SMB_COM_COPY 0x29 /* trivial rsp, fail filename ignrd*/
54 #define SMB_COM_ECHO 0x2B /* echo request */
55 #define SMB_COM_OPEN_ANDX 0x2D /* Legacy open for old servers */
56 #define SMB_COM_READ_ANDX 0x2E
57 #define SMB_COM_WRITE_ANDX 0x2F
58 #define SMB_COM_TRANSACTION2 0x32
59 #define SMB_COM_TRANSACTION2_SECONDARY 0x33
60 #define SMB_COM_FIND_CLOSE2 0x34 /* trivial response */
61 #define SMB_COM_TREE_DISCONNECT 0x71 /* trivial response */
62 #define SMB_COM_NEGOTIATE 0x72
63 #define SMB_COM_SESSION_SETUP_ANDX 0x73
64 #define SMB_COM_LOGOFF_ANDX 0x74 /* trivial response */
65 #define SMB_COM_TREE_CONNECT_ANDX 0x75
66 #define SMB_COM_NT_TRANSACT 0xA0
67 #define SMB_COM_NT_TRANSACT_SECONDARY 0xA1
68 #define SMB_COM_NT_CREATE_ANDX 0xA2
69 #define SMB_COM_NT_CANCEL 0xA4 /* no response */
70 #define SMB_COM_NT_RENAME 0xA5 /* trivial response */
73 #define TRANS2_OPEN 0x00
74 #define TRANS2_FIND_FIRST 0x01
75 #define TRANS2_FIND_NEXT 0x02
76 #define TRANS2_QUERY_FS_INFORMATION 0x03
77 #define TRANS2_SET_FS_INFORMATION 0x04
78 #define TRANS2_QUERY_PATH_INFORMATION 0x05
79 #define TRANS2_SET_PATH_INFORMATION 0x06
80 #define TRANS2_QUERY_FILE_INFORMATION 0x07
81 #define TRANS2_SET_FILE_INFORMATION 0x08
82 #define TRANS2_GET_DFS_REFERRAL 0x10
83 #define TRANS2_REPORT_DFS_INCOSISTENCY 0x11
86 #define TRANS_SET_NMPIPE_STATE 0x0001
87 #define TRANS_RAW_READ_NMPIPE 0x0011
88 #define TRANS_QUERY_NMPIPE_STATE 0x0021
89 #define TRANS_QUERY_NMPIPE_INFO 0x0022
90 #define TRANS_PEEK_NMPIPE 0x0023
91 #define TRANS_TRANSACT_NMPIPE 0x0026
92 #define TRANS_RAW_WRITE_NMPIPE 0x0031
93 #define TRANS_READ_NMPIPE 0x0036
94 #define TRANS_WRITE_NMPIPE 0x0037
95 #define TRANS_WAIT_NMPIPE 0x0053
96 #define TRANS_CALL_NMPIPE 0x0054
99 #define NT_TRANSACT_CREATE 0x01
100 #define NT_TRANSACT_IOCTL 0x02
101 #define NT_TRANSACT_SET_SECURITY_DESC 0x03
102 #define NT_TRANSACT_NOTIFY_CHANGE 0x04
103 #define NT_TRANSACT_RENAME 0x05
104 #define NT_TRANSACT_QUERY_SECURITY_DESC 0x06
105 #define NT_TRANSACT_GET_USER_QUOTA 0x07
106 #define NT_TRANSACT_SET_USER_QUOTA 0x08
111 #define MAX_CIFS_HDR_SIZE 0x58 /* 4 len + 32 hdr + (2*24 wct) + 2 bct + 2 pad */
169 #define SMBOPEN_WRITE_THROUGH 0x4000
170 #define SMBOPEN_DENY_ALL 0x0010
171 #define SMBOPEN_DENY_WRITE 0x0020
172 #define SMBOPEN_DENY_READ 0x0030
173 #define SMBOPEN_DENY_NONE 0x0040
174 #define SMBOPEN_READ 0x0000
175 #define SMBOPEN_WRITE 0x0001
176 #define SMBOPEN_READWRITE 0x0002
177 #define SMBOPEN_EXECUTE 0x0003
179 #define SMBOPEN_OCREATE 0x0010
180 #define SMBOPEN_OTRUNC 0x0002
181 #define SMBOPEN_OAPPEND 0x0001
186 #define SMBFLG_EXTD_LOCK 0x01 /* server supports lock-read write-unlock smb */
187 #define SMBFLG_RCV_POSTED 0x02 /* obsolete */
188 #define SMBFLG_RSVD 0x04
189 #define SMBFLG_CASELESS 0x08 /* all pathnames treated as caseless (off
191 #define SMBFLG_CANONICAL_PATH_FORMAT 0x10 /* obsolete */
192 #define SMBFLG_OLD_OPLOCK 0x20 /* obsolete */
193 #define SMBFLG_OLD_OPLOCK_NOTIFY 0x40 /* obsolete */
194 #define SMBFLG_RESPONSE 0x80 /* this PDU is a response from server */
204 #define SMBFLG2_SECURITY_SIGNATURE_REQUIRED (0x10)
205 #define SMBFLG2_IS_LONG_NAME cpu_to_le16(0x40)
206 #define SMBFLG2_REPARSE_PATH (0x400)
207 #define SMBFLG2_EXT_SEC cpu_to_le16(0x800)
208 #define SMBFLG2_DFS cpu_to_le16(0x1000)
209 #define SMBFLG2_PAGING_IO cpu_to_le16(0x2000)
210 #define SMBFLG2_ERR_STATUS cpu_to_le16(0x4000)
211 #define SMBFLG2_UNICODE cpu_to_le16(0x8000)
215 * NTCreateAndX as well as the level 0x107
216 * TRANS2_QUERY_PATH_INFORMATION API. The level 0x107, SMB_QUERY_FILE_ALL_INFO
222 #define FILE_READ_DATA 0x00000001 /* Data can be read from the file */
223 #define FILE_WRITE_DATA 0x00000002 /* Data can be written to the file */
224 #define FILE_APPEND_DATA 0x00000004 /* Data can be appended to the file */
225 #define FILE_READ_EA 0x00000008 /* Extended attributes associated */
227 #define FILE_WRITE_EA 0x00000010 /* Extended attributes associated */
229 #define FILE_EXECUTE 0x00000020 /*Data can be read into memory from */
231 #define FILE_DELETE_CHILD 0x00000040
232 #define FILE_READ_ATTRIBUTES 0x00000080 /* Attributes associated with the */
234 #define FILE_WRITE_ATTRIBUTES 0x00000100 /* Attributes associated with the */
236 #define DELETE 0x00010000 /* The file can be deleted */
237 #define READ_CONTROL 0x00020000 /* The access control list and */
240 #define WRITE_DAC 0x00040000 /* The access control list and */
243 #define WRITE_OWNER 0x00080000 /* Ownership information associated */
245 #define SYNCHRONIZE 0x00100000 /* The file handle can waited on to */
248 #define GENERIC_ALL 0x10000000
249 #define GENERIC_EXECUTE 0x20000000
250 #define GENERIC_WRITE 0x40000000
251 #define GENERIC_READ 0x80000000
287 #define CIFS_NO_HANDLE 0xFFFF
289 #define NO_CHANGE_64 0xFFFFFFFFFFFFFFFFULL
297 /* Unicode Null terminate 2 bytes of 0 */
299 #define ASCII_NULL 0x00
304 #define CIFS_SV_TYPE_DC 0x00000008
305 #define CIFS_SV_TYPE_BACKDC 0x00000010
310 #define CIFS_ALIAS_TYPE_FILE 0x0001
311 #define CIFS_SHARE_TYPE_FILE 0x0000
316 #define ATTR_READONLY 0x0001
317 #define ATTR_HIDDEN 0x0002
318 #define ATTR_SYSTEM 0x0004
319 #define ATTR_VOLUME 0x0008
320 #define ATTR_DIRECTORY 0x0010
321 #define ATTR_ARCHIVE 0x0020
322 #define ATTR_DEVICE 0x0040
323 #define ATTR_NORMAL 0x0080
324 #define ATTR_TEMPORARY 0x0100
325 #define ATTR_SPARSE 0x0200
326 #define ATTR_REPARSE 0x0400
327 #define ATTR_COMPRESSED 0x0800
328 #define ATTR_OFFLINE 0x1000 /* ie file not immediately available -
330 #define ATTR_NOT_CONTENT_INDEXED 0x2000
331 #define ATTR_ENCRYPTED 0x4000
332 #define ATTR_POSIX_SEMANTICS 0x01000000
333 #define ATTR_BACKUP_SEMANTICS 0x02000000
334 #define ATTR_DELETE_ON_CLOSE 0x04000000
335 #define ATTR_SEQUENTIAL_SCAN 0x08000000
336 #define ATTR_RANDOM_ACCESS 0x10000000
337 #define ATTR_NO_BUFFERING 0x20000000
338 #define ATTR_WRITE_THROUGH 0x80000000
341 #define FILE_NO_SHARE 0x00000000
342 #define FILE_SHARE_READ 0x00000001
343 #define FILE_SHARE_WRITE 0x00000002
344 #define FILE_SHARE_DELETE 0x00000004
345 #define FILE_SHARE_ALL 0x00000007
348 #define FILE_SUPERSEDE 0x00000000
349 #define FILE_OPEN 0x00000001
350 #define FILE_CREATE 0x00000002
351 #define FILE_OPEN_IF 0x00000003
352 #define FILE_OVERWRITE 0x00000004
353 #define FILE_OVERWRITE_IF 0x00000005
356 #define CREATE_NOT_FILE 0x00000001 /* if set must not be file */
357 #define CREATE_WRITE_THROUGH 0x00000002
358 #define CREATE_SEQUENTIAL 0x00000004
359 #define CREATE_NO_BUFFER 0x00000008 /* should not buffer on srv */
360 #define CREATE_SYNC_ALERT 0x00000010 /* MBZ */
361 #define CREATE_ASYNC_ALERT 0x00000020 /* MBZ */
362 #define CREATE_NOT_DIR 0x00000040 /* if set must not be directory */
363 #define CREATE_TREE_CONNECTION 0x00000080 /* should be zero */
364 #define CREATE_COMPLETE_IF_OPLK 0x00000100 /* should be zero */
365 #define CREATE_NO_EA_KNOWLEDGE 0x00000200
366 #define CREATE_EIGHT_DOT_THREE 0x00000400 /* doc says this is obsolete
369 #define CREATE_OPEN_FOR_RECOVERY 0x00000400
370 #define CREATE_RANDOM_ACCESS 0x00000800
371 #define CREATE_DELETE_ON_CLOSE 0x00001000
372 #define CREATE_OPEN_BY_ID 0x00002000
373 #define CREATE_OPEN_BACKUP_INTENT 0x00004000
374 #define CREATE_NO_COMPRESSION 0x00008000
375 #define CREATE_RESERVE_OPFILTER 0x00100000 /* should be zero */
376 #define OPEN_REPARSE_POINT 0x00200000
377 #define OPEN_NO_RECALL 0x00400000
378 #define OPEN_FREE_SPACE_QUERY 0x00800000 /* should be zero */
379 #define CREATE_OPTIONS_MASK 0x007FFFFF
380 #define CREATE_OPTION_READONLY 0x10000000
381 #define CREATE_OPTION_SPECIAL 0x20000000 /* system. NB not sent over wire */
384 #define SECURITY_ANONYMOUS 0
390 #define SECURITY_CONTEXT_TRACKING 0x01
391 #define SECURITY_EFFECTIVE_ONLY 0x02
396 #define CIFS_DFT_PID 0x1234
469 * Computer Name Length (since Netbios name was length 16 with last byte 0x20)
512 struct smb_hdr hdr; /* wct = 0 */
547 __le16 DialectIndex; /* 0xFFFF = no dialect acceptable */
573 #define SECMODE_USER 0x01 /* off indicates share level security */
574 #define SECMODE_PW_ENCRYPT 0x02
575 #define SECMODE_SIGN_ENABLED 0x04 /* SMB security signatures enabled */
576 #define SECMODE_SIGN_REQUIRED 0x08 /* SMB security signatures required */
579 #define CAP_RAW_MODE 0x00000001
580 #define CAP_MPX_MODE 0x00000002
581 #define CAP_UNICODE 0x00000004
582 #define CAP_LARGE_FILES 0x00000008
583 #define CAP_NT_SMBS 0x00000010 /* implies CAP_NT_FIND */
584 #define CAP_RPC_REMOTE_APIS 0x00000020
585 #define CAP_STATUS32 0x00000040
586 #define CAP_LEVEL_II_OPLOCKS 0x00000080
587 #define CAP_LOCK_AND_READ 0x00000100
588 #define CAP_NT_FIND 0x00000200
589 #define CAP_DFS 0x00001000
590 #define CAP_INFOLEVEL_PASSTHRU 0x00002000
591 #define CAP_LARGE_READ_X 0x00004000
592 #define CAP_LARGE_WRITE_X 0x00008000
593 #define CAP_LWIO 0x00010000 /* support fctl_srv_req_resume_key */
594 #define CAP_UNIX 0x00800000
595 #define CAP_COMPRESSED_DATA 0x02000000
596 #define CAP_DYNAMIC_REAUTH 0x20000000
597 #define CAP_PERSISTENT_HANDLES 0x40000000
598 #define CAP_EXTENDED_SECURITY 0x80000000
724 #define CAP_UNICODE 0x00000004
725 #define CAP_LARGE_FILES 0x00000008
726 #define CAP_NT_SMBS 0x00000010
727 #define CAP_STATUS32 0x00000040
728 #define CAP_LEVEL_II_OPLOCKS 0x00000080
729 #define CAP_NT_FIND 0x00000200 /* reserved should be zero
731 #define CAP_BULK_TRANSFER 0x20000000
732 #define CAP_EXTENDED_SECURITY 0x80000000
776 #define DISCONNECT_TID 0x0001
777 #define TCON_EXTENDED_SIGNATURES 0x0004
778 #define TCON_EXTENDED_SECINFO 0x0008
781 #define SMB_SUPPORT_SEARCH_BITS 0x0001 /* "must have" directory search bits
783 #define SMB_SHARE_IS_IN_DFS 0x0002
784 #define SMB_CSC_MASK 0x000C
786 #define SMB_CSC_CACHE_MANUAL_REINT 0x0000
787 #define SMB_CSC_CACHE_AUTO_REINT 0x0004
788 #define SMB_CSC_CACHE_VDO 0x0008
789 #define SMB_CSC_NO_CACHING 0x000C
790 #define SMB_UNIQUE_FILE_NAME 0x0010
791 #define SMB_EXTENDED_SIGNATURES 0x0020
837 struct smb_hdr hdr; /* wct = 0 */
838 __u16 ByteCount; /* bcc = 0 */
841 struct smb_hdr hdr; /* wct = 0 */
842 __u16 ByteCount; /* bcc = 0 */
850 __u16 ByteCount; /* 0 */
854 struct smb_hdr hdr; /* wct = 0 */
855 __u16 ByteCount; /* bct = 0 */
861 __u16 ByteCount; /* 0 */
867 __u16 ByteCount; /* 0 */
871 #define REQ_MORE_INFO 0x00000001 /* legacy (OPEN_AND_X) only */
872 #define REQ_OPLOCK 0x00000002
873 #define REQ_BATCHOPLOCK 0x00000004
874 #define REQ_OPENDIRONLY 0x00000008
875 #define REQ_EXTENDED_INFO 0x00000010
878 #define DISK_TYPE 0x0000
879 #define BYTE_PIPE_TYPE 0x0001
880 #define MESSAGE_PIPE_TYPE 0x0002
881 #define PRINTER_TYPE 0x0003
882 #define COMM_DEV_TYPE 0x0004
883 #define UNKNOWN_TYPE 0xFFFF
886 #define NO_EAS 0x0001
887 #define NO_SUBSTREAMS 0x0002
888 #define NO_REPARSETAG 0x0004
890 #define ICOUNT_MASK 0x00FF
891 #define PIPE_READ_MODE 0x0100
892 #define NAMED_PIPE_TYPE 0x0400
893 #define PIPE_END_POINT 0x4000
894 #define BLOCKING_NAMED_PIPE 0x8000
918 #define OPLOCK_NONE 0
924 #define CIFS_CREATE_ACTION 0x20000 /* file created */
944 __u16 ByteCount; /* bct = 0 */
969 __u16 ByteCount; /* bct = 0 */
1010 /* For encoding of POSIX Open Request - see trans2 function 0x209 data struct */
1119 #define LOCKING_ANDX_SHARED_LOCK 0x01
1120 #define LOCKING_ANDX_OPLOCK_RELEASE 0x02
1121 #define LOCKING_ANDX_CHANGE_LOCKTYPE 0x04
1122 #define LOCKING_ANDX_CANCEL_LOCK 0x08
1123 #define LOCKING_ANDX_LARGE_FILES 0x10 /* always on for us */
1141 #define CIFS_RDLCK 0
1145 __le16 lock_type; /* 0 = Read, 1 = Write, 2 = Unlock */
1172 #define COPY_MUST_BE_FILE 0x0001
1173 #define COPY_MUST_BE_DIR 0x0002
1174 #define COPY_TARGET_MODE_ASCII 0x0004 /* if not set, binary */
1175 #define COPY_SOURCE_MODE_ASCII 0x0008 /* if not set, binary */
1176 #define COPY_VERIFY_WRITES 0x0010
1177 #define COPY_TREE 0x0020
1195 __u8 BufferFormat; /* 0x04 - only present if errored file follows */
1199 #define CREATE_HARD_LINK 0x103
1200 #define MOVEFILE_COPY_ALLOWED 0x0002
1201 #define MOVEFILE_REPLACE_EXISTING 0x0001
1216 struct smb_hdr hdr; /* wct = 0 */
1217 __u16 ByteCount; /* bct = 0 */
1229 struct smb_hdr hdr; /* wct = 0 */
1230 __u16 ByteCount; /* bct = 0 */
1234 struct smb_hdr hdr; /* wct = 0 */
1241 struct smb_hdr hdr; /* wct = 0 */
1242 __u16 ByteCount; /* bct = 0 */
1246 struct smb_hdr hdr; /* wct = 0 */
1253 struct smb_hdr hdr; /* wct = 0 */
1254 __u16 ByteCount; /* bct = 0 */
1258 struct smb_hdr hdr; /* wct = 0 */
1270 __le16 ByteCount; /* bcc = 0 */
1285 struct smb_hdr hdr; /* wct = 0 */
1286 __u16 ByteCount; /* bct = 0 */
1328 __u8 SetupCount; /* 0 */
1359 __u8 IsFsctl; /* 1 = File System Control 0 = device control (IOCTL) */
1383 __u8 IsFsctl; /* 1 = File System Control 0 = device control (IOCTL) */
1391 #define COMPRESSION_FORMAT_NONE 0x0000
1392 #define COMPRESSION_FORMAT_DEFAULT 0x0001
1393 #define COMPRESSION_FORMAT_LZNT1 0x0002
1498 __u8 SetupCount; /* 0 */
1503 #define FILE_NOTIFY_CHANGE_FILE_NAME 0x00000001
1504 #define FILE_NOTIFY_CHANGE_DIR_NAME 0x00000002
1505 #define FILE_NOTIFY_CHANGE_NAME 0x00000003
1506 #define FILE_NOTIFY_CHANGE_ATTRIBUTES 0x00000004
1507 #define FILE_NOTIFY_CHANGE_SIZE 0x00000008
1508 #define FILE_NOTIFY_CHANGE_LAST_WRITE 0x00000010
1509 #define FILE_NOTIFY_CHANGE_LAST_ACCESS 0x00000020
1510 #define FILE_NOTIFY_CHANGE_CREATION 0x00000040
1511 #define FILE_NOTIFY_CHANGE_EA 0x00000080
1512 #define FILE_NOTIFY_CHANGE_SECURITY 0x00000100
1513 #define FILE_NOTIFY_CHANGE_STREAM_NAME 0x00000200
1514 #define FILE_NOTIFY_CHANGE_STREAM_SIZE 0x00000400
1515 #define FILE_NOTIFY_CHANGE_STREAM_WRITE 0x00000800
1517 #define FILE_ACTION_ADDED 0x00000001
1518 #define FILE_ACTION_REMOVED 0x00000002
1519 #define FILE_ACTION_MODIFIED 0x00000003
1520 #define FILE_ACTION_RENAMED_OLD_NAME 0x00000004
1521 #define FILE_ACTION_RENAMED_NEW_NAME 0x00000005
1522 #define FILE_ACTION_ADDED_STREAM 0x00000006
1523 #define FILE_ACTION_REMOVED_STREAM 0x00000007
1524 #define FILE_ACTION_MODIFIED_STREAM 0x00000008
1548 #define SYMLINK_FLAG_RELATIVE 0x00000001
1551 #define NFS_SPECFILE_LNK 0x00000000014B4E4C
1552 #define NFS_SPECFILE_CHR 0x0000000000524843
1553 #define NFS_SPECFILE_BLK 0x00000000004B4C42
1554 #define NFS_SPECFILE_FIFO 0x000000004F464946
1555 #define NFS_SPECFILE_SOCK 0x000000004B434F53
1565 __u32 rsrvd1; /* 0 */
1567 __u64 rsrvd2; /* 0 */
1575 #define QUOTA_LIST_CONTINUE 0
1576 #define QUOTA_LIST_START 0x100
1577 #define QUOTA_FOR_SID 0x101
1636 #define SMB_QUERY_FILE_BASIC_INFO 0x101
1637 #define SMB_QUERY_FILE_STANDARD_INFO 0x102
1638 #define SMB_QUERY_FILE_EA_INFO 0x103
1639 #define SMB_QUERY_FILE_NAME_INFO 0x104
1640 #define SMB_QUERY_FILE_ALLOCATION_INFO 0x105
1641 #define SMB_QUERY_FILE_END_OF_FILEINFO 0x106
1642 #define SMB_QUERY_FILE_ALL_INFO 0x107
1643 #define SMB_QUERY_ALT_NAME_INFO 0x108
1644 #define SMB_QUERY_FILE_STREAM_INFO 0x109
1645 #define SMB_QUERY_FILE_COMPRESSION_INFO 0x10B
1646 #define SMB_QUERY_FILE_UNIX_BASIC 0x200
1647 #define SMB_QUERY_FILE_UNIX_LINK 0x201
1648 #define SMB_QUERY_POSIX_ACL 0x204
1649 #define SMB_QUERY_XATTR 0x205 /* e.g. system EA name space */
1650 #define SMB_QUERY_ATTR_FLAGS 0x206 /* append,immutable etc. */
1651 #define SMB_QUERY_POSIX_PERMISSION 0x207
1652 #define SMB_QUERY_POSIX_LOCK 0x208
1653 /* #define SMB_POSIX_OPEN 0x209 */
1654 /* #define SMB_POSIX_UNLINK 0x20a */
1655 #define SMB_QUERY_FILE__UNIX_INFO2 0x20b
1656 #define SMB_QUERY_FILE_INTERNAL_INFO 0x3ee
1657 #define SMB_QUERY_FILE_ACCESS_INFO 0x3f0
1658 #define SMB_QUERY_FILE_NAME_INFO2 0x3f1 /* 0x30 bytes */
1659 #define SMB_QUERY_FILE_POSITION_INFO 0x3f6
1660 #define SMB_QUERY_FILE_MODE_INFO 0x3f8
1661 #define SMB_QUERY_FILE_ALGN_INFO 0x3f9
1664 #define SMB_SET_FILE_BASIC_INFO 0x101
1665 #define SMB_SET_FILE_DISPOSITION_INFO 0x102
1666 #define SMB_SET_FILE_ALLOCATION_INFO 0x103
1667 #define SMB_SET_FILE_END_OF_FILE_INFO 0x104
1668 #define SMB_SET_FILE_UNIX_BASIC 0x200
1669 #define SMB_SET_FILE_UNIX_LINK 0x201
1670 #define SMB_SET_FILE_UNIX_HLINK 0x203
1671 #define SMB_SET_POSIX_ACL 0x204
1672 #define SMB_SET_XATTR 0x205
1673 #define SMB_SET_ATTR_FLAGS 0x206 /* append, immutable etc. */
1674 #define SMB_SET_POSIX_LOCK 0x208
1675 #define SMB_POSIX_OPEN 0x209
1676 #define SMB_POSIX_UNLINK 0x20a
1677 #define SMB_SET_FILE_UNIX_INFO2 0x20b
1678 #define SMB_SET_FILE_BASIC_INFO2 0x3ec
1679 #define SMB_SET_FILE_RENAME_INFORMATION 0x3f2 /* BB check if qpathinfo too */
1680 #define SMB_FILE_ALL_INFO2 0x3fa
1681 #define SMB_SET_FILE_ALLOCATION_INFO2 0x3fb
1682 #define SMB_SET_FILE_END_OF_FILE_INFO2 0x3fc
1683 #define SMB_FILE_MOVE_CLUSTER_INFO 0x407
1684 #define SMB_FILE_QUOTA_INFO 0x408
1685 #define SMB_FILE_REPARSEPOINT_INFO 0x409
1686 #define SMB_FILE_MAXIMUM_INFO 0x40d
1689 #define SMB_FIND_FILE_INFO_STANDARD 0x001
1690 #define SMB_FIND_FILE_QUERY_EA_SIZE 0x002
1691 #define SMB_FIND_FILE_QUERY_EAS_FROM_LIST 0x003
1692 #define SMB_FIND_FILE_DIRECTORY_INFO 0x101
1693 #define SMB_FIND_FILE_FULL_DIRECTORY_INFO 0x102
1694 #define SMB_FIND_FILE_NAMES_INFO 0x103
1695 #define SMB_FIND_FILE_BOTH_DIRECTORY_INFO 0x104
1696 #define SMB_FIND_FILE_ID_FULL_DIR_INFO 0x105
1697 #define SMB_FIND_FILE_ID_BOTH_DIR_INFO 0x106
1698 #define SMB_FIND_FILE_UNIX 0x202
1699 #define SMB_FIND_FILE_POSIX_INFO 0x064
1826 #define CIFS_SEARCH_CLOSE_ALWAYS 0x0001
1827 #define CIFS_SEARCH_CLOSE_AT_END 0x0002
1828 #define CIFS_SEARCH_RETURN_RESUME 0x0004
1829 #define CIFS_SEARCH_CONTINUE_FROM_LAST 0x0008
1830 #define CIFS_SEARCH_BACKUP_SEARCH 0x0010
1923 #define SMB_QUERY_FS_VOLUME_INFO 0x102
1924 #define SMB_QUERY_FS_SIZE_INFO 0x103
1925 #define SMB_QUERY_FS_DEVICE_INFO 0x104
1926 #define SMB_QUERY_FS_ATTRIBUTE_INFO 0x105
1927 #define SMB_QUERY_CIFS_UNIX_INFO 0x200
1928 #define SMB_QUERY_POSIX_FS_INFO 0x201
1929 #define SMB_QUERY_POSIX_WHO_AM_I 0x202
1930 #define SMB_REQUEST_TRANSPORT_ENCRYPTION 0x203
1931 #define SMB_QUERY_FS_PROXY 0x204 /* WAFS enabled. Returns structure
1934 (0xACE) for WAN friendly SMB
1936 #define SMB_QUERY_LABEL_INFO 0x3ea
1937 #define SMB_QUERY_FS_QUOTA_INFO 0x3ee
1938 #define SMB_QUERY_FS_FULL_SIZE_INFO 0x3ef
1939 #define SMB_QUERY_OBJECTID_INFO 0x3f0
1971 typedef struct whoami_rsp_data { /* Query level 0x202 */
1972 __u32 flags; /* 0 = Authenticated user 1 = GUEST */
1973 __u32 mask; /* which flags bits server understands ie 0x0001 */
1980 /* __u64 gid_array[0]; */ /* may be empty */
1985 #define SMB_SET_CIFS_UNIX_INFO 0x200
1986 /* level 0x203 is defined above in list of QFS info levels */
1987 /* #define SMB_REQUEST_TRANSPORT_ENCRYPTION 0x203 */
1989 /* Level 0x200 request structure follows */
2017 /* level 0x203 request structure follows */
2043 /* response for setfsinfo levels 0x200 and 0x203 */
2069 __u8 Pad[3]; /* Win2K has sent 0x0F01 (max response length
2076 #define DFS_VERSION cpu_to_le16(0x0003)
2079 #define DFS_TYPE_LINK 0x0000 /* also for sysvol targets */
2080 #define DFS_TYPE_ROOT 0x0001
2083 #define DFS_NAME_LIST_REF 0x0200 /* set for domain or DC referral responses */
2084 #define DFS_TARGET_SET_BOUNDARY 0x0400 /* only valid with version 4 dfs req */
2089 __le16 ServerType; /* 0x0001 = root targets; 0x0000 = link targets */
2115 #define DFSREF_REFERRAL_SERVER 0x00000001 /* all targets are DFS roots */
2116 #define DFSREF_STORAGE_SERVER 0x00000002 /* no further ref requests needed */
2117 #define DFSREF_TARGET_FAILBACK 0x00000004 /* only for DFS referral version 4 */
2168 } __attribute__((packed)) FILE_SYSTEM_INFO; /* size info, level 0x103 */
2182 } __attribute__((packed)) FILE_SYSTEM_UNIX_INFO; /* Unix extension level 0x200*/
2186 #define CIFS_UNIX_MINOR_VERSION 0
2189 #define CIFS_UNIX_FCNTL_CAP 0x00000001 /* support for fcntl locks */
2190 #define CIFS_UNIX_POSIX_ACL_CAP 0x00000002 /* support getfacl/setfacl */
2191 #define CIFS_UNIX_XATTR_CAP 0x00000004 /* support new namespace */
2192 #define CIFS_UNIX_EXTATTR_CAP 0x00000008 /* support chattr/chflag */
2193 #define CIFS_UNIX_POSIX_PATHNAMES_CAP 0x00000010 /* Allow POSIX path chars */
2194 #define CIFS_UNIX_POSIX_PATH_OPS_CAP 0x00000020 /* Allow new POSIX path based
2197 #define CIFS_UNIX_LARGE_READ_CAP 0x00000040 /* support reads >128K (up
2198 to 0xFFFF00 */
2199 #define CIFS_UNIX_LARGE_WRITE_CAP 0x00000080
2200 #define CIFS_UNIX_TRANSPORT_ENCRYPTION_CAP 0x00000100 /* can do SPNEGO crypt */
2201 #define CIFS_UNIX_TRANSPORT_ENCRYPTION_MANDATORY_CAP 0x00000200 /* must do */
2202 #define CIFS_UNIX_PROXY_CAP 0x00000400 /* Proxy cap: 0xACE ioctl and
2205 /* presumably don't need the 0x20 POSIX_PATH_OPS_CAP since we never send
2210 /* #define CIFS_UNIX_CAP_MASK 0x000000fb */
2211 #define CIFS_UNIX_CAP_MASK 0x000003db
2213 #define CIFS_UNIX_CAP_MASK 0x00000013
2217 #define CIFS_POSIX_EXTENSIONS 0x00000010 /* support for new QFSInfo */
2227 to make a second call (to QFSInfo level 0x103 to get this info.
2242 #define FILE_DEVICE_CD_ROM 0x00000002
2243 #define FILE_DEVICE_CD_ROM_FILE_SYSTEM 0x00000003
2244 #define FILE_DEVICE_DFS 0x00000006
2245 #define FILE_DEVICE_DISK 0x00000007
2246 #define FILE_DEVICE_DISK_FILE_SYSTEM 0x00000008
2247 #define FILE_DEVICE_FILE_SYSTEM 0x00000009
2248 #define FILE_DEVICE_NAMED_PIPE 0x00000011
2249 #define FILE_DEVICE_NETWORK 0x00000012
2250 #define FILE_DEVICE_NETWORK_FILE_SYSTEM 0x00000014
2251 #define FILE_DEVICE_NULL 0x00000015
2252 #define FILE_DEVICE_PARALLEL_PORT 0x00000016
2253 #define FILE_DEVICE_PRINTER 0x00000018
2254 #define FILE_DEVICE_SERIAL_PORT 0x0000001b
2255 #define FILE_DEVICE_STREAMS 0x0000001e
2256 #define FILE_DEVICE_TAPE 0x0000001f
2257 #define FILE_DEVICE_TAPE_FILE_SYSTEM 0x00000020
2258 #define FILE_DEVICE_VIRTUAL_DISK 0x00000024
2259 #define FILE_DEVICE_NETWORK_REDIRECTOR 0x00000028
2262 #define FILE_REMOVABLE_MEDIA 0x00000001
2263 #define FILE_READ_ONLY_DEVICE 0x00000002
2264 #define FILE_FLOPPY_DISKETTE 0x00000004
2265 #define FILE_WRITE_ONCE_MEDIA 0x00000008
2266 #define FILE_REMOTE_DEVICE 0x00000010
2267 #define FILE_DEVICE_IS_MOUNTED 0x00000020
2268 #define FILE_VIRTUAL_VOLUME 0x00000040
2269 #define FILE_DEVICE_SECURE_OPEN 0x00000100
2270 #define FILE_CHARACTERISTIC_TS_DEVICE 0x00001000
2271 #define FILE_CHARACTERISTIC_WEBDAV_DEVICE 0x00002000
2272 #define FILE_PORTABLE_DEVICE 0x00004000
2273 #define FILE_DEVICE_ALLOW_APPCONTAINER_TRAVERSAL 0x00020000
2278 } __attribute__((packed)) FILE_SYSTEM_DEVICE_INFO; /* device info level 0x104 */
2285 #define FILE_SUPPORTS_SPARSE_VDL 0x10000000 /* faster nonsparse extend */
2286 #define FILE_SUPPORTS_BLOCK_REFCOUNTING 0x08000000 /* allow ioctl dup extents */
2287 #define FILE_SUPPORT_INTEGRITY_STREAMS 0x04000000
2288 #define FILE_SUPPORTS_USN_JOURNAL 0x02000000
2289 #define FILE_SUPPORTS_OPEN_BY_FILE_ID 0x01000000
2290 #define FILE_SUPPORTS_EXTENDED_ATTRIBUTES 0x00800000
2291 #define FILE_SUPPORTS_HARD_LINKS 0x00400000
2292 #define FILE_SUPPORTS_TRANSACTIONS 0x00200000
2293 #define FILE_SEQUENTIAL_WRITE_ONCE 0x00100000
2294 #define FILE_READ_ONLY_VOLUME 0x00080000
2295 #define FILE_NAMED_STREAMS 0x00040000
2296 #define FILE_SUPPORTS_ENCRYPTION 0x00020000
2297 #define FILE_SUPPORTS_OBJECT_IDS 0x00010000
2298 #define FILE_VOLUME_IS_COMPRESSED 0x00008000
2299 #define FILE_SUPPORTS_REMOTE_STORAGE 0x00000100
2300 #define FILE_SUPPORTS_REPARSE_POINTS 0x00000080
2301 #define FILE_SUPPORTS_SPARSE_FILES 0x00000040
2302 #define FILE_VOLUME_QUOTAS 0x00000020
2303 #define FILE_FILE_COMPRESSION 0x00000010
2304 #define FILE_PERSISTENT_ACLS 0x00000008
2305 #define FILE_UNICODE_ON_DISK 0x00000004
2306 #define FILE_CASE_PRESERVED_NAMES 0x00000002
2307 #define FILE_CASE_SENSITIVE_SEARCH 0x00000001
2340 } __attribute__((packed)) FILE_ALL_INFO; /* level 0x107 QPathInfo */
2349 } __attribute__((packed)) FILE_STANDARD_INFO; /* level 0x102 QPathInfo */
2353 #define UNIX_FILE 0
2374 } __attribute__((packed)) FILE_UNIX_BASIC_INFO; /* level 0x200 QPathInfo */
2378 } __attribute__((packed)) FILE_UNIX_LINK_INFO; /* level 0x201 QPathInfo */
2415 } __attribute__((packed)) FILE_BASIC_INFO; /* size info, level 0x101 */
2419 } __attribute__((packed)); /* size used on disk, for level 0x103 for set,
2420 0x105 for query */
2424 } __attribute__((packed)); /* size info, level 0x104 for set, 0x106 for query */
2428 } __attribute__((packed)); /* level 0x0108 */
2436 }; /* level 0x109 */
2445 } __attribute__((packed)); /* level 0x10b */
2462 } __attribute__((packed)); /* level 0x204 */
2465 /* #define CIFS_POSIX_ACL_USER_OBJ 0x01
2466 #define CIFS_POSIX_ACL_USER 0x02
2467 #define CIFS_POSIX_ACL_GROUP_OBJ 0x04
2468 #define CIFS_POSIX_ACL_GROUP 0x08
2469 #define CIFS_POSIX_ACL_MASK 0x10
2470 #define CIFS_POSIX_ACL_OTHER 0x20 */
2473 /* #define CIFS_POSIX_ACL_EXECUTE 0x01
2474 #define CIFS_POSIX_ACL_WRITE 0x02
2475 #define CIFS_POSIX_ACL_READ 0x04 */
2480 #define SMB_O_RDONLY 0x1
2481 #define SMB_O_WRONLY 0x2
2482 #define SMB_O_RDWR 0x4
2483 #define SMB_O_CREAT 0x10
2484 #define SMB_O_EXCL 0x20
2485 #define SMB_O_TRUNC 0x40
2486 #define SMB_O_APPEND 0x80
2487 #define SMB_O_SYNC 0x100
2488 #define SMB_O_DIRECTORY 0x200
2489 #define SMB_O_NOFOLLOW 0x400
2490 #define SMB_O_DIRECT 0x800
2497 } __attribute__((packed)) OPEN_PSX_REQ; /* level 0x209 SetPathInfo data */
2506 } __attribute__((packed)) OPEN_PSX_RSP; /* level 0x209 SetPathInfo data */
2508 #define SMB_POSIX_UNLINK_FILE_TARGET 0
2511 struct unlink_psx_rq { /* level 0x20a SetPathInfo */
2517 } __attribute__((packed)); /* level 0x3ee */
2521 } __attribute__((packed)); /* level 0x3f8 */
2526 } __attribute__((packed)); /* level 0x40b */
2538 } __attribute__((packed)) FILE_UNIX_INFO; /* level 0x202 */
2552 } __attribute__((packed)) FILE_DIRECTORY_INFO; /* level 0x101 FF resp data */
2567 } __attribute__((packed)) FILE_FULL_DIRECTORY_INFO; /* level 0x102 rsp data */
2584 } __attribute__((packed)) SEARCH_ID_FULL_DIR_INFO; /* level 0x105 FF rsp data */
2602 } __attribute__((packed)) FILE_BOTH_DIRECTORY_INFO; /* level 0x104 FFrsp data */
2617 } __attribute__((packed)) FIND_FILE_STANDARD_INFO; /* level 0x1 FF resp data */
2644 #define FEA_NEEDEA 0x80 /* need EA bit */
2754 /* md5 of valid subset of path ie path[0] through path[length-1] */
2757 /* if room left, then end with \n then 0x20s by convention but not required */
2768 level 0x205 */
2776 (chattr, chflags) level 0x206 */