mbedtls icon indicating copy to clipboard operation
mbedtls copied to clipboard

Bignum: add random generation for the new MPI types

Open yanesca opened this issue 2 years ago • 0 comments

Add the following functions to bignum_core and bignum_mod_raw:

  • _random(): same as mbedtls_mpi_random() just for the new types
  • _fill_random(): same as mbedtls_mpi_fill_random() just for the new types

The random bytes are converted to a number in a very particular way, following standards. This behaviour should be kept.

The _core functions should be reused by the legacy functions as usual.

yanesca avatar Aug 25 '22 11:08 yanesca