pub unsafe extern "C" fn ocrypto_rsa1024_init_key(
    pk: *mut ocrypto_rsa1024_key,
    n: *const u8,
    n_len: usize,
    d: *const u8,
    d_len: usize
) -> c_int
Expand description

1024-bit RSA secret key setup.

  • pk - The initialized public key.
  • n - The RSA modulus. Must be exactly 1024 bits.
  • n_len - Length of * n - .
  • d - The secret exponent. Must be <= 1024 bits.
  • d_len - Length of * d - .

Returns -1 If the input length is invalid. Returns 0 On success.