1
0
Fork 0

Merging upstream version 1.11.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-16 10:51:10 +01:00
parent fc25ba7fb2
commit bdf865565e
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
946 changed files with 4896 additions and 1272 deletions

View file

@ -760,6 +760,37 @@ on error. It is the responsibility of the caller to free the returned
string.
.. c:function:: char * nvme_export_tls_key_versioned (unsigned char version, unsigned char hmac, const unsigned char *key_data, size_t key_len)
Export a TLS pre-shared key
**Parameters**
``unsigned char version``
Indicated the representation of the TLS PSK
``unsigned char hmac``
HMAC algorithm used to transfor the configured PSK
in a retained PSK
``const unsigned char *key_data``
Raw data of the key
``size_t key_len``
Length of **key_data**
**Description**
Returns **key_data** in the PSK Interchange format as defined in section
3.6.1.5 of the NVMe TCP Transport specification.
**Return**
The string containing the TLS identity or NULL with errno set
on error. It is the responsibility of the caller to free the returned
string.
.. c:function:: unsigned char * nvme_import_tls_key (const char *encoded_key, int *key_len, unsigned int *hmac)
Import a TLS key
@ -786,6 +817,36 @@ The raw data of the PSK or NULL with errno set on error. It is
the responsibility of the caller to free the returned string.
.. c:function:: unsigned char * nvme_import_tls_key_versioned (const char *encoded_key, unsigned char *version, unsigned char *hmac, size_t *key_len)
Import a TLS key
**Parameters**
``const char *encoded_key``
TLS key in PSK interchange format
``unsigned char *version``
Indicated the representation of the TLS PSK
``unsigned char *hmac``
HMAC algorithm used to transfor the configured
PSK in a retained PSK
``size_t *key_len``
Length of the resulting key data
**Description**
Imports **key_data** in the PSK Interchange format as defined in section
3.6.1.5 of the NVMe TCP Transport specification.
**Return**
The raw data of the PSK or NULL with errno set on error. It is
the responsibility of the caller to free the returned string.
.. c:function:: int nvme_submit_passthru (int fd, unsigned long ioctl_cmd, struct nvme_passthru_cmd *cmd, __u32 *result)
Low level ioctl wrapper for passthru commands