/openssl/crypto/ec/ |
H A D | ecp_s390x_nistp.c | 50 const BIGNUM *scalars[], in ec_GFp_s390x_nistp_mul() argument 81 || (scalar == NULL && num == 1 && BN_is_negative(scalars[0]) == 0)) { in ec_GFp_s390x_nistp_mul() 88 scalar_ptr = scalars[0]; in ec_GFp_s390x_nistp_mul() 118 rc = ossl_ec_wNAF_mul(group, r, scalar, num, points, scalars, ctx); in ec_GFp_s390x_nistp_mul() 291 const BIGNUM *scalars[], \ 295 scalars, ctx, \
|
H A D | ec_local.h | 136 size_t num, const EC_POINT *points[], const BIGNUM *scalars[], 358 const BIGNUM *scalars[], BN_CTX *); 530 const EC_POINT *points[], const BIGNUM *scalars[], 535 const BIGNUM *scalars[], BN_CTX *ctx); 550 const EC_POINT *points[], const BIGNUM *scalars[], 555 const BIGNUM *scalars[], BN_CTX *ctx); 570 const EC_POINT *points[], const BIGNUM *scalars[], 575 const BIGNUM *scalars[], BN_CTX *ctx); 591 const EC_POINT *points[], const BIGNUM *scalars[], 596 const BIGNUM *scalars[], BN_CTX *ctx);
|
H A D | ecp_sm2p256.c | 512 const BIGNUM **scalars = NULL; in ecp_sm2p256_windowed_mul() local 521 || (scalars = OPENSSL_malloc(num * sizeof(BIGNUM *))) == NULL) { in ecp_sm2p256_windowed_mul() 541 scalars[i] = tmp; in ecp_sm2p256_windowed_mul() 543 scalars[i] = scalar[i]; in ecp_sm2p256_windowed_mul() 546 if (ecp_sm2p256_bignum_field_elem(k, scalars[i]) <= 0 in ecp_sm2p256_windowed_mul() 561 OPENSSL_free(scalars); in ecp_sm2p256_windowed_mul() 571 const BIGNUM *scalars[], BN_CTX *ctx) in ecp_sm2p256_points_mul() argument 626 if (!ecp_sm2p256_windowed_mul(group, out, scalars, points, num, ctx)) in ecp_sm2p256_points_mul()
|
H A D | ecp_nistz256.c | 621 const BIGNUM **scalars = NULL; in ecp_nistz256_windowed_mul() local 630 || (scalars = OPENSSL_malloc(num * sizeof(BIGNUM *))) == NULL) in ecp_nistz256_windowed_mul() 649 scalars[i] = mod; in ecp_nistz256_windowed_mul() 651 scalars[i] = scalar[i]; in ecp_nistz256_windowed_mul() 653 for (j = 0; j < bn_get_top(scalars[i]) * BN_BYTES; j += BN_BYTES) { in ecp_nistz256_windowed_mul() 654 BN_ULONG d = bn_get_words(scalars[i])[j / BN_BYTES]; in ecp_nistz256_windowed_mul() 774 OPENSSL_free(scalars); in ecp_nistz256_windowed_mul() 944 const BIGNUM *scalars[], BN_CTX *ctx) in ecp_nistz256_points_mul() argument 1120 memcpy(new_scalars, scalars, num * sizeof(BIGNUM *)); in ecp_nistz256_points_mul() 1125 scalars = new_scalars; in ecp_nistz256_points_mul() [all …]
|
H A D | ecp_nistp224.c | 1139 const felem_bytearray scalars[], in batch_mul() argument 1201 bits = get_bit(scalars[num], i + 4) << 5; in batch_mul() 1202 bits |= get_bit(scalars[num], i + 3) << 4; in batch_mul() 1203 bits |= get_bit(scalars[num], i + 2) << 3; in batch_mul() 1204 bits |= get_bit(scalars[num], i + 1) << 2; in batch_mul() 1205 bits |= get_bit(scalars[num], i) << 1; in batch_mul() 1206 bits |= get_bit(scalars[num], i - 1); in batch_mul() 1408 const BIGNUM *scalars[], BN_CTX *ctx) in ossl_ec_GFp_nistp224_points_mul() argument 1499 p_scalar = scalars[i]; in ossl_ec_GFp_nistp224_points_mul()
|
H A D | ec_mult.c | 406 const BIGNUM *scalars[], BN_CTX *ctx) in ossl_ec_wNAF_mul() argument 449 if ((scalar == NULL) && (num == 1) && (scalars[0] != group->order)) { in ossl_ec_wNAF_mul() 457 return ossl_ec_scalar_mul_ladder(group, r, scalars[0], points[0], in ossl_ec_wNAF_mul() 528 bits = i < num ? BN_num_bits(scalars[i]) : BN_num_bits(scalar); in ossl_ec_wNAF_mul() 533 bn_compute_wNAF((i < num ? scalars[i] : scalar), wsize[i], in ossl_ec_wNAF_mul()
|
H A D | ecp_nistp384.c | 1374 const felem_bytearray scalars[], in batch_mul() argument 1425 bits = get_bit(scalars[num], i + 4) << 5; in batch_mul() 1426 bits |= get_bit(scalars[num], i + 3) << 4; in batch_mul() 1427 bits |= get_bit(scalars[num], i + 2) << 3; in batch_mul() 1428 bits |= get_bit(scalars[num], i + 1) << 2; in batch_mul() 1429 bits |= get_bit(scalars[num], i) << 1; in batch_mul() 1430 bits |= get_bit(scalars[num], i - 1); in batch_mul() 1702 const BIGNUM *scalars[], BN_CTX *ctx) in ossl_ec_GFp_nistp384_points_mul() argument 1796 p_scalar = scalars[i]; in ossl_ec_GFp_nistp384_points_mul()
|
H A D | ecp_nistp521.c | 1582 const felem_bytearray scalars[], in batch_mul() argument 1632 bits = get_bit(scalars[num], i + 4) << 5; in batch_mul() 1633 bits |= get_bit(scalars[num], i + 3) << 4; in batch_mul() 1634 bits |= get_bit(scalars[num], i + 2) << 3; in batch_mul() 1635 bits |= get_bit(scalars[num], i + 1) << 2; in batch_mul() 1636 bits |= get_bit(scalars[num], i) << 1; in batch_mul() 1637 bits |= get_bit(scalars[num], i - 1); in batch_mul() 1911 const BIGNUM *scalars[], BN_CTX *ctx) in ossl_ec_GFp_nistp521_points_mul() argument 2005 p_scalar = scalars[i]; in ossl_ec_GFp_nistp521_points_mul()
|
H A D | ecp_nistp256.c | 1675 const felem_bytearray scalars[], in batch_mul() argument 1739 bits = get_bit(scalars[num], i + 4) << 5; in batch_mul() 1740 bits |= get_bit(scalars[num], i + 3) << 4; in batch_mul() 1741 bits |= get_bit(scalars[num], i + 2) << 3; in batch_mul() 1742 bits |= get_bit(scalars[num], i + 1) << 2; in batch_mul() 1743 bits |= get_bit(scalars[num], i) << 1; in batch_mul() 1744 bits |= get_bit(scalars[num], i - 1); in batch_mul() 2021 const BIGNUM *scalars[], BN_CTX *ctx) in ossl_ec_GFp_nistp256_points_mul() argument 2117 p_scalar = scalars[i]; in ossl_ec_GFp_nistp256_points_mul()
|
H A D | ec2_smpl.c | 871 const BIGNUM *scalars[], in ec_GF2m_simple_points_mul() argument 892 return ossl_ec_wNAF_mul(group, r, scalar, num, points, scalars, ctx); in ec_GF2m_simple_points_mul() 900 return ossl_ec_scalar_mul_ladder(group, r, scalars[0], points[0], ctx); in ec_GF2m_simple_points_mul() 913 || !ossl_ec_scalar_mul_ladder(group, r, scalars[0], points[0], ctx) in ec_GF2m_simple_points_mul()
|
H A D | ec_lib.c | 1072 const BIGNUM *scalars[], BN_CTX *ctx) in EC_POINTs_mul() argument 1105 ret = group->meth->mul(group, r, scalar, num, points, scalars, ctx); in EC_POINTs_mul() 1108 ret = ossl_ec_wNAF_mul(group, r, scalar, num, points, scalars, ctx); in EC_POINTs_mul()
|
/openssl/test/ |
H A D | ectest.c | 117 scalars[0] = scalars[1] = BN_value_one(); in group_order_tests() 125 scalars[0] = n1; in group_order_tests() 127 scalars[1] = n2; in group_order_tests() 129 scalars[2] = n1; in group_order_tests() 131 scalars[3] = n2; in group_order_tests() 133 scalars[4] = n1; in group_order_tests() 135 scalars[5] = n2; in group_order_tests() 555 scalars[1] = y; in prime_field_tests() 566 scalars[0] = y; in prime_field_tests() 575 scalars[0] = x; in prime_field_tests() [all …]
|
/openssl/ |
H A D | CHANGES.md | 4147 in OpenSSL are mostly used with secret scalars in keygen, sign, 11781 * Fix crypto/ec/ec_mult.c to work properly with scalars of value 0 14713 \sum scalars[i]*points[i], 14715 scalar*generator + \sum scalars[i]*points[i].
|