1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-28 00:21:48 +03:00

Add a set of I/O functions for the modulus structure

Signed-off-by: Gabor Mezei <gabor.mezei@arm.com>
This commit is contained in:
Gabor Mezei
2022-07-18 23:13:13 +02:00
committed by Janos Follath
parent b903070cec
commit c5328cf9a6
3 changed files with 84 additions and 0 deletions

View File

@ -49,6 +49,16 @@ typedef struct {
} rep;
} mbedtls_mpi_mod_modulus;
typedef enum
{
MBEDTLS_MPI_MOD_REP_INVALID = 0,
MBEDTLS_MPI_MOD_REP_MONTGOMERY,
MBEDTLS_MPI_MOD_REP_OPT_RED
} mbedtls_mpi_mod_rep_selector;
#define MBEDTLS_MI_MOD_EXT_REP_LE 0x1
#define MBEDTLS_MI_MOD_EXT_REP_BE 0x2
void mbedtls_mpi_mod_residue_release( mbedtls_mpi_mod_residue *r );
int mbedtls_mpi_mod_residue_setup( mbedtls_mpi_mod_residue *r,