![]() |
ndn-lite
|
#include "key-storage.h"
Functions | |
ndn_key_storage_t * | ndn_key_storage_init (void) |
Init an in-library key storage structure. More... | |
ndn_key_storage_t * | ndn_key_storage_get_instance (void) |
Get a running instance of key storage structure. More... | |
int | ndn_key_storage_set_anchor (const ndn_data_t *trust_anchor) |
Set trust anchor for the key storage structure. More... | |
void | ndn_key_storage_get_empty_hmac_key (ndn_hmac_key_t **hmac) |
Get an empty HMAC key pointer from key storage structure. More... | |
void | ndn_key_storage_get_empty_ecc_key (ndn_ecc_pub_t **pub, ndn_ecc_prv_t **prv) |
Get an empty ECC key pointer from key storage structure. More... | |
void | ndn_key_storage_get_empty_aes_key (ndn_aes_key_t **aes) |
Get an empty AES-128 key pointer from key storage structure. More... | |
void | ndn_key_storage_delete_hmac_key (uint32_t key_id) |
Delete a HMAC key by searching corresponding unique key id. More... | |
void | ndn_key_storage_delete_ecc_key (uint32_t key_id) |
Delete a ECC key by searching corresponding unique key id. More... | |
void | ndn_key_storage_delete_aes_key (uint32_t key_id) |
Delete a AES-128 key by searching corresponding unique key id. More... | |
void | ndn_key_storage_get_hmac_key (uint32_t key_id, ndn_hmac_key_t **hmac) |
Get an empty HMAC key pointer from key storage structure. More... | |
void | ndn_key_storage_get_ecc_key (uint32_t key_id, ndn_ecc_pub_t **pub, ndn_ecc_prv_t **prv) |
Get an empty ECC key pointer from key storage structure. More... | |
void | ndn_key_storage_get_aes_key (uint32_t key_id, ndn_aes_key_t **aes) |
Get an empty AES-128 key pointer from key storage structure. More... | |
Variables | |
static ndn_key_storage_t | storage |
void ndn_key_storage_delete_aes_key | ( | uint32_t | key_id | ) |
Delete a AES-128 key by searching corresponding unique key id.
key_id. | Input. Key id of the key to delete. |
void ndn_key_storage_delete_ecc_key | ( | uint32_t | key_id | ) |
Delete a ECC key by searching corresponding unique key id.
key_id. | Input. Key id of the key to delete. |
void ndn_key_storage_delete_hmac_key | ( | uint32_t | key_id | ) |
Delete a HMAC key by searching corresponding unique key id.
key_id. | Input. Key id of the key to delete. |
void ndn_key_storage_get_aes_key | ( | uint32_t | key_id, |
ndn_aes_key_t ** | aes | ||
) |
Get an empty AES-128 key pointer from key storage structure.
key_id. | Input. Key id which indicates the key to fetch. |
hmac. | Output. Pass NULL pointers into the function to get output AES-128 key pointers. |
void ndn_key_storage_get_ecc_key | ( | uint32_t | key_id, |
ndn_ecc_pub_t ** | pub, | ||
ndn_ecc_prv_t ** | prv | ||
) |
Get an empty ECC key pointer from key storage structure.
key_id. | Input. Key id which indicates the key to fetch. |
hmac. | Output. Pass NULL pointers into the function to get output ECC key pointers. |
void ndn_key_storage_get_empty_aes_key | ( | ndn_aes_key_t ** | aes | ) |
Get an empty AES-128 key pointer from key storage structure.
aes. | Output. Pass NULL pointers into the function to get empty ECC key pointers. |
void ndn_key_storage_get_empty_ecc_key | ( | ndn_ecc_pub_t ** | pub, |
ndn_ecc_prv_t ** | prv | ||
) |
Get an empty ECC key pointer from key storage structure.
pub. | Output. Pass NULL pointers into the function to get empty ECC key pointers. |
prv. | Output. Pass NULL pointers into the function to get empty ECC key pointers. |
void ndn_key_storage_get_empty_hmac_key | ( | ndn_hmac_key_t ** | hmac | ) |
Get an empty HMAC key pointer from key storage structure.
hmac. | Output. Pass NULL pointers into the function to get empty HMAC key pointers. |
void ndn_key_storage_get_hmac_key | ( | uint32_t | key_id, |
ndn_hmac_key_t ** | hmac | ||
) |
Get an empty HMAC key pointer from key storage structure.
key_id. | Input. Key id which indicates the key to fetch. |
hmac. | Output. Pass NULL pointers into the function to get output hmac key pointers. |
ndn_key_storage_t* ndn_key_storage_get_instance | ( | void | ) |
Get a running instance of key storage structure.
ndn_key_storage_t* ndn_key_storage_init | ( | void | ) |
Init an in-library key storage structure.
int ndn_key_storage_set_anchor | ( | const ndn_data_t * | trust_anchor | ) |
Set trust anchor for the key storage structure.
trust_anchor. | Input. Trust anchor to configure the key storage structure. |
|
static |