diff options
author | Mark O'Donovan <shiftee@posteo.net> | 2023-10-17 17:09:18 +0000 |
---|---|---|
committer | Keith Busch <kbusch@kernel.org> | 2023-10-17 13:57:54 -0700 |
commit | f047daed179a451657d1e66b5fe4030a593a000c (patch) | |
tree | 26d657ccd67c81069b2b9d9a8755b9d64c862bcb /include/linux/nvme-auth.h | |
parent | nvme-auth: alloc nvme_dhchap_key as single buffer (diff) | |
download | linux-f047daed179a451657d1e66b5fe4030a593a000c.tar.gz linux-f047daed179a451657d1e66b5fe4030a593a000c.tar.bz2 linux-f047daed179a451657d1e66b5fe4030a593a000c.zip |
nvme-auth: use transformed key size to create resp
This does not change current behaviour as the driver currently
verifies that the secret size is the same size as the length of
the transformation hash.
Co-developed-by: Akash Appaiah <Akash.Appaiah@dell.com>
Signed-off-by: Akash Appaiah <Akash.Appaiah@dell.com>
Signed-off-by: Mark O'Donovan <shiftee@posteo.net>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Keith Busch <kbusch@kernel.org>
Diffstat (limited to 'include/linux/nvme-auth.h')
-rw-r--r-- | include/linux/nvme-auth.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/nvme-auth.h b/include/linux/nvme-auth.h index a5ae9abe1ef6..c1d0bc5d9624 100644 --- a/include/linux/nvme-auth.h +++ b/include/linux/nvme-auth.h @@ -29,7 +29,8 @@ struct nvme_dhchap_key *nvme_auth_extract_key(unsigned char *secret, u8 key_hash); void nvme_auth_free_key(struct nvme_dhchap_key *key); struct nvme_dhchap_key *nvme_auth_alloc_key(u32 len, u8 hash); -u8 *nvme_auth_transform_key(struct nvme_dhchap_key *key, char *nqn); +struct nvme_dhchap_key *nvme_auth_transform_key( + struct nvme_dhchap_key *key, char *nqn); int nvme_auth_generate_key(u8 *secret, struct nvme_dhchap_key **ret_key); int nvme_auth_augmented_challenge(u8 hmac_id, u8 *skey, size_t skey_len, u8 *challenge, u8 *aug, size_t hlen); |