LIBNVMF_GENERATE_TLS_KEY_IDENTITY_COMPAT-LIBNVME3(2)

πŸ“¦ version 3.2, in arch rolling

πŸŽ€ NAME πŸŽ€

okay so bestie, meet libnvmf_generate_tls_key_identity_compat from the libnvme API manual β€” it's the one that generates the TLS PSK identity. literally what it says on the tin πŸ’…


✨ SYNOPSIS ✨

int libnvmf_generate_tls_key_identity_compat (struct libnvme_global_ctx
*ctx , const char *hostnqn , const char *subsysnqn , int version , enum
libnvmf_hmac_alg hmac , unsigned char *configured_key , int key_len ,
char **identity );

🫢 ARGUMENTS 🫢

  • ctx β€” a struct libnvme_global_ctx object, aka the global context bestie 🫢
  • hostnqn β€” Host NVMe Qualified Name ✨
  • subsysnqn β€” Subsystem NVMe Qualified Name 🌸
  • version β€” TLS PSK identity version to use πŸ‘‘
  • hmac β€” HMAC algorithm πŸ”₯
  • configured_key β€” Configured PSK to derive the retained PSK from πŸŽ€
  • key_len β€” Length of configured_key πŸ¦‹
  • identity β€” TLS PSK identity to return πŸ’–

πŸ¦‹ DESCRIPTION πŸ¦‹

so basically it derives a retained PSK as specified in the NVMe TCP Transport Specification 1.3, section 3.6.1.3, and generates the corresponding TLS PSK identity. no cap ✨

this one is the compat girlie, and it differs from libnvmf_generate_tls_key_identity in that it uses the original implementation for HKDF-Expand-Label which does not prefix the 'info' and 'label' strings with the length. iykyk πŸ’…

it's giving β€œyou own this memory now” πŸ’€ β€” it is the responsibility of the caller to free the returned string.

πŸ’– RETURN πŸ’–

  • 0 on success, negative error code otherwise. periodt 🌈

mwah πŸ’‹ β€” that's the tea from the libnvme API manual, October 2026, libnvmf_generate_tls_key_identity_compat(9). bestie, you got this 🫢✨

πŸ“¦ where this page comes from