Latest update.
This commit is contained in:
+12
-20
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
* Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
@@ -37,22 +37,19 @@
|
||||
*/
|
||||
|
||||
#include <openssl/opensslconf.h>
|
||||
#ifdef OPENSSL_NO_EC_NISTP_64_GCC_128
|
||||
NON_EMPTY_TRANSLATION_UNIT
|
||||
#else
|
||||
|
||||
# include <stdint.h>
|
||||
# include <string.h>
|
||||
# include <openssl/err.h>
|
||||
# include "ec_local.h"
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
#include <openssl/err.h>
|
||||
#include "ec_local.h"
|
||||
|
||||
# if defined(__SIZEOF_INT128__) && __SIZEOF_INT128__==16
|
||||
#if defined(__SIZEOF_INT128__) && __SIZEOF_INT128__==16
|
||||
/* even with gcc, the typedef won't work for 32-bit platforms */
|
||||
typedef __uint128_t uint128_t; /* nonstandard; implemented by gcc on 64-bit
|
||||
* platforms */
|
||||
# else
|
||||
# error "Your compiler doesn't appear to support 128-bit integer types"
|
||||
# endif
|
||||
#else
|
||||
# error "Your compiler doesn't appear to support 128-bit integer types"
|
||||
#endif
|
||||
|
||||
typedef uint8_t u8;
|
||||
typedef uint64_t u64;
|
||||
@@ -264,8 +261,6 @@ const EC_METHOD *EC_GFp_nistp224_method(void)
|
||||
ec_GFp_simple_point_clear_finish,
|
||||
ec_GFp_simple_point_copy,
|
||||
ec_GFp_simple_point_set_to_infinity,
|
||||
ec_GFp_simple_set_Jprojective_coordinates_GFp,
|
||||
ec_GFp_simple_get_Jprojective_coordinates_GFp,
|
||||
ec_GFp_simple_point_set_affine_coordinates,
|
||||
ec_GFp_nistp224_point_get_affine_coordinates,
|
||||
0 /* point_set_compressed_coordinates */ ,
|
||||
@@ -1468,9 +1463,8 @@ int ec_GFp_nistp224_points_mul(const EC_GROUP *group, EC_POINT *r,
|
||||
ECerr(EC_F_EC_GFP_NISTP224_POINTS_MUL, ERR_R_BN_LIB);
|
||||
goto err;
|
||||
}
|
||||
if (!EC_POINT_set_Jprojective_coordinates_GFp(group,
|
||||
generator, x, y, z,
|
||||
ctx))
|
||||
if (!ec_GFp_simple_set_Jprojective_coordinates_GFp(group, generator, x,
|
||||
y, z, ctx))
|
||||
goto err;
|
||||
if (0 == EC_POINT_cmp(group, generator, group->generator, ctx))
|
||||
/* precomputation matches generator */
|
||||
@@ -1604,7 +1598,7 @@ int ec_GFp_nistp224_points_mul(const EC_GROUP *group, EC_POINT *r,
|
||||
ECerr(EC_F_EC_GFP_NISTP224_POINTS_MUL, ERR_R_BN_LIB);
|
||||
goto err;
|
||||
}
|
||||
ret = EC_POINT_set_Jprojective_coordinates_GFp(group, r, x, y, z, ctx);
|
||||
ret = ec_GFp_simple_set_Jprojective_coordinates_GFp(group, r, x, y, z, ctx);
|
||||
|
||||
err:
|
||||
BN_CTX_end(ctx);
|
||||
@@ -1755,5 +1749,3 @@ int ec_GFp_nistp224_have_precompute_mult(const EC_GROUP *group)
|
||||
{
|
||||
return HAVEPRECOMP(group, nistp224);
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user