summaryrefslogtreecommitdiffstats
path: root/lib/libssl/src/crypto/ecdsa/ecs_ossl.c
diff options
context:
space:
mode:
authordjm <djm@openbsd.org>2012-10-13 21:23:32 +0000
committerdjm <djm@openbsd.org>2012-10-13 21:23:32 +0000
commitec07fdf13572372e9cd617b18f2e2790e6616c8c (patch)
treebc2aaa935cf216bb82963cd07e6b9f736c4cb1e7 /lib/libssl/src/crypto/ecdsa/ecs_ossl.c
parentsync (diff)
downloadwireguard-openbsd-ec07fdf13572372e9cd617b18f2e2790e6616c8c.tar.xz
wireguard-openbsd-ec07fdf13572372e9cd617b18f2e2790e6616c8c.zip
import OpenSSL-1.0.1c
Diffstat (limited to 'lib/libssl/src/crypto/ecdsa/ecs_ossl.c')
-rw-r--r--lib/libssl/src/crypto/ecdsa/ecs_ossl.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/libssl/src/crypto/ecdsa/ecs_ossl.c b/lib/libssl/src/crypto/ecdsa/ecs_ossl.c
index 1bbf328de54..7725935610e 100644
--- a/lib/libssl/src/crypto/ecdsa/ecs_ossl.c
+++ b/lib/libssl/src/crypto/ecdsa/ecs_ossl.c
@@ -167,6 +167,7 @@ static int ecdsa_sign_setup(EC_KEY *eckey, BN_CTX *ctx_in, BIGNUM **kinvp,
goto err;
}
}
+#ifndef OPENSSL_NO_EC2M
else /* NID_X9_62_characteristic_two_field */
{
if (!EC_POINT_get_affine_coordinates_GF2m(group,
@@ -176,6 +177,7 @@ static int ecdsa_sign_setup(EC_KEY *eckey, BN_CTX *ctx_in, BIGNUM **kinvp,
goto err;
}
}
+#endif
if (!BN_nnmod(r, X, order, ctx))
{
ECDSAerr(ECDSA_F_ECDSA_SIGN_SETUP, ERR_R_BN_LIB);
@@ -454,6 +456,7 @@ static int ecdsa_do_verify(const unsigned char *dgst, int dgst_len,
goto err;
}
}
+#ifndef OPENSSL_NO_EC2M
else /* NID_X9_62_characteristic_two_field */
{
if (!EC_POINT_get_affine_coordinates_GF2m(group,
@@ -463,7 +466,7 @@ static int ecdsa_do_verify(const unsigned char *dgst, int dgst_len,
goto err;
}
}
-
+#endif
if (!BN_nnmod(u1, X, order, ctx))
{
ECDSAerr(ECDSA_F_ECDSA_DO_VERIFY, ERR_R_BN_LIB);