53 lines
1.5 KiB
C
53 lines
1.5 KiB
C
/****************************************************************************
|
|
|
|
Copyright(c) 2019 by Aerospace C.Power (Chongqing) Microelectronics. ALL RIGHTS RESERVED.
|
|
|
|
This Information is proprietary to Aerospace C.Power (Chongqing) Microelectronics and MAY NOT
|
|
be copied by any method or incorporated into another program without
|
|
the express written consent of Aerospace C.Power. This Information or any portion
|
|
thereof remains the property of Aerospace C.Power. The Information contained herein
|
|
is believed to be accurate and Aerospace C.Power assumes no responsibility or
|
|
liability for its use in any way and conveys no license or title under
|
|
any patent or copyright and makes no representation or warranty that this
|
|
Information is free from patent or copyright infringement.
|
|
|
|
****************************************************************************/
|
|
#ifndef BIGNUM_PATCH_ALT_H
|
|
#define BIGNUM_PATCH_ALT_H
|
|
|
|
#if !defined(MBEDTLS_CONFIG_FILE)
|
|
#include "mbedtls/config.h"
|
|
#else
|
|
#include MBEDTLS_CONFIG_FILE
|
|
#endif
|
|
|
|
#include "os_types.h"
|
|
|
|
#if defined(MBEDTLS_BIGNUM_C)
|
|
#include "mbedtls/bignum.h"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
int patch_mpi_mul_mpi(mbedtls_mpi *X, const mbedtls_mpi *A,
|
|
const mbedtls_mpi *B);
|
|
|
|
int patch_mpi_mod_mpi(mbedtls_mpi *R, const mbedtls_mpi *A,
|
|
const mbedtls_mpi *B);
|
|
|
|
int patch_mpi_montmul(mbedtls_mpi *A, const mbedtls_mpi *B,
|
|
const mbedtls_mpi *N, mbedtls_mpi_uint mm,
|
|
const mbedtls_mpi *T);
|
|
|
|
void patch_bignum_mpi_init(void);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* MBEDTLS_BIGNUM_C */
|
|
|
|
#endif /* BIGNUM_PATCH_ALT_H */
|
|
|