1*de0e0e4dSAntonio Huete Jimenez /* $OpenBSD: ossl_typ.h,v 1.21 2022/01/14 08:59:30 tb Exp $ */ 2f5b1c8a1SJohn Marino /* ==================================================================== 3f5b1c8a1SJohn Marino * Copyright (c) 1998-2001 The OpenSSL Project. All rights reserved. 4f5b1c8a1SJohn Marino * 5f5b1c8a1SJohn Marino * Redistribution and use in source and binary forms, with or without 6f5b1c8a1SJohn Marino * modification, are permitted provided that the following conditions 7f5b1c8a1SJohn Marino * are met: 8f5b1c8a1SJohn Marino * 9f5b1c8a1SJohn Marino * 1. Redistributions of source code must retain the above copyright 10f5b1c8a1SJohn Marino * notice, this list of conditions and the following disclaimer. 11f5b1c8a1SJohn Marino * 12f5b1c8a1SJohn Marino * 2. Redistributions in binary form must reproduce the above copyright 13f5b1c8a1SJohn Marino * notice, this list of conditions and the following disclaimer in 14f5b1c8a1SJohn Marino * the documentation and/or other materials provided with the 15f5b1c8a1SJohn Marino * distribution. 16f5b1c8a1SJohn Marino * 17f5b1c8a1SJohn Marino * 3. All advertising materials mentioning features or use of this 18f5b1c8a1SJohn Marino * software must display the following acknowledgment: 19f5b1c8a1SJohn Marino * "This product includes software developed by the OpenSSL Project 20f5b1c8a1SJohn Marino * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" 21f5b1c8a1SJohn Marino * 22f5b1c8a1SJohn Marino * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 23f5b1c8a1SJohn Marino * endorse or promote products derived from this software without 24f5b1c8a1SJohn Marino * prior written permission. For written permission, please contact 25f5b1c8a1SJohn Marino * openssl-core@openssl.org. 26f5b1c8a1SJohn Marino * 27f5b1c8a1SJohn Marino * 5. Products derived from this software may not be called "OpenSSL" 28f5b1c8a1SJohn Marino * nor may "OpenSSL" appear in their names without prior written 29f5b1c8a1SJohn Marino * permission of the OpenSSL Project. 30f5b1c8a1SJohn Marino * 31f5b1c8a1SJohn Marino * 6. Redistributions of any form whatsoever must retain the following 32f5b1c8a1SJohn Marino * acknowledgment: 33f5b1c8a1SJohn Marino * "This product includes software developed by the OpenSSL Project 34f5b1c8a1SJohn Marino * for use in the OpenSSL Toolkit (http://www.openssl.org/)" 35f5b1c8a1SJohn Marino * 36f5b1c8a1SJohn Marino * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 37f5b1c8a1SJohn Marino * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 38f5b1c8a1SJohn Marino * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 39f5b1c8a1SJohn Marino * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 40f5b1c8a1SJohn Marino * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 41f5b1c8a1SJohn Marino * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 42f5b1c8a1SJohn Marino * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 43f5b1c8a1SJohn Marino * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 44f5b1c8a1SJohn Marino * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 45f5b1c8a1SJohn Marino * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 46f5b1c8a1SJohn Marino * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 47f5b1c8a1SJohn Marino * OF THE POSSIBILITY OF SUCH DAMAGE. 48f5b1c8a1SJohn Marino * ==================================================================== 49f5b1c8a1SJohn Marino * 50f5b1c8a1SJohn Marino * This product includes cryptographic software written by Eric Young 51f5b1c8a1SJohn Marino * (eay@cryptsoft.com). This product includes software written by Tim 52f5b1c8a1SJohn Marino * Hudson (tjh@cryptsoft.com). 53f5b1c8a1SJohn Marino * 54f5b1c8a1SJohn Marino */ 55f5b1c8a1SJohn Marino 56f5b1c8a1SJohn Marino #ifndef HEADER_OPENSSL_TYPES_H 57f5b1c8a1SJohn Marino #define HEADER_OPENSSL_TYPES_H 58f5b1c8a1SJohn Marino 59f5b1c8a1SJohn Marino #include <openssl/opensslconf.h> 60f5b1c8a1SJohn Marino 61f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_INTEGER; 62f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_ENUMERATED; 63f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_BIT_STRING; 64f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_OCTET_STRING; 65f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_PRINTABLESTRING; 66f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_T61STRING; 67f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_IA5STRING; 68f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_GENERALSTRING; 69f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_UNIVERSALSTRING; 70f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_BMPSTRING; 71f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_UTCTIME; 72f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_TIME; 73f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_GENERALIZEDTIME; 74f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_VISIBLESTRING; 75f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_UTF8STRING; 76f5b1c8a1SJohn Marino typedef struct asn1_string_st ASN1_STRING; 77f5b1c8a1SJohn Marino typedef int ASN1_BOOLEAN; 78f5b1c8a1SJohn Marino typedef int ASN1_NULL; 79f5b1c8a1SJohn Marino 80*de0e0e4dSAntonio Huete Jimenez typedef struct asn1_object_st ASN1_OBJECT; 81*de0e0e4dSAntonio Huete Jimenez 82f5b1c8a1SJohn Marino typedef struct ASN1_ITEM_st ASN1_ITEM; 83f5b1c8a1SJohn Marino typedef struct asn1_pctx_st ASN1_PCTX; 84f5b1c8a1SJohn Marino 85f5b1c8a1SJohn Marino #if defined(_WIN32) && defined(__WINCRYPT_H__) 86f5b1c8a1SJohn Marino #ifndef LIBRESSL_INTERNAL 87f5b1c8a1SJohn Marino #ifdef _MSC_VER 88f5b1c8a1SJohn Marino #pragma message("Warning, overriding WinCrypt defines") 89f5b1c8a1SJohn Marino #else 90f5b1c8a1SJohn Marino #warning overriding WinCrypt defines 91f5b1c8a1SJohn Marino #endif 92f5b1c8a1SJohn Marino #endif 93f5b1c8a1SJohn Marino #undef X509_NAME 94f5b1c8a1SJohn Marino #undef X509_CERT_PAIR 95f5b1c8a1SJohn Marino #undef X509_EXTENSIONS 96f5b1c8a1SJohn Marino #undef OCSP_REQUEST 97f5b1c8a1SJohn Marino #undef OCSP_RESPONSE 98f5b1c8a1SJohn Marino #undef PKCS7_ISSUER_AND_SERIAL 99f5b1c8a1SJohn Marino #endif 100f5b1c8a1SJohn Marino 101f5b1c8a1SJohn Marino #ifdef BIGNUM 102f5b1c8a1SJohn Marino #undef BIGNUM 103f5b1c8a1SJohn Marino #endif 104f5b1c8a1SJohn Marino typedef struct bignum_st BIGNUM; 105f5b1c8a1SJohn Marino typedef struct bignum_ctx BN_CTX; 106f5b1c8a1SJohn Marino typedef struct bn_blinding_st BN_BLINDING; 107f5b1c8a1SJohn Marino typedef struct bn_mont_ctx_st BN_MONT_CTX; 108f5b1c8a1SJohn Marino typedef struct bn_recp_ctx_st BN_RECP_CTX; 109f5b1c8a1SJohn Marino typedef struct bn_gencb_st BN_GENCB; 110f5b1c8a1SJohn Marino 111*de0e0e4dSAntonio Huete Jimenez typedef struct bio_st BIO; 112f5b1c8a1SJohn Marino typedef struct buf_mem_st BUF_MEM; 113f5b1c8a1SJohn Marino 114*de0e0e4dSAntonio Huete Jimenez typedef struct comp_ctx_st COMP_CTX; 115*de0e0e4dSAntonio Huete Jimenez typedef struct comp_method_st COMP_METHOD; 116*de0e0e4dSAntonio Huete Jimenez 117f5b1c8a1SJohn Marino typedef struct evp_cipher_st EVP_CIPHER; 118f5b1c8a1SJohn Marino typedef struct evp_cipher_ctx_st EVP_CIPHER_CTX; 119f5b1c8a1SJohn Marino typedef struct env_md_st EVP_MD; 120f5b1c8a1SJohn Marino typedef struct env_md_ctx_st EVP_MD_CTX; 121f5b1c8a1SJohn Marino typedef struct evp_pkey_st EVP_PKEY; 122f5b1c8a1SJohn Marino 123f5b1c8a1SJohn Marino typedef struct evp_pkey_asn1_method_st EVP_PKEY_ASN1_METHOD; 124f5b1c8a1SJohn Marino 125f5b1c8a1SJohn Marino typedef struct evp_pkey_method_st EVP_PKEY_METHOD; 126f5b1c8a1SJohn Marino typedef struct evp_pkey_ctx_st EVP_PKEY_CTX; 127f5b1c8a1SJohn Marino 128*de0e0e4dSAntonio Huete Jimenez typedef struct evp_Encode_Ctx_st EVP_ENCODE_CTX; 129*de0e0e4dSAntonio Huete Jimenez 130*de0e0e4dSAntonio Huete Jimenez typedef struct hmac_ctx_st HMAC_CTX; 131*de0e0e4dSAntonio Huete Jimenez 132f5b1c8a1SJohn Marino typedef struct dh_st DH; 133f5b1c8a1SJohn Marino typedef struct dh_method DH_METHOD; 134f5b1c8a1SJohn Marino 135f5b1c8a1SJohn Marino typedef struct dsa_st DSA; 136f5b1c8a1SJohn Marino typedef struct dsa_method DSA_METHOD; 137f5b1c8a1SJohn Marino 138f5b1c8a1SJohn Marino typedef struct rsa_st RSA; 139f5b1c8a1SJohn Marino typedef struct rsa_meth_st RSA_METHOD; 140*de0e0e4dSAntonio Huete Jimenez typedef struct rsa_pss_params_st RSA_PSS_PARAMS; 141f5b1c8a1SJohn Marino 142f5b1c8a1SJohn Marino typedef struct rand_meth_st RAND_METHOD; 143f5b1c8a1SJohn Marino 144f5b1c8a1SJohn Marino typedef struct ecdh_method ECDH_METHOD; 145f5b1c8a1SJohn Marino typedef struct ecdsa_method ECDSA_METHOD; 146f5b1c8a1SJohn Marino 147f5b1c8a1SJohn Marino typedef struct x509_st X509; 148f5b1c8a1SJohn Marino typedef struct X509_algor_st X509_ALGOR; 149f5b1c8a1SJohn Marino typedef struct X509_crl_st X509_CRL; 150f5b1c8a1SJohn Marino typedef struct x509_crl_method_st X509_CRL_METHOD; 151f5b1c8a1SJohn Marino typedef struct x509_revoked_st X509_REVOKED; 152f5b1c8a1SJohn Marino typedef struct X509_name_st X509_NAME; 153f5b1c8a1SJohn Marino typedef struct X509_pubkey_st X509_PUBKEY; 154f5b1c8a1SJohn Marino typedef struct x509_store_st X509_STORE; 155f5b1c8a1SJohn Marino typedef struct x509_store_ctx_st X509_STORE_CTX; 156f5b1c8a1SJohn Marino 157*de0e0e4dSAntonio Huete Jimenez typedef struct x509_object_st X509_OBJECT; 158*de0e0e4dSAntonio Huete Jimenez typedef struct x509_lookup_st X509_LOOKUP; 159*de0e0e4dSAntonio Huete Jimenez typedef struct x509_lookup_method_st X509_LOOKUP_METHOD; 160*de0e0e4dSAntonio Huete Jimenez typedef struct X509_VERIFY_PARAM_st X509_VERIFY_PARAM; 161*de0e0e4dSAntonio Huete Jimenez 162f5b1c8a1SJohn Marino typedef struct pkcs8_priv_key_info_st PKCS8_PRIV_KEY_INFO; 163f5b1c8a1SJohn Marino 164f5b1c8a1SJohn Marino typedef struct v3_ext_ctx X509V3_CTX; 165f5b1c8a1SJohn Marino typedef struct conf_st CONF; 166f5b1c8a1SJohn Marino 167f5b1c8a1SJohn Marino typedef struct store_st STORE; 168f5b1c8a1SJohn Marino typedef struct store_method_st STORE_METHOD; 169f5b1c8a1SJohn Marino 170f5b1c8a1SJohn Marino typedef struct ui_st UI; 171f5b1c8a1SJohn Marino typedef struct ui_method_st UI_METHOD; 172f5b1c8a1SJohn Marino 173f5b1c8a1SJohn Marino typedef struct st_ERR_FNS ERR_FNS; 174f5b1c8a1SJohn Marino 175f5b1c8a1SJohn Marino typedef struct engine_st ENGINE; 176f5b1c8a1SJohn Marino typedef struct ssl_st SSL; 177f5b1c8a1SJohn Marino typedef struct ssl_ctx_st SSL_CTX; 178f5b1c8a1SJohn Marino 179f5b1c8a1SJohn Marino typedef struct X509_POLICY_NODE_st X509_POLICY_NODE; 180f5b1c8a1SJohn Marino typedef struct X509_POLICY_LEVEL_st X509_POLICY_LEVEL; 181f5b1c8a1SJohn Marino typedef struct X509_POLICY_TREE_st X509_POLICY_TREE; 182f5b1c8a1SJohn Marino typedef struct X509_POLICY_CACHE_st X509_POLICY_CACHE; 183f5b1c8a1SJohn Marino 184f5b1c8a1SJohn Marino typedef struct AUTHORITY_KEYID_st AUTHORITY_KEYID; 185f5b1c8a1SJohn Marino typedef struct DIST_POINT_st DIST_POINT; 186f5b1c8a1SJohn Marino typedef struct ISSUING_DIST_POINT_st ISSUING_DIST_POINT; 187f5b1c8a1SJohn Marino typedef struct NAME_CONSTRAINTS_st NAME_CONSTRAINTS; 188f5b1c8a1SJohn Marino 189f5b1c8a1SJohn Marino /* If placed in pkcs12.h, we end up with a circular depency with pkcs7.h */ 190f5b1c8a1SJohn Marino #define DECLARE_PKCS12_STACK_OF(type) /* Nothing */ 191f5b1c8a1SJohn Marino #define IMPLEMENT_PKCS12_STACK_OF(type) /* Nothing */ 192f5b1c8a1SJohn Marino 193f5b1c8a1SJohn Marino typedef struct crypto_ex_data_st CRYPTO_EX_DATA; 194f5b1c8a1SJohn Marino /* Callback types for crypto.h */ 195f5b1c8a1SJohn Marino typedef int CRYPTO_EX_new(void *parent, void *ptr, CRYPTO_EX_DATA *ad, 196f5b1c8a1SJohn Marino int idx, long argl, void *argp); 197f5b1c8a1SJohn Marino typedef void CRYPTO_EX_free(void *parent, void *ptr, CRYPTO_EX_DATA *ad, 198f5b1c8a1SJohn Marino int idx, long argl, void *argp); 199f5b1c8a1SJohn Marino typedef int CRYPTO_EX_dup(CRYPTO_EX_DATA *to, CRYPTO_EX_DATA *from, 200f5b1c8a1SJohn Marino void *from_d, int idx, long argl, void *argp); 201f5b1c8a1SJohn Marino 202f5b1c8a1SJohn Marino typedef struct ocsp_req_ctx_st OCSP_REQ_CTX; 203f5b1c8a1SJohn Marino typedef struct ocsp_response_st OCSP_RESPONSE; 204f5b1c8a1SJohn Marino typedef struct ocsp_responder_id_st OCSP_RESPID; 205f5b1c8a1SJohn Marino 206*de0e0e4dSAntonio Huete Jimenez typedef struct sct_st SCT; 207*de0e0e4dSAntonio Huete Jimenez typedef struct sct_ctx_st SCT_CTX; 208*de0e0e4dSAntonio Huete Jimenez typedef struct ctlog_st CTLOG; 209*de0e0e4dSAntonio Huete Jimenez typedef struct ctlog_store_st CTLOG_STORE; 210*de0e0e4dSAntonio Huete Jimenez typedef struct ct_policy_eval_ctx_st CT_POLICY_EVAL_CTX; 211*de0e0e4dSAntonio Huete Jimenez 212f5b1c8a1SJohn Marino #endif /* def HEADER_OPENSSL_TYPES_H */ 213