summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/asn1
diff options
context:
space:
mode:
authortb <>2024-03-02 10:03:13 +0000
committertb <>2024-03-02 10:03:13 +0000
commit10d41204e8ddb50a380449ffe06fcbff6b901565 (patch)
treec4cc7ad2519b1a29cfb700d282bcdba9777490df /src/lib/libcrypto/asn1
parent390c4d5e48028e0a43621ca1bdbfb80aa119e1fc (diff)
downloadopenbsd-10d41204e8ddb50a380449ffe06fcbff6b901565.tar.gz
openbsd-10d41204e8ddb50a380449ffe06fcbff6b901565.tar.bz2
openbsd-10d41204e8ddb50a380449ffe06fcbff6b901565.zip
Remove the ameth lib
This is accessor API for ASN.1 methods needed for custom PKEYs. Nothing has ever used this. This has been neutered for months. The EVP_PKEY_asn1_* API that needs to stay was moved elsewhere. ok jsing
Diffstat (limited to 'src/lib/libcrypto/asn1')
-rw-r--r--src/lib/libcrypto/asn1/ameth_lib.c180
1 files changed, 0 insertions, 180 deletions
diff --git a/src/lib/libcrypto/asn1/ameth_lib.c b/src/lib/libcrypto/asn1/ameth_lib.c
deleted file mode 100644
index 35fcb8ea08..0000000000
--- a/src/lib/libcrypto/asn1/ameth_lib.c
+++ /dev/null
@@ -1,180 +0,0 @@
1/* $OpenBSD: ameth_lib.c,v 1.42 2024/01/04 16:50:53 tb Exp $ */
2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
3 * project 2006.
4 */
5/* ====================================================================
6 * Copyright (c) 2006 The OpenSSL Project. All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions
10 * are met:
11 *
12 * 1. Redistributions of source code must retain the above copyright
13 * notice, this list of conditions and the following disclaimer.
14 *
15 * 2. Redistributions in binary form must reproduce the above copyright
16 * notice, this list of conditions and the following disclaimer in
17 * the documentation and/or other materials provided with the
18 * distribution.
19 *
20 * 3. All advertising materials mentioning features or use of this
21 * software must display the following acknowledgment:
22 * "This product includes software developed by the OpenSSL Project
23 * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)"
24 *
25 * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
26 * endorse or promote products derived from this software without
27 * prior written permission. For written permission, please contact
28 * licensing@OpenSSL.org.
29 *
30 * 5. Products derived from this software may not be called "OpenSSL"
31 * nor may "OpenSSL" appear in their names without prior written
32 * permission of the OpenSSL Project.
33 *
34 * 6. Redistributions of any form whatsoever must retain the following
35 * acknowledgment:
36 * "This product includes software developed by the OpenSSL Project
37 * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)"
38 *
39 * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
40 * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
41 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
42 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR
43 * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
44 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
45 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
46 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
47 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
48 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
49 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
50 * OF THE POSSIBILITY OF SUCH DAMAGE.
51 * ====================================================================
52 *
53 * This product includes cryptographic software written by Eric Young
54 * (eay@cryptsoft.com). This product includes software written by Tim
55 * Hudson (tjh@cryptsoft.com).
56 *
57 */
58
59#include <stdlib.h>
60#include <string.h>
61
62#include <openssl/err.h>
63#include <openssl/evp.h>
64
65#include "evp_local.h"
66
67/*
68 * XXX - remove all the API below here in the next major bump.
69 */
70
71EVP_PKEY_ASN1_METHOD*
72EVP_PKEY_asn1_new(int id, int flags, const char *pem_str, const char *info)
73{
74 EVPerror(ERR_R_DISABLED);
75 return NULL;
76}
77
78void
79EVP_PKEY_asn1_copy(EVP_PKEY_ASN1_METHOD *dst, const EVP_PKEY_ASN1_METHOD *src)
80{
81 EVPerror(ERR_R_DISABLED);
82}
83
84void
85EVP_PKEY_asn1_free(EVP_PKEY_ASN1_METHOD *ameth)
86{
87 EVPerror(ERR_R_DISABLED);
88}
89
90void
91EVP_PKEY_asn1_set_public(EVP_PKEY_ASN1_METHOD *ameth,
92 int (*pub_decode)(EVP_PKEY *pk, X509_PUBKEY *pub),
93 int (*pub_encode)(X509_PUBKEY *pub, const EVP_PKEY *pk),
94 int (*pub_cmp)(const EVP_PKEY *a, const EVP_PKEY *b),
95 int (*pub_print)(BIO *out, const EVP_PKEY *pkey, int indent,
96 ASN1_PCTX *pctx),
97 int (*pkey_size)(const EVP_PKEY *pk),
98 int (*pkey_bits)(const EVP_PKEY *pk))
99{
100 EVPerror(ERR_R_DISABLED);
101}
102
103void
104EVP_PKEY_asn1_set_private(EVP_PKEY_ASN1_METHOD *ameth,
105 int (*priv_decode)(EVP_PKEY *pk, const PKCS8_PRIV_KEY_INFO *p8inf),
106 int (*priv_encode)(PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pk),
107 int (*priv_print)(BIO *out, const EVP_PKEY *pkey, int indent,
108 ASN1_PCTX *pctx))
109{
110 EVPerror(ERR_R_DISABLED);
111}
112
113void
114EVP_PKEY_asn1_set_param(EVP_PKEY_ASN1_METHOD *ameth,
115 int (*param_decode)(EVP_PKEY *pkey, const unsigned char **pder, int derlen),
116 int (*param_encode)(const EVP_PKEY *pkey, unsigned char **pder),
117 int (*param_missing)(const EVP_PKEY *pk),
118 int (*param_copy)(EVP_PKEY *to, const EVP_PKEY *from),
119 int (*param_cmp)(const EVP_PKEY *a, const EVP_PKEY *b),
120 int (*param_print)(BIO *out, const EVP_PKEY *pkey, int indent,
121 ASN1_PCTX *pctx))
122{
123 EVPerror(ERR_R_DISABLED);
124}
125
126void
127EVP_PKEY_asn1_set_free(EVP_PKEY_ASN1_METHOD *ameth,
128 void (*pkey_free)(EVP_PKEY *pkey))
129{
130 EVPerror(ERR_R_DISABLED);
131}
132
133void
134EVP_PKEY_asn1_set_ctrl(EVP_PKEY_ASN1_METHOD *ameth,
135 int (*pkey_ctrl)(EVP_PKEY *pkey, int op, long arg1, void *arg2))
136{
137 EVPerror(ERR_R_DISABLED);
138}
139
140void
141EVP_PKEY_asn1_set_security_bits(EVP_PKEY_ASN1_METHOD *ameth,
142 int (*pkey_security_bits)(const EVP_PKEY *pkey))
143{
144 EVPerror(ERR_R_DISABLED);
145}
146
147void
148EVP_PKEY_asn1_set_check(EVP_PKEY_ASN1_METHOD *ameth,
149 int (*pkey_check)(const EVP_PKEY *pk))
150{
151 EVPerror(ERR_R_DISABLED);
152}
153
154void
155EVP_PKEY_asn1_set_public_check(EVP_PKEY_ASN1_METHOD *ameth,
156 int (*pkey_public_check)(const EVP_PKEY *pk))
157{
158 EVPerror(ERR_R_DISABLED);
159}
160
161void
162EVP_PKEY_asn1_set_param_check(EVP_PKEY_ASN1_METHOD *ameth,
163 int (*pkey_param_check)(const EVP_PKEY *pk))
164{
165 EVPerror(ERR_R_DISABLED);
166}
167
168int
169EVP_PKEY_asn1_add0(const EVP_PKEY_ASN1_METHOD *ameth)
170{
171 EVPerror(ERR_R_DISABLED);
172 return 0;
173}
174
175int
176EVP_PKEY_asn1_add_alias(int to, int from)
177{
178 EVPerror(ERR_R_DISABLED);
179 return 0;
180}