carta
libnvmf_read_key-libnvme3(2)

libnvmf_read_key-libnvme32

Read key raw data

Usage

int libnvmf_read_key (struct libnvme_global_ctx *ctx , long keyring_id , long key_id , int *len , unsigned char **key );

Arguments

ctx

struct libnvme_global_ctx object

keyring_id

Id of the keyring holding key_id

key_id

Key id

len

Length of key to return

key

Raw key data to return

Overview

Links the keyring specified by keyring_id into the session keyring and reads the payload of the key specified by key_id. len holds the size of the returned buffer. If keyring_id is 0 the default keyring '.nvme' is used.

Return

0 on success, negative error code otherwise.

From nvme-cli 3.2-1 in Arch Linux 2026-11-01. Parsed by carta from the page's man source.