diff options
Diffstat (limited to 'src/include/openssl/bn.h')
-rw-r--r-- | src/include/openssl/bn.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/include/openssl/bn.h b/src/include/openssl/bn.h index 46673dc..01115c8 100644 --- a/src/include/openssl/bn.h +++ b/src/include/openssl/bn.h @@ -532,7 +532,7 @@ OPENSSL_EXPORT int BN_mod_sub_quick(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, OPENSSL_EXPORT int BN_mod_mul(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, const BIGNUM *m, BN_CTX *ctx); -/* BN_mod_mul sets |r| = |a|^2 mod |m|. It returns one on success and zero +/* BN_mod_sqr sets |r| = |a|^2 mod |m|. It returns one on success and zero * on error. */ OPENSSL_EXPORT int BN_mod_sqr(BIGNUM *r, const BIGNUM *a, const BIGNUM *m, BN_CTX *ctx); @@ -737,7 +737,7 @@ OPENSSL_EXPORT void BN_MONT_CTX_free(BN_MONT_CTX *mont); /* BN_MONT_CTX_copy sets |to| equal to |from|. It returns |to| on success or * NULL on error. */ OPENSSL_EXPORT BN_MONT_CTX *BN_MONT_CTX_copy(BN_MONT_CTX *to, - BN_MONT_CTX *from); + const BN_MONT_CTX *from); /* BN_MONT_CTX_set sets up a Montgomery context given the modulus, |mod|. It * returns one on success and zero on error. */ @@ -787,19 +787,20 @@ OPENSSL_EXPORT int BN_mod_exp(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, OPENSSL_EXPORT int BN_mod_exp_mont(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, const BIGNUM *m, BN_CTX *ctx, - BN_MONT_CTX *m_ctx); + const BN_MONT_CTX *mont); OPENSSL_EXPORT int BN_mod_exp_mont_consttime(BIGNUM *rr, const BIGNUM *a, const BIGNUM *p, const BIGNUM *m, - BN_CTX *ctx, BN_MONT_CTX *in_mont); + BN_CTX *ctx, + const BN_MONT_CTX *mont); OPENSSL_EXPORT int BN_mod_exp_mont_word(BIGNUM *r, BN_ULONG a, const BIGNUM *p, const BIGNUM *m, BN_CTX *ctx, - BN_MONT_CTX *m_ctx); + const BN_MONT_CTX *mont); OPENSSL_EXPORT int BN_mod_exp2_mont(BIGNUM *r, const BIGNUM *a1, const BIGNUM *p1, const BIGNUM *a2, const BIGNUM *p2, const BIGNUM *m, - BN_CTX *ctx, BN_MONT_CTX *m_ctx); + BN_CTX *ctx, const BN_MONT_CTX *mont); /* Deprecated functions */ @@ -812,7 +813,7 @@ OPENSSL_EXPORT int BN_mod_exp2_mont(BIGNUM *r, const BIGNUM *a1, * find the needed amount of space, call the function with |out| set to NULL. */ OPENSSL_EXPORT size_t BN_bn2mpi(const BIGNUM *in, uint8_t *out); -/* BN_bin2bn parses |len| bytes from |in| and returns the resulting value. The +/* BN_mpi2bn parses |len| bytes from |in| and returns the resulting value. The * bytes at |in| are expected to be in the format emitted by |BN_bn2mpi|. * * If |out| is NULL then a fresh |BIGNUM| is allocated and returned, otherwise |