mirror of
https://github.com/guanzhi/GmSSL.git
synced 2026-05-07 17:06:25 +08:00
Update SM2 methods
The default `./config` will enable the X86_64 ASM implementation of SM2. Use `./config -DGMSSL_NO_TURBO enable-ec_nistp_64_gcc_128` will enable the fast C implementation of SM2. The `./config -DGMSSL_NO_TURBO` will use the original implementation.
This commit is contained in:
@@ -455,12 +455,18 @@ int BN_nist_mod_224(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx);
|
||||
int BN_nist_mod_256(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx);
|
||||
int BN_nist_mod_384(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx);
|
||||
int BN_nist_mod_521(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx);
|
||||
# ifndef OPENSSL_NO_SM2
|
||||
int BN_sm2_mod_256(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx);
|
||||
# endif
|
||||
|
||||
const BIGNUM *BN_get0_nist_prime_192(void);
|
||||
const BIGNUM *BN_get0_nist_prime_224(void);
|
||||
const BIGNUM *BN_get0_nist_prime_256(void);
|
||||
const BIGNUM *BN_get0_nist_prime_384(void);
|
||||
const BIGNUM *BN_get0_nist_prime_521(void);
|
||||
# ifndef OPENSSL_NO_SM2
|
||||
const BIGNUM *BN_get0_sm2_prime_256(void);
|
||||
# endif
|
||||
|
||||
int (*BN_nist_mod_func(const BIGNUM *p)) (BIGNUM *r, const BIGNUM *a,
|
||||
const BIGNUM *field, BN_CTX *ctx);
|
||||
|
||||
@@ -41,9 +41,9 @@ extern "C" {
|
||||
*/
|
||||
# define OPENSSL_VERSION_NUMBER 0x1010004fL
|
||||
# ifdef OPENSSL_FIPS
|
||||
# define OPENSSL_VERSION_TEXT "GmSSL 2.4.3 - OpenSSL 1.1.0d-fips 23 Jan 2019"
|
||||
# define OPENSSL_VERSION_TEXT "GmSSL 2.4.4 - OpenSSL 1.1.0d-fips 26 Jan 2019"
|
||||
# else
|
||||
# define OPENSSL_VERSION_TEXT "GmSSL 2.4.3 - OpenSSL 1.1.0d 23 Jan 2019"
|
||||
# define OPENSSL_VERSION_TEXT "GmSSL 2.4.4 - OpenSSL 1.1.0d 26 Jan 2019"
|
||||
# endif
|
||||
|
||||
/*-
|
||||
|
||||
Reference in New Issue
Block a user