From: Namjae Jeon <namjae.jeon@samsung.com>
To: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-cifs@vger.kernel.org
Cc: linux-cifsd-devel@lists.sourceforge.net,
aurelien.aptel@gmail.com, senozhatsky@chromium.org,
sandeen@sandeen.net, willy@infradead.org, hch@infradead.org,
viro@zeniv.linux.org.uk, ronniesahlberg@gmail.com,
dan.carpenter@oracle.com, hch@lst.de, christian@brauner.io,
smfrench@gmail.com, hyc.lee@gmail.com,
Namjae Jeon <namjae.jeon@samsung.com>,
Steve French <stfrench@microsoft.com>
Subject: [PATCH v6 12/13] ksmbd: add Kconfig and Makefile
Date: Fri, 16 Jul 2021 08:53:55 +0900 [thread overview]
Message-ID: <20210715235356.3191-13-namjae.jeon@samsung.com> (raw)
In-Reply-To: <20210715235356.3191-1-namjae.jeon@samsung.com>
This adds the Kconfig and Makefile for ksmbd.
Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
Signed-off-by: Sergey Senozhatsky <senozhatsky@chromium.org>
Signed-off-by: Hyunchul Lee <hyc.lee@gmail.com>
Acked-by: Ronnie Sahlberg <lsahlber@redhat.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
---
fs/Kconfig | 1 +
fs/Makefile | 1 +
fs/ksmbd/Kconfig | 69 +++++++++++++++++++++++++++++++++++++++++++++++
fs/ksmbd/Makefile | 20 ++++++++++++++
4 files changed, 91 insertions(+)
create mode 100644 fs/ksmbd/Kconfig
create mode 100644 fs/ksmbd/Makefile
diff --git a/fs/Kconfig b/fs/Kconfig
index a7749c126b8e..9237728678cd 100644
--- a/fs/Kconfig
+++ b/fs/Kconfig
@@ -359,6 +359,7 @@ config NFS_V4_2_SSC_HELPER
source "net/sunrpc/Kconfig"
source "fs/ceph/Kconfig"
source "fs/cifs/Kconfig"
+source "fs/ksmbd/Kconfig"
source "fs/coda/Kconfig"
source "fs/afs/Kconfig"
source "fs/9p/Kconfig"
diff --git a/fs/Makefile b/fs/Makefile
index 9c708e1fbe8f..e03a048b2cd8 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -98,6 +98,7 @@ obj-$(CONFIG_NLS) += nls/
obj-$(CONFIG_UNICODE) += unicode/
obj-$(CONFIG_SYSV_FS) += sysv/
obj-$(CONFIG_CIFS) += cifs/
+obj-$(CONFIG_SMB_SERVER) += ksmbd/
obj-$(CONFIG_HPFS_FS) += hpfs/
obj-$(CONFIG_NTFS_FS) += ntfs/
obj-$(CONFIG_UFS_FS) += ufs/
diff --git a/fs/ksmbd/Kconfig b/fs/ksmbd/Kconfig
new file mode 100644
index 000000000000..e9a5ac01b6e0
--- /dev/null
+++ b/fs/ksmbd/Kconfig
@@ -0,0 +1,69 @@
+config SMB_SERVER
+ tristate "SMB3 server support (EXPERIMENTAL)"
+ depends on INET
+ depends on MULTIUSER
+ depends on FILE_LOCKING
+ select NLS
+ select NLS_UTF8
+ select CRYPTO
+ select CRYPTO_MD4
+ select CRYPTO_MD5
+ select CRYPTO_HMAC
+ select CRYPTO_ECB
+ select CRYPTO_LIB_DES
+ select CRYPTO_SHA256
+ select CRYPTO_CMAC
+ select CRYPTO_SHA512
+ select CRYPTO_AEAD2
+ select CRYPTO_CCM
+ select CRYPTO_GCM
+ select ASN1
+ select OID_REGISTRY
+ select FS_POSIX_ACL
+ default n
+ help
+ Choose Y here if you want to allow SMB3 compliant clients
+ to access files residing on this system using SMB3 protocol.
+ To compile the SMB3 server support as a module,
+ choose M here: the module will be called ksmbd.
+
+ You may choose to use a samba server instead, in which
+ case you can choose N here.
+
+ You also need to install user space programs which can be found
+ in ksmbd-tools, available from
+ https://github.com/cifsd-team/ksmbd-tools.
+ More detail about how to run the ksmbd kernel server is
+ available via README file
+ (https://github.com/cifsd-team/ksmbd-tools/blob/master/README).
+
+ ksmbd kernel server includes support for auto-negotiation,
+ Secure negotiate, Pre-authentication integrity, oplock/lease,
+ compound requests, multi-credit, packet signing, RDMA(smbdirect),
+ smb3 encryption, copy-offload, secure per-user session
+ establishment via NTLM or NTLMv2.
+
+config SMB_SERVER_SMBDIRECT
+ bool "Support for SMB Direct protocol"
+ depends on SMB_SERVER=m && INFINIBAND && INFINIBAND_ADDR_TRANS || SMB_SERVER=y && INFINIBAND=y && INFINIBAND_ADDR_TRANS=y
+ select SG_POOL
+ default n
+
+ help
+ Enables SMB Direct support for SMB 3.0, 3.02 and 3.1.1.
+
+ SMB Direct allows transferring SMB packets over RDMA. If unsure,
+ say N.
+
+config SMB_SERVER_CHECK_CAP_NET_ADMIN
+ bool "Enable check network administration capability"
+ depends on SMB_SERVER
+ default y
+
+ help
+ Prevent unprivileged processes to start the ksmbd kernel server.
+
+config SMB_SERVER_KERBEROS5
+ bool "Support for Kerberos 5"
+ depends on SMB_SERVER
+ default n
diff --git a/fs/ksmbd/Makefile b/fs/ksmbd/Makefile
new file mode 100644
index 000000000000..7d6337a7dee4
--- /dev/null
+++ b/fs/ksmbd/Makefile
@@ -0,0 +1,20 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+#
+# Makefile for Linux SMB3 kernel server
+#
+obj-$(CONFIG_SMB_SERVER) += ksmbd.o
+
+ksmbd-y := unicode.o auth.o vfs.o vfs_cache.o server.o ndr.o \
+ misc.o oplock.o connection.o ksmbd_work.o crypto_ctx.o \
+ mgmt/ksmbd_ida.o mgmt/user_config.o mgmt/share_config.o \
+ mgmt/tree_connect.o mgmt/user_session.o smb_common.o \
+ transport_tcp.o transport_ipc.o smbacl.o smb2pdu.o \
+ smb2ops.o smb2misc.o ksmbd_spnego_negtokeninit.asn1.o \
+ ksmbd_spnego_negtokentarg.asn1.o asn1.o
+
+$(obj)/asn1.o: $(obj)/ksmbd_spnego_negtokeninit.asn1.h $(obj)/ksmbd_spnego_negtokentarg.asn1.h
+
+$(obj)/ksmbd_spnego_negtokeninit.asn1.o: $(obj)/ksmbd_spnego_negtokeninit.asn1.c $(obj)/ksmbd_spnego_negtokeninit.asn1.h
+$(obj)/ksmbd_spnego_negtokentarg.asn1.o: $(obj)/ksmbd_spnego_negtokentarg.asn1.c $(obj)/ksmbd_spnego_negtokentarg.asn1.h
+
+ksmbd-$(CONFIG_SMB_SERVER_SMBDIRECT) += transport_rdma.o
--
2.17.1
next prev parent reply other threads:[~2021-07-16 0:04 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20210716000346epcas1p4fecf8bdde87dd76457b739fc3c1812a3@epcas1p4.samsung.com>
2021-07-15 23:53 ` [PATCH v6 00/13] ksmbd: introduce new SMB3 kernel server Namjae Jeon
[not found] ` <CGME20210716000347epcas1p49645cb64b0400b21eaf9e73e5267e211@epcas1p4.samsung.com>
2021-07-15 23:53 ` [PATCH v6 01/13] ksmbd: add document Namjae Jeon
[not found] ` <CGME20210716000348epcas1p4e6911b697bb4ebbc51880ff0cdd8bd04@epcas1p4.samsung.com>
2021-07-15 23:53 ` [PATCH v6 02/13] ksmbd: add server handler Namjae Jeon
[not found] ` <CGME20210716000349epcas1p1062a5e54cb3adda3c3ca23b933acffee@epcas1p1.samsung.com>
2021-07-15 23:53 ` [PATCH v6 03/13] ksmbd: add tcp transport layer Namjae Jeon
[not found] ` <CGME20210716000350epcas1p3d0153f945e30624b0cc2c09ad2269869@epcas1p3.samsung.com>
2021-07-15 23:53 ` [PATCH v6 04/13] ksmbd: add ipc " Namjae Jeon
[not found] ` <CGME20210716000350epcas1p22679615c2a4b63ea6d345849ee290542@epcas1p2.samsung.com>
2021-07-15 23:53 ` [PATCH v6 05/13] ksmbd: add rdma " Namjae Jeon
[not found] ` <CGME20210716000351epcas1p38834ce6505074c56308a6d71e762e09f@epcas1p3.samsung.com>
2021-07-15 23:53 ` [PATCH v6 06/13] ksmbd: add a utility code that tracks (and caches) sessions data Namjae Jeon
[not found] ` <CGME20210716000352epcas1p37f04458aea3e3025ae837745c3d90f54@epcas1p3.samsung.com>
2021-07-15 23:53 ` [PATCH v6 07/13] ksmbd: add authentication Namjae Jeon
[not found] ` <CGME20210716000355epcas1p1d47c355779f6dd3c0a6e5f9d2c9c094b@epcas1p1.samsung.com>
2021-07-15 23:53 ` [PATCH v6 10/13] ksmbd: add oplock/lease cache mechanism Namjae Jeon
[not found] ` <CGME20210716000356epcas1p3444a50440a5a0cfbc28f9ba935637bab@epcas1p3.samsung.com>
2021-07-15 23:53 ` [PATCH v6 11/13] ksmbd: add file operations Namjae Jeon
[not found] ` <CGME20210716000356epcas1p2ed40bdd5d7ed27393df9fa5fef97d47a@epcas1p2.samsung.com>
2021-07-15 23:53 ` Namjae Jeon [this message]
[not found] ` <CGME20210716000357epcas1p33ac820775b679f429872e936195a7fb1@epcas1p3.samsung.com>
2021-07-15 23:53 ` [PATCH v6 13/13] MAINTAINERS: add ksmbd kernel server Namjae Jeon
2021-07-16 8:35 ` [PATCH v6 00/13] ksmbd: introduce new SMB3 " Stefan Metzmacher
2021-07-16 12:34 ` [Linux-cifsd-devel] " Namjae Jeon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210715235356.3191-13-namjae.jeon@samsung.com \
--to=namjae.jeon@samsung.com \
--cc=aurelien.aptel@gmail.com \
--cc=christian@brauner.io \
--cc=dan.carpenter@oracle.com \
--cc=hch@infradead.org \
--cc=hch@lst.de \
--cc=hyc.lee@gmail.com \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-cifsd-devel@lists.sourceforge.net \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ronniesahlberg@gmail.com \
--cc=sandeen@sandeen.net \
--cc=senozhatsky@chromium.org \
--cc=smfrench@gmail.com \
--cc=stfrench@microsoft.com \
--cc=viro@zeniv.linux.org.uk \
--cc=willy@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).