Latest update
This commit is contained in:
@@ -1488,7 +1488,7 @@ $code.=<<___;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// void ecp_nistz256_ord_sqr_mont(uint64_t res[4], uint64_t a[4],
|
||||
// int rep);
|
||||
// uint64_t rep);
|
||||
.globl ecp_nistz256_ord_sqr_mont
|
||||
.type ecp_nistz256_ord_sqr_mont,%function
|
||||
.align 4
|
||||
|
||||
@@ -1919,7 +1919,7 @@ $code.=<<___;
|
||||
|
||||
################################################################################
|
||||
# void ecp_nistz256_ord_sqr_mont(uint64_t res[4], uint64_t a[4],
|
||||
# int rep);
|
||||
# uint64_t rep);
|
||||
.globl ecp_nistz256_ord_sqr_mont
|
||||
.align 5
|
||||
ecp_nistz256_ord_sqr_mont:
|
||||
|
||||
@@ -826,7 +826,7 @@ $code.=<<___;
|
||||
# void ecp_nistz256_ord_sqr_mont(
|
||||
# uint64_t res[4],
|
||||
# uint64_t a[4],
|
||||
# int rep);
|
||||
# uint64_t rep);
|
||||
|
||||
.globl ecp_nistz256_ord_sqr_mont
|
||||
.type ecp_nistz256_ord_sqr_mont,\@function,3
|
||||
|
||||
+2
-2
@@ -441,7 +441,7 @@ int ec_wNAF_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
|
||||
* scalar multiplication implementation based on a Montgomery ladder,
|
||||
* with various timing attack defenses.
|
||||
*/
|
||||
if ((scalar != NULL) && (num == 0)) {
|
||||
if ((scalar != group->order) && (scalar != NULL) && (num == 0)) {
|
||||
/*-
|
||||
* In this case we want to compute scalar * GeneratorPoint: this
|
||||
* codepath is reached most prominently by (ephemeral) key
|
||||
@@ -452,7 +452,7 @@ int ec_wNAF_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
|
||||
*/
|
||||
return ec_scalar_mul_ladder(group, r, scalar, NULL, ctx);
|
||||
}
|
||||
if ((scalar == NULL) && (num == 1)) {
|
||||
if ((scalar == NULL) && (num == 1) && (scalars[0] != group->order)) {
|
||||
/*-
|
||||
* In this case we want to compute scalar * VariablePoint: this
|
||||
* codepath is reached most prominently by the second half of ECDH,
|
||||
|
||||
@@ -1467,7 +1467,7 @@ void ecp_nistz256_ord_mul_mont(BN_ULONG res[P256_LIMBS],
|
||||
const BN_ULONG b[P256_LIMBS]);
|
||||
void ecp_nistz256_ord_sqr_mont(BN_ULONG res[P256_LIMBS],
|
||||
const BN_ULONG a[P256_LIMBS],
|
||||
int rep);
|
||||
BN_ULONG rep);
|
||||
|
||||
static int ecp_nistz256_inv_mod_ord(const EC_GROUP *group, BIGNUM *r,
|
||||
const BIGNUM *x, BN_CTX *ctx)
|
||||
|
||||
Reference in New Issue
Block a user