public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Milan Broz <gmazyland@gmail.com>
To: Eric Biggers <ebiggers@kernel.org>,
	cryptsetup development <cryptsetup@lists.linux.dev>
Cc: linux-crypto@vger.kernel.org, dm-devel@lists.linux.dev,
	linux-kernel@vger.kernel.org,
	Demi Marie Obenour <demiobenour@gmail.com>
Subject: Re: AF_ALG algorithms required by cryptsetup
Date: Mon, 4 May 2026 08:08:10 +0200	[thread overview]
Message-ID: <5dd3be22-13fb-41fb-b469-1ae6472200b1@gmail.com> (raw)
In-Reply-To: <20260504052400.GB2289@sol>

On 5/4/26 7:24 AM, Eric Biggers wrote:
> Hi Milan,
> 
> AF_ALG is going to have to go away eventually, due to its frequent
> vulnerabilities which vastly outweigh its benefits.  Userspace crypto
> code can be, should be, and generally already is used instead.

Heh, I just send reply to the thread on security list. I know about this.
(It is probably waiting for moderation, cannot find link to paste here yet.)

In general, it is more complicated and need some time, but it can be done.

> Is a reasonably definitive list of the algorithms cryptsetup needs from
> AF_ALG available anywhere, so that an allowlist can be implemented on
> the kernel side?

For Veracrypt support, it would be easy to create list.
But maybe we can do it differently completely without AF_ALG.

> (It would need to be unioned with what iwd uses as well.)
> 
> Also, what are the biggest blockers to removing the AF_ALG dependency
> from cryptsetup, in your view?
> 
> Finally, how well would a CAP_SYS_ADMIN or CAP_NET_ADMIN restriction
> work for cryptsetup?  IIUC, volume formatting and opening require root
> anyway, and all the device-mapper ioctls already require CAP_SYS_ADMIN.
> I know 'cryptsetup benchmark' would be affected, but that tends to be a
> one-off manually-run thing, which people could add 'sudo' to.

Formatting does not require root, basically only device-mapper interaction
requires it now.

LUKS should be completely OK without AF_ALG (it calls userspace backend),
it is about other formats.

I'll reply later.

Milan


      reply	other threads:[~2026-05-04  6:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-04  5:24 AF_ALG algorithms required by cryptsetup Eric Biggers
2026-05-04  6:08 ` Milan Broz [this message]

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=5dd3be22-13fb-41fb-b469-1ae6472200b1@gmail.com \
    --to=gmazyland@gmail.com \
    --cc=cryptsetup@lists.linux.dev \
    --cc=demiobenour@gmail.com \
    --cc=dm-devel@lists.linux.dev \
    --cc=ebiggers@kernel.org \
    --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