0c6ea12145
Signed-off-by: Werner Lewis <werner.lewis@arm.com>
86 lines
3 KiB
Text
86 lines
3 KiB
Text
Test mbedtls_mpi_mod_setup #1 (Both representations invalid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_INVALID:MBEDTLS_MPI_MOD_REP_INVALID:MBEDTLS_ERR_MPI_BAD_INPUT_DATA
|
|
|
|
Test mbedtls_mpi_mod_setup #2 (Internal representation invalid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_LE:MBEDTLS_MPI_MOD_REP_INVALID:MBEDTLS_ERR_MPI_BAD_INPUT_DATA
|
|
|
|
Test mbedtls_mpi_mod_setup #3 (Internal representation invalid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_BE:MBEDTLS_MPI_MOD_REP_INVALID:MBEDTLS_ERR_MPI_BAD_INPUT_DATA
|
|
|
|
Test mbedtls_mpi_mod_setup #4 (External representation invalid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_INVALID:MBEDTLS_MPI_MOD_REP_MONTGOMERY:MBEDTLS_ERR_MPI_BAD_INPUT_DATA
|
|
|
|
Test mbedtls_mpi_mod_setup #5 (External representation invalid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_INVALID:MBEDTLS_MPI_MOD_REP_OPT_RED:MBEDTLS_ERR_MPI_BAD_INPUT_DATA
|
|
|
|
Test mbedtls_mpi_mod_setup #6 (Both representations valid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_BE:MBEDTLS_MPI_MOD_REP_OPT_RED:0
|
|
|
|
Test mbedtls_mpi_mod_setup #7 (Both representations valid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_BE:MBEDTLS_MPI_MOD_REP_MONTGOMERY:0
|
|
|
|
Test mbedtls_mpi_mod_setup #8 (Both representations valid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_LE:MBEDTLS_MPI_MOD_REP_OPT_RED:0
|
|
|
|
Test mbedtls_mpi_mod_setup #9 (Both representations valid)
|
|
mpi_mod_setup:MBEDTLS_MPI_MOD_EXT_REP_LE:MBEDTLS_MPI_MOD_REP_MONTGOMERY:0
|
|
|
|
Base test mbedtls_mpi_mod_mpi #1
|
|
mpi_mod_mpi:"3e8":"d":"c":0
|
|
|
|
Base test mbedtls_mpi_mod_mpi #2 (Divide by zero (null))
|
|
mpi_mod_mpi:"3e8":"":"0":MBEDTLS_ERR_MPI_DIVISION_BY_ZERO
|
|
|
|
Base test mbedtls_mpi_mod_mpi #2 (Divide by zero (1 limb))
|
|
mpi_mod_mpi:"3e8":"0":"0":MBEDTLS_ERR_MPI_DIVISION_BY_ZERO
|
|
|
|
Base test mbedtls_mpi_mod_mpi #3
|
|
mpi_mod_mpi:"-3e8":"d":"1":0
|
|
|
|
Base test mbedtls_mpi_mod_mpi #4 (Negative modulo)
|
|
mpi_mod_mpi:"3e8":"-d":"-1":MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|
|
|
|
Base test mbedtls_mpi_mod_mpi #5 (Negative modulo)
|
|
mpi_mod_mpi:"-3e8":"-d":"-c":MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|
|
|
|
Test mbedtls_mpi_mod_mpi: 0 (null) % 1
|
|
mpi_mod_mpi:"":"1":"":0
|
|
|
|
Test mbedtls_mpi_mod_mpi: 0 (null) % -1
|
|
mpi_mod_mpi:"":"-1":"":MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|
|
|
|
Base test mbedtls_mpi_mod_int #1
|
|
mpi_mod_int:"3e8":13:12:0
|
|
|
|
Base test mbedtls_mpi_mod_int #2 (Divide by zero)
|
|
mpi_mod_int:"3e8":0:0:MBEDTLS_ERR_MPI_DIVISION_BY_ZERO
|
|
|
|
Base test mbedtls_mpi_mod_int #3
|
|
mpi_mod_int:"-3e8":13:1:0
|
|
|
|
Base test mbedtls_mpi_mod_int #4 (Negative modulo)
|
|
mpi_mod_int:"3e8":-13:0:MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|
|
|
|
Base test mbedtls_mpi_mod_int #5 (Negative modulo)
|
|
mpi_mod_int:"-3e8":-13:0:MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|
|
|
|
Base test mbedtls_mpi_mod_int #6 (By 1)
|
|
mpi_mod_int:"3e8":1:0:0
|
|
|
|
Base test mbedtls_mpi_mod_int #7 (By 2)
|
|
mpi_mod_int:"3e9":2:1:0
|
|
|
|
Base test mbedtls_mpi_mod_int #8 (By 2)
|
|
mpi_mod_int:"3e8":2:0:0
|
|
|
|
Test mbedtls_mpi_mod_int: 0 (null) % 1
|
|
mpi_mod_int:"":1:0:0
|
|
|
|
Test mbedtls_mpi_mod_int: 0 (null) % 2
|
|
mpi_mod_int:"":2:0:0
|
|
|
|
Test mbedtls_mpi_mod_int: 0 (null) % -1
|
|
mpi_mod_int:"":-1:0:MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|
|
|
|
Test mbedtls_mpi_mod_int: 0 (null) % -2
|
|
mpi_mod_int:"":-2:0:MBEDTLS_ERR_MPI_NEGATIVE_VALUE
|