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

◆ modem_key_mgmt_cmp()

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

#include <include/modem/modem_key_mgmt.h>

Compare a credential with a credential in persistent storage.

Parameters
[in]sec_tagThe security tag of the credential.
[in]cred_typeThe credential type.
[in]bufBuffer to compare the credential to.
[in]lenLength of the buffer.
Return values
0If the credentials match.
1If the credentials do not match.
-ENOBUFSInternal buffer is too small.
-ENOENTNo credential associated with the given sec_tag and cred_type.
-EACCESAccess to credential not allowed.