Skip to contentSkip to conversation

nvme in-band authentication blktests - nvme/043

PATCH [email protected] 3 participants 3 messages Jun 29, 2023 – Jul 3, 2023 NVMe

lore
Share & tools
lore
#0 lore raw

I'm playing around with in-band authentication and using blktests to see how to setup it up and use it.  In test nvme/043, a valid hostkey is never initialized and a NULL is being used to setup the target and to connect.  Is this expected?  The test with the NULL hostkey passes.  I updated the test to use a valid key and it also passes.

tests/nvme/043 +0 -0
index a030884..d5e0d4b 100755
@@ -40,6 +40,8 @@ test() {

        fi hostnqn="nqn.2014-08.org.nvmexpress:uuid:${hostid}"

+       hostkey="$(nvme gen-dhchap-key -n ${subsys_name} 2> /dev/null)" +
        _setup_nvmet

        truncate -s "${nvme_img_size}" "${file_path}"

Alan Adamson

#1 lore raw

CC+: Hannes,

Quoted 15 lines · On Jun 29, 2023 / 12:24, [email protected] wrote:

I'm playing around with in-band authentication and using blktests to see how to setup it up and use it.  In test nvme/043, a valid hostkey is never initialized and a NULL is being used to setup the target and to connect.  Is this expected?  The test with the NULL hostkey passes.  I updated the test to use a valid key and it also passes.

tests/nvme/043 +0 -0
index a030884..d5e0d4b 100755
@@ -40,6 +40,8 @@ test() {

        fi hostnqn="nqn.2014-08.org.nvmexpress:uuid:${hostid}"

Quoted 6 lines

+       hostkey="$(nvme gen-dhchap-key -n ${subsys_name} 2> /dev/null)" +
        _setup_nvmet

        truncate -s "${nvme_img_size}" "${file_path}"

Alan's question looks valid for me.

Hannes, may I ask your comment?

Reviewed-by
#2 lore raw
Quoted 22 lines · Shinichiro Kawasaki

CC+: Hannes,

Quoted 19 lines · On Jun 29, 2023 / 12:24, [email protected] wrote:

I'm playing around with in-band authentication and using blktests to see how to setup it up and use it.  In test nvme/043, a valid hostkey is never initialized and a NULL is being used to setup the target and to connect.  Is this expected?  The test with the NULL hostkey passes.  I updated the test to use a valid key and it also passes.

tests/nvme/043 +2 -0
index a030884..d5e0d4b 100755
@@ -40,6 +40,8 @@ test() {
         fi
         hostnqn="nqn.2014-08.org.nvmexpress:uuid:${hostid}"
 
+       hostkey="$(nvme gen-dhchap-key -n ${subsys_name} 2> /dev/null)"
+
         _setup_nvmet
 
Quoted 6 lines

tests/nvme/043 test() { · line 47

Quoted 2 lines
tests/nvme/043 +0 -0
         truncate -s "${nvme_img_size}" "${file_path}"

Alan's question looks valid for me.

Hannes, may I ask your comment?

Yeah, that's correct.

Cheers,

Hannes