Kconfig 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220
  1. # SPDX-License-Identifier: GPL-2.0-only
  2. config CIFS
  3. tristate "SMB3 and CIFS support (advanced network filesystem)"
  4. depends on INET
  5. select NLS
  6. select NLS_UCS2_UTILS
  7. select CRYPTO
  8. select CRYPTO_MD5
  9. select CRYPTO_SHA256
  10. select CRYPTO_SHA512
  11. select CRYPTO_CMAC
  12. select CRYPTO_HMAC
  13. select CRYPTO_AEAD2
  14. select CRYPTO_CCM
  15. select CRYPTO_GCM
  16. select CRYPTO_ECB
  17. select CRYPTO_AES
  18. select KEYS
  19. select DNS_RESOLVER
  20. select ASN1
  21. select OID_REGISTRY
  22. select NETFS_SUPPORT
  23. help
  24. This is the client VFS module for the SMB3 family of network file
  25. protocols (including the most recent, most secure dialect SMB3.1.1).
  26. This module also includes support for earlier dialects such as
  27. SMB2.1, SMB2 and even the old Common Internet File System (CIFS)
  28. protocol. CIFS was the successor to the original network filesystem
  29. protocol, Server Message Block (SMB ie SMB1), the native file sharing
  30. mechanism for most early PC operating systems.
  31. The SMB3.1.1 protocol is supported by most modern operating systems
  32. and NAS appliances (e.g. Samba, Windows 11, Windows Server 2022,
  33. MacOS) and even in the cloud (e.g. Microsoft Azure) and also by the
  34. Linux kernel server, ksmbd. Support for the older CIFS protocol was
  35. included in Windows NT4, 2000 and XP (and later). Use of dialects
  36. older than SMB2.1 is often discouraged on public networks.
  37. This module also provides limited support for OS/2 and Windows ME
  38. and similar very old servers.
  39. This module provides an advanced network file system client for
  40. mounting to SMB3 (and CIFS) compliant servers. It includes support
  41. for DFS (hierarchical name space), secure per-user session
  42. establishment via Kerberos or NTLMv2, RDMA (smbdirect), advanced
  43. security features, per-share encryption, packet-signing, snapshots,
  44. directory leases, safe distributed caching (leases), multichannel,
  45. Unicode and other internationalization improvements.
  46. In general, the default dialects, SMB3 and later, enable better
  47. performance, security and features, than would be possible with CIFS.
  48. If you need to mount to Samba, Azure, ksmbd, Macs or Windows from this
  49. machine, say Y.
  50. config CIFS_STATS2
  51. bool "Extended statistics"
  52. depends on CIFS
  53. default y
  54. help
  55. Enabling this option will allow more detailed statistics on SMB
  56. request timing to be displayed in /proc/fs/cifs/DebugData and also
  57. allow optional logging of slow responses to dmesg (depending on the
  58. value of /proc/fs/cifs/cifsFYI). See Documentation/admin-guide/cifs/usage.rst
  59. for more details. These additional statistics may have a minor effect
  60. on performance and memory utilization.
  61. If unsure, say Y.
  62. config CIFS_ALLOW_INSECURE_LEGACY
  63. bool "Support legacy servers which use less secure dialects"
  64. depends on CIFS
  65. default y
  66. help
  67. Modern dialects, SMB2.1 and later (including SMB3 and 3.1.1), have
  68. additional security features, including protection against
  69. man-in-the-middle attacks and stronger crypto hashes, so the use
  70. of legacy dialects (SMB1/CIFS and SMB2.0) is discouraged.
  71. Disabling this option prevents users from using vers=1.0 or vers=2.0
  72. on mounts with cifs.ko
  73. If unsure, say Y.
  74. config CIFS_UPCALL
  75. bool "Kerberos/SPNEGO advanced session setup"
  76. depends on CIFS
  77. help
  78. Enables an upcall mechanism for CIFS which accesses userspace helper
  79. utilities to provide SPNEGO packaged (RFC 4178) Kerberos tickets
  80. which are needed to mount to certain secure servers (for which more
  81. secure Kerberos authentication is required). If unsure, say Y.
  82. config CIFS_XATTR
  83. bool "CIFS extended attributes"
  84. depends on CIFS
  85. help
  86. Extended attributes are name:value pairs associated with inodes by
  87. the kernel or by users (see the attr(5) manual page for details).
  88. CIFS maps the name of extended attributes beginning with the user
  89. namespace prefix to SMB/CIFS EAs. EAs are stored on Windows
  90. servers without the user namespace prefix, but their names are
  91. seen by Linux cifs clients prefaced by the user namespace prefix.
  92. The system namespace (used by some filesystems to store ACLs) is
  93. not supported at this time.
  94. If unsure, say Y.
  95. config CIFS_POSIX
  96. bool "CIFS POSIX Extensions"
  97. depends on CIFS && CIFS_ALLOW_INSECURE_LEGACY && CIFS_XATTR
  98. help
  99. Enabling this option will cause the cifs client to attempt to
  100. negotiate a feature of the older cifs dialect with servers, such as
  101. Samba 3.0.5 or later, that optionally can handle more POSIX like
  102. (rather than Windows like) file behavior. It also enables support
  103. for POSIX ACLs (getfacl and setfacl) to servers (such as Samba 3.10
  104. and later) which can negotiate CIFS POSIX ACL support. This config
  105. option is not needed when mounting with SMB3.1.1. If unsure, say N.
  106. config CIFS_DEBUG
  107. bool "Enable CIFS debugging routines"
  108. default y
  109. depends on CIFS
  110. help
  111. Enabling this option adds helpful debugging messages to
  112. the cifs code which increases the size of the cifs module.
  113. If unsure, say Y.
  114. config CIFS_DEBUG2
  115. bool "Enable additional CIFS debugging routines"
  116. depends on CIFS_DEBUG
  117. help
  118. Enabling this option adds a few more debugging routines
  119. to the cifs code which slightly increases the size of
  120. the cifs module and can cause additional logging of debug
  121. messages in some error paths, slowing performance. This
  122. option can be turned off unless you are debugging
  123. cifs problems. If unsure, say N.
  124. config CIFS_DEBUG_DUMP_KEYS
  125. bool "Dump encryption keys for offline decryption (Unsafe)"
  126. depends on CIFS_DEBUG
  127. help
  128. Enabling this will dump the encryption and decryption keys
  129. used to communicate on an encrypted share connection on the
  130. console. This allows Wireshark to decrypt and dissect
  131. encrypted network captures. Enable this carefully.
  132. If unsure, say N.
  133. config CIFS_DFS_UPCALL
  134. bool "DFS feature support"
  135. depends on CIFS
  136. help
  137. Distributed File System (DFS) support is used to access shares
  138. transparently in an enterprise name space, even if the share
  139. moves to a different server. This feature also enables
  140. an upcall mechanism for CIFS which contacts userspace helper
  141. utilities to provide server name resolution (host names to
  142. IP addresses) which is needed in order to reconnect to
  143. servers if their addresses change or for implicit mounts of
  144. DFS junction points. If unsure, say Y.
  145. config CIFS_SWN_UPCALL
  146. bool "SWN feature support"
  147. depends on CIFS
  148. help
  149. The Service Witness Protocol (SWN) is used to get notifications
  150. from a highly available server of resource state changes. This
  151. feature enables an upcall mechanism for CIFS which contacts a
  152. userspace daemon to establish the DCE/RPC connection to retrieve
  153. the cluster available interfaces and resource change notifications.
  154. If unsure, say Y.
  155. config CIFS_NFSD_EXPORT
  156. bool "Allow nfsd to export CIFS file system"
  157. depends on CIFS && BROKEN
  158. help
  159. Allows NFS server to export a CIFS mounted share (nfsd over cifs)
  160. if CIFS
  161. config CIFS_SMB_DIRECT
  162. bool "SMB Direct support"
  163. depends on CIFS=m && INFINIBAND && INFINIBAND_ADDR_TRANS || CIFS=y && INFINIBAND=y && INFINIBAND_ADDR_TRANS=y
  164. help
  165. Enables SMB Direct support for SMB 3.0, 3.02 and 3.1.1.
  166. SMB Direct allows transferring SMB packets over RDMA. If unsure,
  167. say Y.
  168. config CIFS_FSCACHE
  169. bool "Provide CIFS client caching support"
  170. depends on CIFS=m && FSCACHE || CIFS=y && FSCACHE=y
  171. help
  172. Makes CIFS FS-Cache capable. Say Y here if you want your CIFS data
  173. to be cached locally on disk through the general filesystem cache
  174. manager. If unsure, say N.
  175. config CIFS_ROOT
  176. bool "SMB root file system (Experimental)"
  177. depends on CIFS=y && IP_PNP
  178. help
  179. Enables root file system support over SMB protocol.
  180. Most people say N here.
  181. config CIFS_COMPRESSION
  182. bool "SMB message compression (Experimental)"
  183. depends on CIFS
  184. default n
  185. help
  186. Enables over-the-wire message compression for SMB 3.1.1
  187. mounts when negotiated with the server.
  188. Only write requests with data size >= PAGE_SIZE will be
  189. compressed to avoid wasting resources.
  190. Say Y here if you want SMB traffic to be compressed.
  191. If unsure, say N.
  192. endif