nvme_insert...ey_versioned(2)

πŸ’– nvme_insert_tls_key_versioned β€” libnvme API manual, bestie edition πŸ’–

okay so picture this: you're deep in the libnvme API manual (hi, that's the manual this page lives in 🫢) and you need a TLS key derived and inserted like it's nothing. That's this function. She does the math, she drops the key in the keyring, she leaves. Iconic behaviour, no cap. ✨


🌸 NAME 🌸

nvme_insert_tls_key_versioned β€” derive and insert a TLS key, bestie πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

long nvme_insert_tls_key_versioned (const char *keyring , const char
*key_type , const char *hostnqn , const char *subsysnqn , int version ,
int hmac , unsigned char *configured_key , int key_len );

πŸŽ€ ARGUMENTS πŸŽ€

  • keyring β€” the keyring we're using, like the lil handbag we keep our keys in πŸ’œ
  • key_type β€” the type of the resulting key (what kind of key we're manifesting ✨)
  • hostnqn β€” the Host NVMe Qualified Name
  • subsysnqn β€” the Subsystem NVMe Qualified Name
  • version β€” which key version we're using
  • hmac β€” the HMAC algorithm (the secret sauce for the derivation 🌈)
  • configured_key β€” the configured key data that we derive the key from
  • key_len β€” the length of configured_key. she has measurements, periodt πŸ“

✨ DESCRIPTION ✨

So what does she actually DO? She derives a 'retained' TLS key πŸ’– β€” as specified in NVMe TCP 1.0a if version is set to '0', or as specified in NVMe TP8028 if version is set to '1' β€” and then stores it, as type key_type, in the keyring you specified with keyring.

that's it. that's the whole gig. derive, insert, slay. 🧚


πŸ’… RETURN πŸ’…

  • the key serial number if the key could be inserted into the keyring πŸ‘‘
  • or 0 with errno otherwise 😭
fr fr, check that errno β€” a 0 with no follow-up is giving cryptic ex energy and we do not have time for that πŸ™ˆ

and that's the whole page bestie!! mwah πŸ’‹ β€” this one comes to you from the libnvme API manual, dated July 2026. go insert some keys, you've got this πŸŒŸπŸŽ€πŸ¦‹

πŸ“¦ where this page comes from