nRF Connect SDK API 3.3.99
Loading...
Searching...
No Matches

◆ modem_key_mgmt_digest()

int modem_key_mgmt_digest ( nrf_sec_tag_t sec_tag,
enum modem_key_mgmt_cred_type cred_type,
void * buf,
size_t len )

#include <include/modem/modem_key_mgmt.h>

Read the SHA-256 digest of a credential from persistent storage.

Parameters
[in]sec_tagThe security tag of the credential.
[in]cred_typeThe credential type.
[out]bufBuffer to read the credential into.
[in]lenLength of the buffer.
Return values
0On success.
-ENOMEMCredential does not fit in buf. See MODEM_KEY_MGMT_DIGEST_SIZE
-ENOENTNo credential associated with the given sec_tag and cred_type.