From 721a0919125aaef71da76adcbdb7905843d039ab Mon Sep 17 00:00:00 2001 From: tb <> Date: Sat, 2 Mar 2024 09:47:16 +0000 Subject: Remove OBJ_bsearch_() The only reason this has still been part of the public API was that libssl used it for cipher lookup. This was fixed by replacing the lookup by proper bsearch() -- why OpenSSL felt the need to reinvent ANSI C API badly will forever remain a mystery. The stack code in libcrypto still uses a version of this. This should be rewritten. It will be a bit easier once sk_find_ex() is removed. ok jsing --- src/lib/libcrypto/objects/objects.h | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) (limited to 'src/lib/libcrypto/objects/objects.h') diff --git a/src/lib/libcrypto/objects/objects.h b/src/lib/libcrypto/objects/objects.h index 2d3aa986d5..ef6fc233bf 100644 --- a/src/lib/libcrypto/objects/objects.h +++ b/src/lib/libcrypto/objects/objects.h @@ -1,4 +1,4 @@ -/* $OpenBSD: objects.h,v 1.25 2024/03/02 09:43:10 tb Exp $ */ +/* $OpenBSD: objects.h,v 1.26 2024/03/02 09:47:16 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -77,10 +77,6 @@ #define OBJ_NAME_ALIAS 0x8000 -#define OBJ_BSEARCH_VALUE_ON_NOMATCH 0x01 -#define OBJ_BSEARCH_FIRST_VALUE_ON_MATCH 0x02 - - #ifdef __cplusplus extern "C" { #endif @@ -111,14 +107,6 @@ int OBJ_ln2nid(const char *s); int OBJ_sn2nid(const char *s); int OBJ_cmp(const ASN1_OBJECT *a, const ASN1_OBJECT *b); -#if defined(LIBRESSL_INTERNAL) -const void * OBJ_bsearch_(const void *key, const void *base, int num, - int size, int (*cmp)(const void *, const void *)); -const void * OBJ_bsearch_ex_(const void *key, const void *base, int num, - int size, int (*cmp)(const void *, const void *), - int flags); -#endif - int OBJ_new_nid(int num); int OBJ_add_object(const ASN1_OBJECT *obj); int OBJ_create(const char *oid, const char *sn, const char *ln); -- cgit v1.2.3-55-g6feb