From: sashiko-bot@kernel.org
Cc: linux-security-module@vger.kernel.org
Subject: Re: [RFC PATCH 1/9] KEYS: keycrypt: Add a key type for keys user space never reads
Date: Wed, 18 Nov 2026 14:33:10 +0000 [thread overview]
Message-ID: <sashiko-outbox-221218@kernel.org> (raw)
In-Reply-To: <20261118140421.584086-2-giometti@enneenne.com>
> Programs that encrypt, decrypt or authenticate data with a symmetric
> key today hold that key: in a file, in a "user" or "logon" key handed
> to AF_ALG, or in memory a compromised process can read. On a device
> with a TEE or a crypto engine able to keep keys, nothing lets an
> ordinary program use such a key through a kernel interface, with the
> key fixed to one algorithm and purpose and never released.
>
> Add the "keycrypt" key type. A key is created by a backend ("new"),
> sealed from a key given in clear by CAP_SYS_ADMIN ("import", behind
> CONFIG_KEYCRYPT_IMPORT), or re-created from the blob its backend
> sealed ("load"); its algorithm (aes256-cbc, hmac-sha256), purpose and
> protection tier (kernel, tee, hsm) are fixed at creation and
> authenticated in the blob. User space reads only the blob.
>
> This adds a user API: KEYCTL_CRYPT_OPEN opens an operation context on
> a key, a file descriptor whose ioctls run the operation in the key's
> backend, as the documentation describes. Two system policies come as
> sysctls and boot parameters, both one-way: the system tier, a floor on
> the use of keys whose starting value is chosen at build time
> (CONFIG_KEYCRYPT_SYSTEM_TIER_*), and an import switch.
>
> Backends register through keycrypt_register_backend(); none is added
> here, so a well-formed add_key() fails with ENODEV until one is.
>
> Signed-off-by: Rodolfo Giometti <giometti@enneenne.com>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261118140421.584086-1-giometti@enneenne.com?part=1
next prev parent reply other threads:[~2026-11-18 14:33 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-18 14:04 [RFC PATCH 0/9] KEYS: keycrypt: keys that user space can use but never read Rodolfo Giometti
2026-11-18 14:04 ` [RFC PATCH 1/9] KEYS: keycrypt: Add a key type for keys user space never reads Rodolfo Giometti
2026-11-18 14:33 ` sashiko-bot [this message]
2026-11-18 14:04 ` [RFC PATCH 2/9] KEYS: keycrypt: Add the sw backend Rodolfo Giometti
2026-11-18 14:21 ` sashiko-bot
2026-11-18 14:04 ` [RFC PATCH 3/9] KEYS: keycrypt: Add the OP-TEE backend Rodolfo Giometti
2026-11-18 14:33 ` sashiko-bot
2026-11-18 14:07 ` [RFC PATCH 4/9] docs: keycrypt: document keycrypt keys Rodolfo Giometti
2026-11-18 14:19 ` sashiko-bot
2026-11-18 14:08 ` [RFC PATCH 5/9] MAINTAINERS: add KEYS-KEYCRYPT Rodolfo Giometti
2026-11-18 14:09 ` [RFC PATCH 6/9] KEYS: keycrypt: Add the engine tier Rodolfo Giometti
2026-11-18 14:17 ` sashiko-bot
2026-11-18 14:10 ` [RFC PATCH 7/9] crypto: caam - add an internal cbc(paes) taking the blob's key modifier Rodolfo Giometti
2026-11-18 14:24 ` sashiko-bot
2026-11-18 14:11 ` [RFC PATCH 8/9] KEYS: keycrypt: Add the CAAM backend Rodolfo Giometti
2026-11-18 14:36 ` sashiko-bot
2026-11-18 14:12 ` [RFC PATCH 9/9] KEYS: keycrypt: Add the aes256-gcm-stream algorithm Rodolfo Giometti
2026-11-18 14:30 ` sashiko-bot
2026-11-18 14:31 ` [RFC PATCH 0/9] KEYS: keycrypt: keys that user space can use but never read Jarkko Sakkinen
2026-11-18 14:39 ` Jarkko Sakkinen
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=sashiko-outbox-221218@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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