All of lore.kernel.org
 help / color / mirror / Atom feed
From: Martin Belanger <martin.nvme.dev@gmail.com>
To: Hannes Reinecke <hare@kernel.org>,
	Keith Busch <kbusch@kernel.org>, Jens Axboe <axboe@kernel.dk>,
	Christoph Hellwig <hch@lst.de>, Sagi Grimberg <sagi@grimberg.me>,
	Hannes Reinecke <hare@suse.de>,
	Chaitanya Kulkarni <kch@nvidia.com>
Cc: linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v5 0/9] nvme-auth: switch to use the kernel keyring
Date: Mon, 23 Nov 2026 07:59:56 -0500	[thread overview]
Message-ID: <5aa50b65-c502-4b87-8f09-23a456e2ca6a@gmail.com> (raw)
In-Reply-To: <20261123-dhchap-keyring-v4-v5-0-81eefb4c0724@kernel.org>



On 11/23/26 07:14, Hannes Reinecke wrote:
> With this I have updated the dhchap arguments to 'nvme connect' and
> the configfs interface to either be the keydata (ie the original
> interface) _or_ a key description referring to a pre-populated dhchap
> key in the kernel keyring.

Hi Hannes,

How should nvme-cli determine whether the kernel accepts a key
description for DH-HMAC-CHAP?

I will add DH-HMAC-CHAP support to nvme-keysd. It will import the
secrets into the .nvme keyring, the same way it imports TLS PSKs
today, and nvme-cli will pass the key description to 'nvme connect'.
On an older kernel, nvme-keysd must not import the secrets, and
nvme-cli must pass the key data instead. So both need to know what
the kernel supports.

I see these options:

1. Check the kernel version. This does not cover backports.

2. Use a separate option for the key description, for example
   dhchap_key=%s and dhchap_ctrl_key=%s. nvme-cli would then detect
   support through /dev/nvme-fabrics, as it does for the other
   options. It also avoids having one string that can mean either a
   description or key data.

3. Something else. add_key() fails with ENODEV when the 'dhchap' key
   type does not exist, but this does not show that the connect
   options accept a description.

What do you prefer?

Martin

  parent reply	other threads:[~2026-11-23 12:59 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-23 12:14 [PATCH v5 0/9] nvme-auth: switch to use the kernel keyring Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 1/9] nvme-auth: modify nvme_auth_transform_key() to return status Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 2/9] nvme-keyring: add 'dhchap' key type Hannes Reinecke
2026-11-23 12:36   ` sashiko-bot
2026-11-23 13:18     ` Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 3/9] nvme-auth: switch to use 'struct key' Hannes Reinecke
2026-11-23 12:35   ` sashiko-bot
2026-11-23 13:31     ` Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 4/9] nvme: parse dhchap keys during option parsing Hannes Reinecke
2026-11-23 12:34   ` sashiko-bot
2026-11-23 14:10     ` Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 5/9] nvmet-auth: parse dhchap key from configfs attribute Hannes Reinecke
2026-11-23 12:29   ` sashiko-bot
2026-11-23 15:03     ` Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 6/9] nvme: allow to pass in key description as dhchap secret Hannes Reinecke
2026-11-23 12:36   ` sashiko-bot
2026-11-23 15:25     ` Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 7/9] nvme-auth: wait for authentication to finish when changing keys Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 8/9] nvme-fabrics: allow to pass in keyring by name Hannes Reinecke
2026-11-23 12:29   ` sashiko-bot
2026-11-23 15:32     ` Hannes Reinecke
2026-11-23 12:14 ` [PATCH v5 9/9] nvmet: add configfs attribute 'dhchap_keyring' Hannes Reinecke
2026-11-23 12:35   ` sashiko-bot
2026-11-23 15:38     ` Hannes Reinecke
2026-11-23 12:59 ` Martin Belanger [this message]
2026-11-23 15:32   ` [PATCH v5 0/9] nvme-auth: switch to use the kernel keyring Martin Belanger
2026-11-23 15:41     ` Hannes Reinecke
2026-11-23 15:39   ` Hannes Reinecke

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=5aa50b65-c502-4b87-8f09-23a456e2ca6a@gmail.com \
    --to=martin.nvme.dev@gmail.com \
    --cc=axboe@kernel.dk \
    --cc=hare@kernel.org \
    --cc=hare@suse.de \
    --cc=hch@lst.de \
    --cc=kbusch@kernel.org \
    --cc=kch@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=sagi@grimberg.me \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.