From: Eric Biggers <ebiggers@kernel.org> To: linux-cifs@vger.kernel.org, Steve French <sfrench@samba.org> Cc: samba-technical@lists.samba.org, linux-crypto@vger.kernel.org Subject: Building cifs.ko without any support for insecure crypto? Date: Thu, 12 Aug 2021 20:23:44 -0700 [thread overview] Message-ID: <YRXlwDBfQql36wJx@sol.localdomain> (raw) Hi! We should be working to eliminate any uses of insecure crypto algorithms (e.g. DES, ARC4, MD4, MD5) from the kernel. In particular, it should be possible to build a kernel for a modern system without including any such algorithms. Currently, CONFIG_CIFS is problematic because it selects all these algorithms (kconfig options: CONFIG_CRYPTO_LIB_DES, CONFIG_CRYPTO_LIB_ARC4, CONFIG_CRYPTO_MD4, CONFIG_CRYPTO_MD5). It looks like these algorithms might only be used by SMB2.0 and earlier, and the more modern SMB versions don't use them. Is that the case? It mostly looks like that, but there's one case I'm not sure about -- there's a call chain which appears to use ARC4 and HMAC-MD5 even with the most recent SMB version: smb311_operations.sess_setup() SMB2_sess_setup() SMB2_sess_auth_rawntlmssp_authenticate() build_ntlmssp_auth_blob() setup_ntlmv2_rsp() Also, there's already an option CONFIG_CIFS_ALLOW_INSECURE_LEGACY=n which disables support for SMB2.0 and earlier. However, it doesn't actually compile out the code but rather just prevents it from being used. That means that the DES and ARC4 library interfaces are still depended on at link time, so they can't be omitted. Have there been any considerations towards making CONFIG_CIFS_ALLOW_INSECURE_LEGACY=n compile out the code for SMB2.0 and earlier? - Eric
next reply other threads:[~2021-08-13 3:23 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-08-13 3:23 Eric Biggers [this message] 2021-08-13 4:46 ` ronnie sahlberg 2021-08-13 20:19 ` Eric Biggers 2021-08-15 10:38 ` ronnie sahlberg 2021-08-16 22:19 ` Eric Biggers 2021-08-17 5:35 ` Steve French 2021-08-18 11:44 ` Ard Biesheuvel 2021-08-19 3:43 ` ronnie sahlberg 2021-08-19 3:53 ` Andrew Bartlett 2021-08-23 10:04 ` Simo Sorce 2021-08-24 16:41 ` Steve French
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=YRXlwDBfQql36wJx@sol.localdomain \ --to=ebiggers@kernel.org \ --cc=linux-cifs@vger.kernel.org \ --cc=linux-crypto@vger.kernel.org \ --cc=samba-technical@lists.samba.org \ --cc=sfrench@samba.org \ --subject='Re: Building cifs.ko without any support for insecure crypto?' \ /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
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).