sync
This commit is contained in:
parent
2a351e0cdc
commit
f57be82572
704 changed files with 20524 additions and 10572 deletions
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_ameth.c,v 1.40 2023/07/03 09:25:44 tb Exp $ */
|
||||
/* $OpenBSD: ec_ameth.c,v 1.41 2023/07/07 06:59:18 tb Exp $ */
|
||||
/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
|
||||
* project 2006.
|
||||
*/
|
||||
|
@ -427,9 +427,7 @@ int_ec_free(EVP_PKEY *pkey)
|
|||
static int
|
||||
do_EC_KEY_print(BIO *bp, const EC_KEY *x, int off, int ktype)
|
||||
{
|
||||
unsigned char *buffer = NULL;
|
||||
const char *ecstr;
|
||||
size_t buf_len = 0, i;
|
||||
int ret = 0, reason = ERR_R_BIO_LIB;
|
||||
BIGNUM *pub_key = NULL;
|
||||
BN_CTX *ctx = NULL;
|
||||
|
@ -454,24 +452,13 @@ do_EC_KEY_print(BIO *bp, const EC_KEY *x, int off, int ktype)
|
|||
reason = ERR_R_EC_LIB;
|
||||
goto err;
|
||||
}
|
||||
if (pub_key)
|
||||
buf_len = (size_t) BN_num_bytes(pub_key);
|
||||
}
|
||||
}
|
||||
if (ktype == 2) {
|
||||
priv_key = EC_KEY_get0_private_key(x);
|
||||
if (priv_key && (i = (size_t) BN_num_bytes(priv_key)) > buf_len)
|
||||
buf_len = i;
|
||||
} else
|
||||
priv_key = NULL;
|
||||
|
||||
if (ktype > 0) {
|
||||
buf_len += 10;
|
||||
if ((buffer = malloc(buf_len)) == NULL) {
|
||||
reason = ERR_R_MALLOC_FAILURE;
|
||||
goto err;
|
||||
}
|
||||
}
|
||||
if (ktype == 2)
|
||||
ecstr = "Private-Key";
|
||||
else if (ktype == 1)
|
||||
|
@ -485,19 +472,21 @@ do_EC_KEY_print(BIO *bp, const EC_KEY *x, int off, int ktype)
|
|||
EC_GROUP_order_bits(group)) <= 0)
|
||||
goto err;
|
||||
|
||||
if (!ASN1_bn_print(bp, "priv:", priv_key, buffer, off))
|
||||
if (!bn_printf(bp, priv_key, off, "priv:"))
|
||||
goto err;
|
||||
if (!ASN1_bn_print(bp, "pub: ", pub_key, buffer, off))
|
||||
if (!bn_printf(bp, pub_key, off, "pub: "))
|
||||
goto err;
|
||||
if (!ECPKParameters_print(bp, group, off))
|
||||
goto err;
|
||||
|
||||
ret = 1;
|
||||
|
||||
err:
|
||||
if (!ret)
|
||||
ECerror(reason);
|
||||
BN_free(pub_key);
|
||||
BN_CTX_free(ctx);
|
||||
free(buffer);
|
||||
|
||||
return (ret);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_asn1.c,v 1.46 2023/06/27 07:28:57 tb Exp $ */
|
||||
/* $OpenBSD: ec_asn1.c,v 1.48 2023/07/07 19:37:53 beck Exp $ */
|
||||
/*
|
||||
* Written by Nils Larsch for the OpenSSL project.
|
||||
*/
|
||||
|
@ -72,6 +72,7 @@ EC_GROUP_get_basis_type(const EC_GROUP *group)
|
|||
{
|
||||
return 0;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_basis_type);
|
||||
|
||||
/* some structures needed for the asn1 encoding */
|
||||
typedef struct x9_62_pentanomial_st {
|
||||
|
@ -1101,6 +1102,7 @@ d2i_ECPKParameters(EC_GROUP **a, const unsigned char **in, long len)
|
|||
ECPKPARAMETERS_free(params);
|
||||
return (group);
|
||||
}
|
||||
LCRYPTO_ALIAS(d2i_ECPKParameters);
|
||||
|
||||
int
|
||||
i2d_ECPKParameters(const EC_GROUP *a, unsigned char **out)
|
||||
|
@ -1119,6 +1121,7 @@ i2d_ECPKParameters(const EC_GROUP *a, unsigned char **out)
|
|||
ECPKPARAMETERS_free(tmp);
|
||||
return (ret);
|
||||
}
|
||||
LCRYPTO_ALIAS(i2d_ECPKParameters);
|
||||
|
||||
/* some EC_KEY functions */
|
||||
|
||||
|
@ -1213,6 +1216,7 @@ d2i_ECPrivateKey(EC_KEY **a, const unsigned char **in, long len)
|
|||
|
||||
return (NULL);
|
||||
}
|
||||
LCRYPTO_ALIAS(d2i_ECPrivateKey);
|
||||
|
||||
int
|
||||
i2d_ECPrivateKey(EC_KEY *a, unsigned char **out)
|
||||
|
@ -1297,6 +1301,7 @@ i2d_ECPrivateKey(EC_KEY *a, unsigned char **out)
|
|||
EC_PRIVATEKEY_free(priv_key);
|
||||
return (ok ? ret : 0);
|
||||
}
|
||||
LCRYPTO_ALIAS(i2d_ECPrivateKey);
|
||||
|
||||
int
|
||||
i2d_ECParameters(EC_KEY *a, unsigned char **out)
|
||||
|
@ -1307,6 +1312,7 @@ i2d_ECParameters(EC_KEY *a, unsigned char **out)
|
|||
}
|
||||
return i2d_ECPKParameters(a->group, out);
|
||||
}
|
||||
LCRYPTO_ALIAS(i2d_ECParameters);
|
||||
|
||||
EC_KEY *
|
||||
d2i_ECParameters(EC_KEY **a, const unsigned char **in, long len)
|
||||
|
@ -1336,6 +1342,7 @@ d2i_ECParameters(EC_KEY **a, const unsigned char **in, long len)
|
|||
*a = ret;
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(d2i_ECParameters);
|
||||
|
||||
EC_KEY *
|
||||
o2i_ECPublicKey(EC_KEY **a, const unsigned char **in, long len)
|
||||
|
@ -1362,6 +1369,7 @@ o2i_ECPublicKey(EC_KEY **a, const unsigned char **in, long len)
|
|||
*in += len;
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(o2i_ECPublicKey);
|
||||
|
||||
int
|
||||
i2o_ECPublicKey(const EC_KEY *a, unsigned char **out)
|
||||
|
@ -1400,3 +1408,4 @@ i2o_ECPublicKey(const EC_KEY *a, unsigned char **out)
|
|||
*out += buf_len;
|
||||
return buf_len;
|
||||
}
|
||||
LCRYPTO_ALIAS(i2o_ECPublicKey);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_check.c,v 1.14 2023/07/03 09:29:55 tb Exp $ */
|
||||
/* $OpenBSD: ec_check.c,v 1.15 2023/07/07 13:54:45 beck Exp $ */
|
||||
/* ====================================================================
|
||||
* Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved.
|
||||
*
|
||||
|
@ -109,3 +109,4 @@ EC_GROUP_check(const EC_GROUP *group, BN_CTX *ctx_in)
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_check);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_curve.c,v 1.41 2023/05/02 13:01:57 tb Exp $ */
|
||||
/* $OpenBSD: ec_curve.c,v 1.42 2023/07/07 13:54:45 beck Exp $ */
|
||||
/*
|
||||
* Written by Nils Larsch for the OpenSSL project.
|
||||
*/
|
||||
|
@ -3122,6 +3122,7 @@ EC_GROUP_new_by_curve_name(int nid)
|
|||
ECerror(EC_R_UNKNOWN_GROUP);
|
||||
return NULL;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_new_by_curve_name);
|
||||
|
||||
size_t
|
||||
EC_get_builtin_curves(EC_builtin_curve *r, size_t nitems)
|
||||
|
@ -3140,6 +3141,7 @@ EC_get_builtin_curves(EC_builtin_curve *r, size_t nitems)
|
|||
|
||||
return CURVE_LIST_LENGTH;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_get_builtin_curves);
|
||||
|
||||
static const struct {
|
||||
const char *name;
|
||||
|
@ -3174,6 +3176,7 @@ EC_curve_nid2nist(int nid)
|
|||
|
||||
return NULL;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_curve_nid2nist);
|
||||
|
||||
int
|
||||
EC_curve_nist2nid(const char *name)
|
||||
|
@ -3187,3 +3190,4 @@ EC_curve_nist2nid(const char *name)
|
|||
|
||||
return NID_undef;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_curve_nist2nid);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_cvt.c,v 1.11 2023/04/25 19:53:30 tb Exp $ */
|
||||
/* $OpenBSD: ec_cvt.c,v 1.12 2023/07/07 13:54:45 beck Exp $ */
|
||||
/*
|
||||
* Originally written by Bodo Moeller for the OpenSSL project.
|
||||
*/
|
||||
|
@ -100,3 +100,4 @@ EC_GROUP_new_curve_GFp(const BIGNUM *p, const BIGNUM *a, const BIGNUM *b,
|
|||
{
|
||||
return ec_group_new_curve(EC_GFp_mont_method(), p, a, b, ctx);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_new_curve_GFp);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_err.c,v 1.16 2023/07/05 17:10:10 tb Exp $ */
|
||||
/* $OpenBSD: ec_err.c,v 1.17 2023/07/07 13:54:45 beck Exp $ */
|
||||
/* ====================================================================
|
||||
* Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved.
|
||||
*
|
||||
|
@ -147,3 +147,4 @@ ERR_load_EC_strings(void)
|
|||
}
|
||||
#endif
|
||||
}
|
||||
LCRYPTO_ALIAS(ERR_load_EC_strings);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_key.c,v 1.35 2023/07/05 08:39:40 tb Exp $ */
|
||||
/* $OpenBSD: ec_key.c,v 1.36 2023/07/07 13:54:45 beck Exp $ */
|
||||
/*
|
||||
* Written by Nils Larsch for the OpenSSL project.
|
||||
*/
|
||||
|
@ -78,6 +78,7 @@ EC_KEY_new(void)
|
|||
{
|
||||
return EC_KEY_new_method(NULL);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_new);
|
||||
|
||||
EC_KEY *
|
||||
EC_KEY_new_by_curve_name(int nid)
|
||||
|
@ -97,6 +98,7 @@ EC_KEY_new_by_curve_name(int nid)
|
|||
}
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_new_by_curve_name);
|
||||
|
||||
void
|
||||
EC_KEY_free(EC_KEY *r)
|
||||
|
@ -124,6 +126,7 @@ EC_KEY_free(EC_KEY *r)
|
|||
|
||||
freezero(r, sizeof(EC_KEY));
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_free);
|
||||
|
||||
EC_KEY *
|
||||
EC_KEY_copy(EC_KEY *dest, const EC_KEY *src)
|
||||
|
@ -197,6 +200,7 @@ EC_KEY_copy(EC_KEY *dest, const EC_KEY *src)
|
|||
|
||||
return dest;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_copy);
|
||||
|
||||
EC_KEY *
|
||||
EC_KEY_dup(const EC_KEY *ec_key)
|
||||
|
@ -211,6 +215,7 @@ EC_KEY_dup(const EC_KEY *ec_key)
|
|||
}
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_dup);
|
||||
|
||||
int
|
||||
EC_KEY_up_ref(EC_KEY *r)
|
||||
|
@ -218,18 +223,21 @@ EC_KEY_up_ref(EC_KEY *r)
|
|||
int i = CRYPTO_add(&r->references, 1, CRYPTO_LOCK_EC);
|
||||
return ((i > 1) ? 1 : 0);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_up_ref);
|
||||
|
||||
int
|
||||
EC_KEY_set_ex_data(EC_KEY *r, int idx, void *arg)
|
||||
{
|
||||
return CRYPTO_set_ex_data(&r->ex_data, idx, arg);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_ex_data);
|
||||
|
||||
void *
|
||||
EC_KEY_get_ex_data(const EC_KEY *r, int idx)
|
||||
{
|
||||
return CRYPTO_get_ex_data(&r->ex_data, idx);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get_ex_data);
|
||||
|
||||
int
|
||||
EC_KEY_generate_key(EC_KEY *eckey)
|
||||
|
@ -239,6 +247,7 @@ EC_KEY_generate_key(EC_KEY *eckey)
|
|||
ECerror(EC_R_NOT_IMPLEMENTED);
|
||||
return 0;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_generate_key);
|
||||
|
||||
int
|
||||
ec_key_gen(EC_KEY *eckey)
|
||||
|
@ -355,6 +364,7 @@ EC_KEY_check_key(const EC_KEY *eckey)
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_check_key);
|
||||
|
||||
int
|
||||
EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y)
|
||||
|
@ -409,12 +419,14 @@ EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y)
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_public_key_affine_coordinates);
|
||||
|
||||
const EC_GROUP *
|
||||
EC_KEY_get0_group(const EC_KEY *key)
|
||||
{
|
||||
return key->group;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get0_group);
|
||||
|
||||
int
|
||||
EC_KEY_set_group(EC_KEY *key, const EC_GROUP *group)
|
||||
|
@ -426,12 +438,14 @@ EC_KEY_set_group(EC_KEY *key, const EC_GROUP *group)
|
|||
key->group = EC_GROUP_dup(group);
|
||||
return (key->group == NULL) ? 0 : 1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_group);
|
||||
|
||||
const BIGNUM *
|
||||
EC_KEY_get0_private_key(const EC_KEY *key)
|
||||
{
|
||||
return key->priv_key;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get0_private_key);
|
||||
|
||||
int
|
||||
EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key)
|
||||
|
@ -446,12 +460,14 @@ EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key)
|
|||
|
||||
return 1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_private_key);
|
||||
|
||||
const EC_POINT *
|
||||
EC_KEY_get0_public_key(const EC_KEY *key)
|
||||
{
|
||||
return key->pub_key;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get0_public_key);
|
||||
|
||||
int
|
||||
EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub_key)
|
||||
|
@ -466,24 +482,28 @@ EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub_key)
|
|||
|
||||
return 1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_public_key);
|
||||
|
||||
unsigned int
|
||||
EC_KEY_get_enc_flags(const EC_KEY *key)
|
||||
{
|
||||
return key->enc_flag;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get_enc_flags);
|
||||
|
||||
void
|
||||
EC_KEY_set_enc_flags(EC_KEY *key, unsigned int flags)
|
||||
{
|
||||
key->enc_flag = flags;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_enc_flags);
|
||||
|
||||
point_conversion_form_t
|
||||
EC_KEY_get_conv_form(const EC_KEY *key)
|
||||
{
|
||||
return key->conv_form;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get_conv_form);
|
||||
|
||||
void
|
||||
EC_KEY_set_conv_form(EC_KEY *key, point_conversion_form_t cform)
|
||||
|
@ -492,6 +512,7 @@ EC_KEY_set_conv_form(EC_KEY *key, point_conversion_form_t cform)
|
|||
if (key->group != NULL)
|
||||
EC_GROUP_set_point_conversion_form(key->group, cform);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_conv_form);
|
||||
|
||||
void
|
||||
EC_KEY_set_asn1_flag(EC_KEY *key, int flag)
|
||||
|
@ -499,6 +520,7 @@ EC_KEY_set_asn1_flag(EC_KEY *key, int flag)
|
|||
if (key->group != NULL)
|
||||
EC_GROUP_set_asn1_flag(key->group, flag);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_asn1_flag);
|
||||
|
||||
int
|
||||
EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx)
|
||||
|
@ -507,21 +529,25 @@ EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx)
|
|||
return 0;
|
||||
return EC_GROUP_precompute_mult(key->group, ctx);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_precompute_mult);
|
||||
|
||||
int
|
||||
EC_KEY_get_flags(const EC_KEY *key)
|
||||
{
|
||||
return key->flags;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get_flags);
|
||||
|
||||
void
|
||||
EC_KEY_set_flags(EC_KEY *key, int flags)
|
||||
{
|
||||
key->flags |= flags;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_flags);
|
||||
|
||||
void
|
||||
EC_KEY_clear_flags(EC_KEY *key, int flags)
|
||||
{
|
||||
key->flags &= ~flags;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_clear_flags);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_kmeth.c,v 1.10 2023/07/05 11:37:46 tb Exp $ */
|
||||
/* $OpenBSD: ec_kmeth.c,v 1.11 2023/07/07 13:54:45 beck Exp $ */
|
||||
/*
|
||||
* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
|
||||
* project.
|
||||
|
@ -92,12 +92,14 @@ EC_KEY_OpenSSL(void)
|
|||
{
|
||||
return &openssl_ec_key_method;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_OpenSSL);
|
||||
|
||||
const EC_KEY_METHOD *
|
||||
EC_KEY_get_default_method(void)
|
||||
{
|
||||
return default_ec_key_meth;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get_default_method);
|
||||
|
||||
void
|
||||
EC_KEY_set_default_method(const EC_KEY_METHOD *meth)
|
||||
|
@ -107,12 +109,14 @@ EC_KEY_set_default_method(const EC_KEY_METHOD *meth)
|
|||
else
|
||||
default_ec_key_meth = meth;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_default_method);
|
||||
|
||||
const EC_KEY_METHOD *
|
||||
EC_KEY_get_method(const EC_KEY *key)
|
||||
{
|
||||
return key->meth;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_get_method);
|
||||
|
||||
int
|
||||
EC_KEY_set_method(EC_KEY *key, const EC_KEY_METHOD *meth)
|
||||
|
@ -132,6 +136,7 @@ EC_KEY_set_method(EC_KEY *key, const EC_KEY_METHOD *meth)
|
|||
return meth->init(key);
|
||||
return 1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_set_method);
|
||||
|
||||
EC_KEY *
|
||||
EC_KEY_new_method(ENGINE *engine)
|
||||
|
@ -180,6 +185,7 @@ EC_KEY_new_method(ENGINE *engine)
|
|||
EC_KEY_free(ret);
|
||||
return NULL;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_new_method);
|
||||
|
||||
EC_KEY_METHOD *
|
||||
EC_KEY_METHOD_new(const EC_KEY_METHOD *meth)
|
||||
|
@ -193,6 +199,7 @@ EC_KEY_METHOD_new(const EC_KEY_METHOD *meth)
|
|||
ret->flags |= EC_KEY_METHOD_DYNAMIC;
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_new);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_free(EC_KEY_METHOD *meth)
|
||||
|
@ -202,6 +209,7 @@ EC_KEY_METHOD_free(EC_KEY_METHOD *meth)
|
|||
if (meth->flags & EC_KEY_METHOD_DYNAMIC)
|
||||
free(meth);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_free);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_set_init(EC_KEY_METHOD *meth,
|
||||
|
@ -219,12 +227,14 @@ EC_KEY_METHOD_set_init(EC_KEY_METHOD *meth,
|
|||
meth->set_private = set_private;
|
||||
meth->set_public = set_public;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_set_init);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_set_keygen(EC_KEY_METHOD *meth, int (*keygen)(EC_KEY *key))
|
||||
{
|
||||
meth->keygen = keygen;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_set_keygen);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_set_compute_key(EC_KEY_METHOD *meth,
|
||||
|
@ -233,6 +243,7 @@ EC_KEY_METHOD_set_compute_key(EC_KEY_METHOD *meth,
|
|||
{
|
||||
meth->compute_key = ckey;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_set_compute_key);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_set_sign(EC_KEY_METHOD *meth,
|
||||
|
@ -249,6 +260,7 @@ EC_KEY_METHOD_set_sign(EC_KEY_METHOD *meth,
|
|||
meth->sign_setup = sign_setup;
|
||||
meth->sign_sig = sign_sig;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_set_sign);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_set_verify(EC_KEY_METHOD *meth,
|
||||
|
@ -260,6 +272,7 @@ EC_KEY_METHOD_set_verify(EC_KEY_METHOD *meth,
|
|||
meth->verify = verify;
|
||||
meth->verify_sig = verify_sig;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_set_verify);
|
||||
|
||||
|
||||
void
|
||||
|
@ -284,6 +297,7 @@ EC_KEY_METHOD_get_init(const EC_KEY_METHOD *meth,
|
|||
if (pset_public != NULL)
|
||||
*pset_public = meth->set_public;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_get_init);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_get_keygen(const EC_KEY_METHOD *meth,
|
||||
|
@ -292,6 +306,7 @@ EC_KEY_METHOD_get_keygen(const EC_KEY_METHOD *meth,
|
|||
if (pkeygen != NULL)
|
||||
*pkeygen = meth->keygen;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_get_keygen);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_get_compute_key(const EC_KEY_METHOD *meth,
|
||||
|
@ -301,6 +316,7 @@ EC_KEY_METHOD_get_compute_key(const EC_KEY_METHOD *meth,
|
|||
if (pck != NULL)
|
||||
*pck = meth->compute_key;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_get_compute_key);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_get_sign(const EC_KEY_METHOD *meth,
|
||||
|
@ -320,6 +336,7 @@ EC_KEY_METHOD_get_sign(const EC_KEY_METHOD *meth,
|
|||
if (psign_sig != NULL)
|
||||
*psign_sig = meth->sign_sig;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_get_sign);
|
||||
|
||||
void
|
||||
EC_KEY_METHOD_get_verify(const EC_KEY_METHOD *meth,
|
||||
|
@ -333,3 +350,4 @@ EC_KEY_METHOD_get_verify(const EC_KEY_METHOD *meth,
|
|||
if (pverify_sig != NULL)
|
||||
*pverify_sig = meth->verify_sig;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_METHOD_get_verify);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_lib.c,v 1.62 2023/07/03 07:26:40 tb Exp $ */
|
||||
/* $OpenBSD: ec_lib.c,v 1.64 2023/07/07 19:37:53 beck Exp $ */
|
||||
/*
|
||||
* Originally written by Bodo Moeller for the OpenSSL project.
|
||||
*/
|
||||
|
@ -110,6 +110,7 @@ EC_GROUP_new(const EC_METHOD *meth)
|
|||
}
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_new);
|
||||
|
||||
|
||||
void
|
||||
|
@ -128,6 +129,7 @@ EC_GROUP_free(EC_GROUP *group)
|
|||
freezero(group->seed, group->seed_len);
|
||||
freezero(group, sizeof *group);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_free);
|
||||
|
||||
void
|
||||
EC_GROUP_clear_free(EC_GROUP *group)
|
||||
|
@ -188,6 +190,7 @@ EC_GROUP_copy(EC_GROUP *dest, const EC_GROUP *src)
|
|||
|
||||
return dest->meth->group_copy(dest, src);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_copy);
|
||||
|
||||
|
||||
EC_GROUP *
|
||||
|
@ -202,6 +205,7 @@ EC_GROUP_dup(const EC_GROUP *a)
|
|||
}
|
||||
return t;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_dup);
|
||||
|
||||
|
||||
const EC_METHOD *
|
||||
|
@ -209,6 +213,7 @@ EC_GROUP_method_of(const EC_GROUP *group)
|
|||
{
|
||||
return group->meth;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_method_of);
|
||||
|
||||
|
||||
int
|
||||
|
@ -216,6 +221,7 @@ EC_METHOD_get_field_type(const EC_METHOD *meth)
|
|||
{
|
||||
return meth->field_type;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_METHOD_get_field_type);
|
||||
|
||||
/*
|
||||
* If there is a user-provided cofactor, sanity check and use it. Otherwise
|
||||
|
@ -349,6 +355,7 @@ EC_GROUP_set_generator(EC_GROUP *group, const EC_POINT *generator,
|
|||
|
||||
return 1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_set_generator);
|
||||
|
||||
|
||||
const EC_POINT *
|
||||
|
@ -356,6 +363,7 @@ EC_GROUP_get0_generator(const EC_GROUP *group)
|
|||
{
|
||||
return group->generator;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get0_generator);
|
||||
|
||||
int
|
||||
EC_GROUP_get_order(const EC_GROUP *group, BIGNUM *order, BN_CTX *ctx)
|
||||
|
@ -365,6 +373,7 @@ EC_GROUP_get_order(const EC_GROUP *group, BIGNUM *order, BN_CTX *ctx)
|
|||
|
||||
return !BN_is_zero(order);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_order);
|
||||
|
||||
const BIGNUM *
|
||||
EC_GROUP_get0_order(const EC_GROUP *group)
|
||||
|
@ -377,6 +386,7 @@ EC_GROUP_order_bits(const EC_GROUP *group)
|
|||
{
|
||||
return group->meth->group_order_bits(group);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_order_bits);
|
||||
|
||||
int
|
||||
EC_GROUP_get_cofactor(const EC_GROUP *group, BIGNUM *cofactor, BN_CTX *ctx)
|
||||
|
@ -386,6 +396,7 @@ EC_GROUP_get_cofactor(const EC_GROUP *group, BIGNUM *cofactor, BN_CTX *ctx)
|
|||
|
||||
return !BN_is_zero(&group->cofactor);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_cofactor);
|
||||
|
||||
|
||||
void
|
||||
|
@ -393,6 +404,7 @@ EC_GROUP_set_curve_name(EC_GROUP *group, int nid)
|
|||
{
|
||||
group->curve_name = nid;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_set_curve_name);
|
||||
|
||||
|
||||
int
|
||||
|
@ -400,6 +412,7 @@ EC_GROUP_get_curve_name(const EC_GROUP *group)
|
|||
{
|
||||
return group->curve_name;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_curve_name);
|
||||
|
||||
|
||||
void
|
||||
|
@ -407,6 +420,7 @@ EC_GROUP_set_asn1_flag(EC_GROUP *group, int flag)
|
|||
{
|
||||
group->asn1_flag = flag;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_set_asn1_flag);
|
||||
|
||||
|
||||
int
|
||||
|
@ -414,6 +428,7 @@ EC_GROUP_get_asn1_flag(const EC_GROUP *group)
|
|||
{
|
||||
return group->asn1_flag;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_asn1_flag);
|
||||
|
||||
|
||||
void
|
||||
|
@ -422,6 +437,7 @@ EC_GROUP_set_point_conversion_form(EC_GROUP *group,
|
|||
{
|
||||
group->asn1_form = form;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_set_point_conversion_form);
|
||||
|
||||
|
||||
point_conversion_form_t
|
||||
|
@ -429,6 +445,7 @@ EC_GROUP_get_point_conversion_form(const EC_GROUP *group)
|
|||
{
|
||||
return group->asn1_form;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_point_conversion_form);
|
||||
|
||||
|
||||
size_t
|
||||
|
@ -449,6 +466,7 @@ EC_GROUP_set_seed(EC_GROUP *group, const unsigned char *p, size_t len)
|
|||
|
||||
return len;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_set_seed);
|
||||
|
||||
|
||||
unsigned char *
|
||||
|
@ -456,6 +474,7 @@ EC_GROUP_get0_seed(const EC_GROUP *group)
|
|||
{
|
||||
return group->seed;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get0_seed);
|
||||
|
||||
|
||||
size_t
|
||||
|
@ -463,6 +482,7 @@ EC_GROUP_get_seed_len(const EC_GROUP *group)
|
|||
{
|
||||
return group->seed_len;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_seed_len);
|
||||
|
||||
int
|
||||
EC_GROUP_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a,
|
||||
|
@ -488,6 +508,7 @@ EC_GROUP_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_set_curve);
|
||||
|
||||
int
|
||||
EC_GROUP_get_curve(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b,
|
||||
|
@ -513,6 +534,7 @@ EC_GROUP_get_curve(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_curve);
|
||||
|
||||
int
|
||||
EC_GROUP_set_curve_GFp(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a,
|
||||
|
@ -537,6 +559,7 @@ EC_GROUP_get_degree(const EC_GROUP *group)
|
|||
}
|
||||
return group->meth->group_get_degree(group);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_get_degree);
|
||||
|
||||
|
||||
int
|
||||
|
@ -562,6 +585,7 @@ EC_GROUP_check_discriminant(const EC_GROUP *group, BN_CTX *ctx_in)
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_check_discriminant);
|
||||
|
||||
|
||||
int
|
||||
|
@ -637,6 +661,7 @@ EC_GROUP_cmp(const EC_GROUP *a, const EC_GROUP *b, BN_CTX *ctx)
|
|||
BN_CTX_free(ctx);
|
||||
return -1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_cmp);
|
||||
|
||||
/*
|
||||
* Coordinate blinding for EC_POINT.
|
||||
|
@ -682,6 +707,7 @@ EC_POINT_new(const EC_GROUP *group)
|
|||
}
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_new);
|
||||
|
||||
void
|
||||
EC_POINT_free(EC_POINT *point)
|
||||
|
@ -694,6 +720,7 @@ EC_POINT_free(EC_POINT *point)
|
|||
|
||||
freezero(point, sizeof *point);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_free);
|
||||
|
||||
void
|
||||
EC_POINT_clear_free(EC_POINT *point)
|
||||
|
@ -716,6 +743,7 @@ EC_POINT_copy(EC_POINT *dest, const EC_POINT *src)
|
|||
return 1;
|
||||
return dest->meth->point_copy(dest, src);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_copy);
|
||||
|
||||
EC_POINT *
|
||||
EC_POINT_dup(const EC_POINT *a, const EC_GROUP *group)
|
||||
|
@ -736,12 +764,14 @@ EC_POINT_dup(const EC_POINT *a, const EC_GROUP *group)
|
|||
} else
|
||||
return t;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_dup);
|
||||
|
||||
const EC_METHOD *
|
||||
EC_POINT_method_of(const EC_POINT *point)
|
||||
{
|
||||
return point->meth;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_method_of);
|
||||
|
||||
int
|
||||
EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point)
|
||||
|
@ -756,6 +786,7 @@ EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point)
|
|||
}
|
||||
return group->meth->point_set_to_infinity(group, point);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_set_to_infinity);
|
||||
|
||||
int
|
||||
EC_POINT_set_Jprojective_coordinates(const EC_GROUP *group, EC_POINT *point,
|
||||
|
@ -875,6 +906,7 @@ EC_POINT_set_affine_coordinates(const EC_GROUP *group, EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_set_affine_coordinates);
|
||||
|
||||
int
|
||||
EC_POINT_set_affine_coordinates_GFp(const EC_GROUP *group, EC_POINT *point,
|
||||
|
@ -911,6 +943,7 @@ EC_POINT_get_affine_coordinates(const EC_GROUP *group, const EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_get_affine_coordinates);
|
||||
|
||||
int
|
||||
EC_POINT_get_affine_coordinates_GFp(const EC_GROUP *group, const EC_POINT *point,
|
||||
|
@ -948,6 +981,7 @@ EC_POINT_add(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_add);
|
||||
|
||||
int
|
||||
EC_POINT_dbl(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a,
|
||||
|
@ -977,6 +1011,7 @@ EC_POINT_dbl(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_dbl);
|
||||
|
||||
int
|
||||
EC_POINT_invert(const EC_GROUP *group, EC_POINT *a, BN_CTX *ctx_in)
|
||||
|
@ -1005,6 +1040,7 @@ EC_POINT_invert(const EC_GROUP *group, EC_POINT *a, BN_CTX *ctx_in)
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_invert);
|
||||
|
||||
int
|
||||
EC_POINT_is_at_infinity(const EC_GROUP *group, const EC_POINT *point)
|
||||
|
@ -1019,6 +1055,7 @@ EC_POINT_is_at_infinity(const EC_GROUP *group, const EC_POINT *point)
|
|||
}
|
||||
return group->meth->is_at_infinity(group, point);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_is_at_infinity);
|
||||
|
||||
int
|
||||
EC_POINT_is_on_curve(const EC_GROUP *group, const EC_POINT *point,
|
||||
|
@ -1048,6 +1085,7 @@ EC_POINT_is_on_curve(const EC_GROUP *group, const EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_is_on_curve);
|
||||
|
||||
int
|
||||
EC_POINT_cmp(const EC_GROUP *group, const EC_POINT *a, const EC_POINT *b,
|
||||
|
@ -1077,6 +1115,7 @@ EC_POINT_cmp(const EC_GROUP *group, const EC_POINT *a, const EC_POINT *b,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_cmp);
|
||||
|
||||
int
|
||||
EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx_in)
|
||||
|
@ -1105,6 +1144,7 @@ EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx_in)
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_make_affine);
|
||||
|
||||
int
|
||||
EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[],
|
||||
|
@ -1137,6 +1177,7 @@ EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[],
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINTs_make_affine);
|
||||
|
||||
int
|
||||
EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
|
||||
|
@ -1178,6 +1219,7 @@ EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINTs_mul);
|
||||
|
||||
int
|
||||
EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *g_scalar,
|
||||
|
@ -1239,18 +1281,21 @@ EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *g_scalar,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_mul);
|
||||
|
||||
int
|
||||
EC_GROUP_precompute_mult(EC_GROUP *group, BN_CTX *ctx_in)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_precompute_mult);
|
||||
|
||||
int
|
||||
EC_GROUP_have_precompute_mult(const EC_GROUP *group)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GROUP_have_precompute_mult);
|
||||
|
||||
int
|
||||
ec_group_simple_order_bits(const EC_GROUP *group)
|
||||
|
@ -1283,3 +1328,4 @@ ECParameters_dup(EC_KEY *key)
|
|||
|
||||
return dup;
|
||||
}
|
||||
LCRYPTO_ALIAS(ECParameters_dup);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_oct.c,v 1.14 2023/05/04 06:45:51 tb Exp $ */
|
||||
/* $OpenBSD: ec_oct.c,v 1.16 2023/07/07 19:37:53 beck Exp $ */
|
||||
/*
|
||||
* Originally written by Bodo Moeller for the OpenSSL project.
|
||||
*/
|
||||
|
@ -99,6 +99,7 @@ EC_POINT_set_compressed_coordinates(const EC_GROUP *group, EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_set_compressed_coordinates);
|
||||
|
||||
int
|
||||
EC_POINT_set_compressed_coordinates_GFp(const EC_GROUP *group, EC_POINT *point,
|
||||
|
@ -136,6 +137,7 @@ EC_POINT_point2oct(const EC_GROUP *group, const EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_point2oct);
|
||||
|
||||
int
|
||||
EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *point,
|
||||
|
@ -165,3 +167,4 @@ EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_oct2point);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ec_print.c,v 1.12 2023/06/23 10:34:16 tb Exp $ */
|
||||
/* $OpenBSD: ec_print.c,v 1.13 2023/07/07 13:54:45 beck Exp $ */
|
||||
/* ====================================================================
|
||||
* Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved.
|
||||
*
|
||||
|
@ -81,6 +81,7 @@ EC_POINT_point2bn(const EC_GROUP *group, const EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_point2bn);
|
||||
|
||||
EC_POINT *
|
||||
EC_POINT_bn2point(const EC_GROUP *group,
|
||||
|
@ -117,6 +118,7 @@ EC_POINT_bn2point(const EC_GROUP *group,
|
|||
free(buf);
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_bn2point);
|
||||
|
||||
static const char *HEX_DIGITS = "0123456789ABCDEF";
|
||||
|
||||
|
@ -159,6 +161,7 @@ EC_POINT_point2hex(const EC_GROUP *group, const EC_POINT *point,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_point2hex);
|
||||
|
||||
EC_POINT *
|
||||
EC_POINT_hex2point(const EC_GROUP *group, const char *buf,
|
||||
|
@ -176,3 +179,4 @@ EC_POINT_hex2point(const EC_GROUP *group, const char *buf,
|
|||
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_POINT_hex2point);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: eck_prn.c,v 1.27 2023/07/06 15:18:02 tb Exp $ */
|
||||
/* $OpenBSD: eck_prn.c,v 1.28 2023/07/07 13:54:45 beck Exp $ */
|
||||
/*
|
||||
* Written by Nils Larsch for the OpenSSL project.
|
||||
*/
|
||||
|
@ -86,6 +86,7 @@ ECPKParameters_print_fp(FILE *fp, const EC_GROUP *x, int off)
|
|||
BIO_free(b);
|
||||
return (ret);
|
||||
}
|
||||
LCRYPTO_ALIAS(ECPKParameters_print_fp);
|
||||
|
||||
int
|
||||
EC_KEY_print_fp(FILE *fp, const EC_KEY *x, int off)
|
||||
|
@ -102,6 +103,7 @@ EC_KEY_print_fp(FILE *fp, const EC_KEY *x, int off)
|
|||
BIO_free(b);
|
||||
return (ret);
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_print_fp);
|
||||
|
||||
int
|
||||
ECParameters_print_fp(FILE *fp, const EC_KEY *x)
|
||||
|
@ -118,6 +120,7 @@ ECParameters_print_fp(FILE *fp, const EC_KEY *x)
|
|||
BIO_free(b);
|
||||
return (ret);
|
||||
}
|
||||
LCRYPTO_ALIAS(ECParameters_print_fp);
|
||||
|
||||
int
|
||||
EC_KEY_print(BIO *bp, const EC_KEY *x, int off)
|
||||
|
@ -136,6 +139,7 @@ EC_KEY_print(BIO *bp, const EC_KEY *x, int off)
|
|||
EVP_PKEY_free(pk);
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_KEY_print);
|
||||
|
||||
int
|
||||
ECParameters_print(BIO *bp, const EC_KEY *x)
|
||||
|
@ -154,6 +158,7 @@ ECParameters_print(BIO *bp, const EC_KEY *x)
|
|||
EVP_PKEY_free(pk);
|
||||
return ret;
|
||||
}
|
||||
LCRYPTO_ALIAS(ECParameters_print);
|
||||
|
||||
static int
|
||||
print_bin(BIO *fp, const char *str, const unsigned char *num,
|
||||
|
@ -310,6 +315,7 @@ ECPKParameters_print(BIO *bp, const EC_GROUP *group, int off)
|
|||
|
||||
return ecpk_print_explicit_parameters(bp, group, off);
|
||||
}
|
||||
LCRYPTO_ALIAS(ECPKParameters_print);
|
||||
|
||||
static int
|
||||
print_bin(BIO *fp, const char *name, const unsigned char *buf,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ecp_mont.c,v 1.29 2023/04/11 18:58:20 jsing Exp $ */
|
||||
/* $OpenBSD: ecp_mont.c,v 1.30 2023/07/07 13:54:45 beck Exp $ */
|
||||
/*
|
||||
* Originally written by Bodo Moeller for the OpenSSL project.
|
||||
*/
|
||||
|
@ -269,3 +269,4 @@ EC_GFp_mont_method(void)
|
|||
{
|
||||
return &ec_GFp_mont_method;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GFp_mont_method);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: ecp_smpl.c,v 1.45 2023/06/30 18:19:35 tb Exp $ */
|
||||
/* $OpenBSD: ecp_smpl.c,v 1.46 2023/07/07 13:54:45 beck Exp $ */
|
||||
/* Includes code written by Lenka Fibikova <fibikova@exp-math.uni-essen.de>
|
||||
* for the OpenSSL project.
|
||||
* Includes code written by Bodo Moeller for the OpenSSL project.
|
||||
|
@ -1604,3 +1604,4 @@ EC_GFp_simple_method(void)
|
|||
{
|
||||
return &ec_GFp_simple_method;
|
||||
}
|
||||
LCRYPTO_ALIAS(EC_GFp_simple_method);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue