summaryrefslogtreecommitdiff
path: root/deps/openssl/openssl/crypto/ec/ec_lcl.h
diff options
context:
space:
mode:
authorShigeki Ohtsu <ohtsu@iij.ad.jp>2015-03-30 14:41:01 +0900
committerShigeki Ohtsu <ohtsu@iij.ad.jp>2015-04-15 00:36:13 +0900
commite4872d7405c60da50692e3c4cd5a9df2e96a5680 (patch)
tree2ccc49f465ec7364702c99f6aa190c8c60de16ef /deps/openssl/openssl/crypto/ec/ec_lcl.h
parent50e9fc197d57ecd7b3c23ae85d66b59fedf4ea82 (diff)
downloadandroid-node-v8-e4872d7405c60da50692e3c4cd5a9df2e96a5680.tar.gz
android-node-v8-e4872d7405c60da50692e3c4cd5a9df2e96a5680.tar.bz2
android-node-v8-e4872d7405c60da50692e3c4cd5a9df2e96a5680.zip
deps: upgrade openssl to 1.0.2a
This just replaces all sources in deps/openssl/openssl to originals in https://www.openssl.org/source/openssl-1.0.2a.tar.gz Fixes: https://github.com/iojs/io.js/issues/589 PR-URL: https://github.com/iojs/io.js/pull/1389 Reviewed-By: Fedor Indutny <fedor@indutny.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Diffstat (limited to 'deps/openssl/openssl/crypto/ec/ec_lcl.h')
-rw-r--r--deps/openssl/openssl/crypto/ec/ec_lcl.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/deps/openssl/openssl/crypto/ec/ec_lcl.h b/deps/openssl/openssl/crypto/ec/ec_lcl.h
index 319e651f67..697eeb528c 100644
--- a/deps/openssl/openssl/crypto/ec/ec_lcl.h
+++ b/deps/openssl/openssl/crypto/ec/ec_lcl.h
@@ -212,6 +212,13 @@ struct ec_group_st {
BIGNUM order, cofactor;
int curve_name; /* optional NID for named curve */
int asn1_flag; /* flag to control the asn1 encoding */
+ /*
+ * Kludge: upper bit of ans1_flag is used to denote structure
+ * version. Is set, then last field is present. This is done
+ * for interoperation with FIPS code.
+ */
+#define EC_GROUP_ASN1_FLAG_MASK 0x7fffffff
+#define EC_GROUP_VERSION(p) (p->asn1_flag&~EC_GROUP_ASN1_FLAG_MASK)
point_conversion_form_t asn1_form;
unsigned char *seed; /* optional seed for parameters (appears in
* ASN1) */
@@ -252,6 +259,7 @@ struct ec_group_st {
/* method-specific */
int (*field_mod_func) (BIGNUM *, const BIGNUM *, const BIGNUM *,
BN_CTX *);
+ BN_MONT_CTX *mont_data; /* data for ECDSA inverse */
} /* EC_GROUP */ ;
struct ec_key_st {
@@ -549,3 +557,20 @@ void ec_GFp_nistp_points_make_affine_internal(size_t num, void *point_array,
void ec_GFp_nistp_recode_scalar_bits(unsigned char *sign,
unsigned char *digit, unsigned char in);
#endif
+int ec_precompute_mont_data(EC_GROUP *);
+
+#ifdef ECP_NISTZ256_ASM
+/** Returns GFp methods using montgomery multiplication, with x86-64 optimized
+ * P256. See http://eprint.iacr.org/2013/816.
+ * \return EC_METHOD object
+ */
+const EC_METHOD *EC_GFp_nistz256_method(void);
+#endif
+
+#ifdef OPENSSL_FIPS
+EC_GROUP *FIPS_ec_group_new_curve_gfp(const BIGNUM *p, const BIGNUM *a,
+ const BIGNUM *b, BN_CTX *ctx);
+EC_GROUP *FIPS_ec_group_new_curve_gf2m(const BIGNUM *p, const BIGNUM *a,
+ const BIGNUM *b, BN_CTX *ctx);
+EC_GROUP *FIPS_ec_group_new_by_curve_name(int nid);
+#endif