mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Justin M. Forbes" <jforbes@fedoraproject.org>
To: Herbert Xu <herbert@gondor.apana.org.au>,
	"David S. Miller" <davem@davemloft.net>,
	linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: "Justin M. Forbes" <jforbes@fedoraproject.org>
Subject: [PATCH] Allow hmac(sha512) for unpriviledged users
Date: Sat,  3 Oct 2026 10:03:02 -0600	[thread overview]
Message-ID: <20261003160302.3000325-1-jforbes@fedoraproject.org> (raw)

By default users cannot run sha512hmac with the current set up. This
is problematic because our kernel builds call this for FIPS compliance.
Rather than have anyone turn off af_alg_restrict all together, let's
allow a common use case.

Signed-off-by: Justin M. Forbes <jforbes@fedoraproject.org>
---
 crypto/algif_hash.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/crypto/algif_hash.c b/crypto/algif_hash.c
index 6e8b5fb82a7f..0d3ec5760de6 100644
--- a/crypto/algif_hash.c
+++ b/crypto/algif_hash.c
@@ -23,7 +23,7 @@ static const struct af_alg_allowlist_entry hash_allowlist[] = {
 	{ "hmac(sha224)" }, /* iwd */
 	{ "hmac(sha256)" }, /* iwd */
 	{ "hmac(sha384)" }, /* iwd */
-	{ "hmac(sha512)" }, /* iwd, sha512hmac */
+	{ "hmac(sha512)", AF_ALG_UNPRIVILEGED }, /* iwd, sha512hmac */
 	{ "md4" }, /* iwd */
 	{ "md5" }, /* iwd */
 	{ "sha1", AF_ALG_UNPRIVILEGED }, /* iwd, iproute2 < 7.0 */
-- 
2.55.0


             reply	other threads:[~2026-10-03 16:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-03 16:03 Justin M. Forbes [this message]
2026-10-03 16:18 ` Eric Biggers
2026-10-03 17:05   ` Justin Forbes
2026-10-03 17:37     ` Eric Biggers
2026-10-03 17:43       ` Justin Forbes

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=20261003160302.3000325-1-jforbes@fedoraproject.org \
    --to=jforbes@fedoraproject.org \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®