summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorTheo Buehler <tb@cvs.openbsd.org>2023-06-25 18:24:34 +0000
committerTheo Buehler <tb@cvs.openbsd.org>2023-06-25 18:24:34 +0000
commit64c8809e2412ead102469dac766e030f3252352a (patch)
tree4f47a6aceed214fbfb0c2b23212c16c5a7fb35dd /lib
parent26f1e8168e64678e02bd077dd17242c95e471125 (diff)
Make {ECDH,ECDSA}_set_method() always fail
They will be removed in the next major bump. No port uses them. They use code that is in the way of upcoming surgery. Only libtls used the ECDSA version, but thankfully op cleaned that up. ok jsing
Diffstat (limited to 'lib')
-rw-r--r--lib/libcrypto/ecdh/ech_lib.c16
-rw-r--r--lib/libcrypto/ecdsa/ecs_lib.c17
2 files changed, 4 insertions, 29 deletions
diff --git a/lib/libcrypto/ecdh/ech_lib.c b/lib/libcrypto/ecdh/ech_lib.c
index 15d7737c393..90e14e11089 100644
--- a/lib/libcrypto/ecdh/ech_lib.c
+++ b/lib/libcrypto/ecdh/ech_lib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ech_lib.c,v 1.16 2023/04/25 19:26:45 tb Exp $ */
+/* $OpenBSD: ech_lib.c,v 1.17 2023/06/25 18:24:33 tb Exp $ */
/* ====================================================================
* Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED.
*
@@ -103,19 +103,7 @@ ECDH_get_default_method(void)
int
ECDH_set_method(EC_KEY *eckey, const ECDH_METHOD *meth)
{
- ECDH_DATA *ecdh;
-
- ecdh = ecdh_check(eckey);
-
- if (ecdh == NULL)
- return 0;
-
-#ifndef OPENSSL_NO_ENGINE
- ENGINE_finish(ecdh->engine);
- ecdh->engine = NULL;
-#endif
- ecdh->meth = meth;
- return 1;
+ return 0;
}
static ECDH_DATA *
diff --git a/lib/libcrypto/ecdsa/ecs_lib.c b/lib/libcrypto/ecdsa/ecs_lib.c
index 9a35a030dbf..caebeeb1f93 100644
--- a/lib/libcrypto/ecdsa/ecs_lib.c
+++ b/lib/libcrypto/ecdsa/ecs_lib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ecs_lib.c,v 1.17 2023/04/25 19:26:45 tb Exp $ */
+/* $OpenBSD: ecs_lib.c,v 1.18 2023/06/25 18:24:33 tb Exp $ */
/* ====================================================================
* Copyright (c) 1998-2005 The OpenSSL Project. All rights reserved.
*
@@ -90,20 +90,7 @@ ECDSA_get_default_method(void)
int
ECDSA_set_method(EC_KEY *eckey, const ECDSA_METHOD *meth)
{
- ECDSA_DATA *ecdsa;
-
- ecdsa = ecdsa_check(eckey);
-
- if (ecdsa == NULL)
- return 0;
-
-#ifndef OPENSSL_NO_ENGINE
- ENGINE_finish(ecdsa->engine);
- ecdsa->engine = NULL;
-#endif
- ecdsa->meth = meth;
-
- return 1;
+ return 0;
}
static ECDSA_DATA *