nrfxlib API 0.1.0
|
int ocrypto_rsa_init_key | ( | ocrypto_rsa_key * | key, |
uint32_t * | key_mem, | ||
const uint8_t * | n, | ||
size_t | n_len, | ||
const uint8_t * | d, | ||
size_t | d_len | ||
) |
#include <crypto/nrf_oberon/include/ocrypto_rsa_primitives.h>
RSA secret key setup.
[out] | key | The initialized secret key. |
[out] | key_mem | Key memory. Length OCRYPTO_RSA_KEY_SIZE(bits). Must have same lifetime as key . |
n | The RSA modulus, unsigned big-endian. | |
n_len | Length of n . | |
d | The secret exponent, unsigned big-endian. | |
d_len | Length of d . Must be <= n_len . |
-1 | If the input length is invalid. |
0 | On success. |