diff options
-rw-r--r-- | crypto/asn1/a_int.c | 2 | ||||
-rw-r--r-- | crypto/asn1/a_object.c | 2 | ||||
-rw-r--r-- | crypto/asn1/a_strnid.c | 2 | ||||
-rw-r--r-- | crypto/asn1/a_type.c | 2 | ||||
-rw-r--r-- | crypto/asn1/asn_mime.c | 2 | ||||
-rw-r--r-- | crypto/asn1/x_algor.c | 2 | ||||
-rw-r--r-- | crypto/asn1/x_crl.c | 4 | ||||
-rw-r--r-- | crypto/asn1/x_info.c | 2 | ||||
-rw-r--r-- | crypto/asn1/x_name.c | 2 | ||||
-rw-r--r-- | crypto/bio/bio_lib.c | 2 | ||||
-rw-r--r-- | crypto/conf/conf_api.c | 2 | ||||
-rw-r--r-- | crypto/ex_data.c | 2 | ||||
-rw-r--r-- | crypto/objects/o_names.c | 1 | ||||
-rw-r--r-- | crypto/stack/safestack.h | 163 | ||||
-rw-r--r-- | crypto/store/str_lib.c | 2 | ||||
-rw-r--r-- | crypto/ui/ui_lib.c | 2 | ||||
-rw-r--r-- | crypto/x509/x509_ext.c | 2 | ||||
-rw-r--r-- | crypto/x509/x509_lu.c | 4 | ||||
-rw-r--r-- | crypto/x509/x509_trs.c | 2 | ||||
-rw-r--r-- | crypto/x509/x509_vfy.c | 6 | ||||
-rw-r--r-- | crypto/x509v3/v3_cpols.c | 5 | ||||
-rw-r--r-- | crypto/x509v3/v3_crld.c | 2 | ||||
-rw-r--r-- | crypto/x509v3/v3_lib.c | 2 | ||||
-rw-r--r-- | crypto/x509v3/v3_purp.c | 2 | ||||
-rw-r--r-- | crypto/x509v3/v3_sxnet.c | 2 | ||||
-rw-r--r-- | ssl/ssl_lib.c | 4 | ||||
-rwxr-xr-x | util/mkstack.pl | 534 |
27 files changed, 516 insertions, 243 deletions
diff --git a/crypto/asn1/a_int.c b/crypto/asn1/a_int.c index 024115bdf5..6b6a5143c8 100644 --- a/crypto/asn1/a_int.c +++ b/crypto/asn1/a_int.c @@ -455,6 +455,4 @@ BIGNUM *ASN1_INTEGER_to_BN(const ASN1_INTEGER *ai, BIGNUM *bn) return (ret); } -IMPLEMENT_STACK_OF(ASN1_INTEGER) - IMPLEMENT_ASN1_SET_OF(ASN1_INTEGER) diff --git a/crypto/asn1/a_object.c b/crypto/asn1/a_object.c index 99abf688fb..5732a71547 100644 --- a/crypto/asn1/a_object.c +++ b/crypto/asn1/a_object.c @@ -400,6 +400,4 @@ ASN1_OBJECT *ASN1_OBJECT_create(int nid, unsigned char *data, int len, return (OBJ_dup(&o)); } -IMPLEMENT_STACK_OF(ASN1_OBJECT) - IMPLEMENT_ASN1_SET_OF(ASN1_OBJECT) diff --git a/crypto/asn1/a_strnid.c b/crypto/asn1/a_strnid.c index ab446b15d2..213cf63e59 100644 --- a/crypto/asn1/a_strnid.c +++ b/crypto/asn1/a_strnid.c @@ -302,8 +302,6 @@ static void st_free(ASN1_STRING_TABLE *tbl) } -IMPLEMENT_STACK_OF(ASN1_STRING_TABLE) - #ifdef STRING_TABLE_TEST main() diff --git a/crypto/asn1/a_type.c b/crypto/asn1/a_type.c index 4a36aff6ac..94d0b1ab5f 100644 --- a/crypto/asn1/a_type.c +++ b/crypto/asn1/a_type.c @@ -103,8 +103,6 @@ int ASN1_TYPE_set1(ASN1_TYPE *a, int type, const void *value) return 1; } -IMPLEMENT_STACK_OF(ASN1_TYPE) - IMPLEMENT_ASN1_SET_OF(ASN1_TYPE) /* Returns 0 if they are equal, != 0 otherwise. */ diff --git a/crypto/asn1/asn_mime.c b/crypto/asn1/asn_mime.c index 97e5b34579..28622f2815 100644 --- a/crypto/asn1/asn_mime.c +++ b/crypto/asn1/asn_mime.c @@ -78,7 +78,6 @@ typedef struct { } MIME_PARAM; DECLARE_STACK_OF(MIME_PARAM) -IMPLEMENT_STACK_OF(MIME_PARAM) typedef struct { char *name; /* Name of line e.g. "content-type" */ @@ -87,7 +86,6 @@ typedef struct { } MIME_HEADER; DECLARE_STACK_OF(MIME_HEADER) -IMPLEMENT_STACK_OF(MIME_HEADER) static int asn1_output_data(BIO *out, BIO *data, ASN1_VALUE *val, int flags, const ASN1_ITEM *it); diff --git a/crypto/asn1/x_algor.c b/crypto/asn1/x_algor.c index fd7d16d404..f7ff57387d 100644 --- a/crypto/asn1/x_algor.c +++ b/crypto/asn1/x_algor.c @@ -74,8 +74,6 @@ ASN1_ITEM_TEMPLATE_END(X509_ALGORS) IMPLEMENT_ASN1_FUNCTIONS(X509_ALGOR) IMPLEMENT_ASN1_ENCODE_FUNCTIONS_fname(X509_ALGORS, X509_ALGORS, X509_ALGORS) IMPLEMENT_ASN1_DUP_FUNCTION(X509_ALGOR) - -IMPLEMENT_STACK_OF(X509_ALGOR) IMPLEMENT_ASN1_SET_OF(X509_ALGOR) int X509_ALGOR_set0(X509_ALGOR *alg, ASN1_OBJECT *aobj, int ptype, void *pval) diff --git a/crypto/asn1/x_crl.c b/crypto/asn1/x_crl.c index 79eab4f398..bcbae1b32b 100644 --- a/crypto/asn1/x_crl.c +++ b/crypto/asn1/x_crl.c @@ -506,10 +506,6 @@ void *X509_CRL_get_meth_data(X509_CRL *crl) return crl->meth_data; } -IMPLEMENT_STACK_OF(X509_REVOKED) - IMPLEMENT_ASN1_SET_OF(X509_REVOKED) -IMPLEMENT_STACK_OF(X509_CRL) - IMPLEMENT_ASN1_SET_OF(X509_CRL) diff --git a/crypto/asn1/x_info.c b/crypto/asn1/x_info.c index 067fd72a6e..a847277b49 100644 --- a/crypto/asn1/x_info.c +++ b/crypto/asn1/x_info.c @@ -113,5 +113,3 @@ void X509_INFO_free(X509_INFO *x) OPENSSL_free(x->enc_data); OPENSSL_free(x); } - -IMPLEMENT_STACK_OF(X509_INFO) diff --git a/crypto/asn1/x_name.c b/crypto/asn1/x_name.c index 737c426f2d..bc446e0005 100644 --- a/crypto/asn1/x_name.c +++ b/crypto/asn1/x_name.c @@ -522,6 +522,4 @@ int X509_NAME_set(X509_NAME **xn, X509_NAME *name) return (*xn != NULL); } -IMPLEMENT_STACK_OF(X509_NAME_ENTRY) - IMPLEMENT_ASN1_SET_OF(X509_NAME_ENTRY) diff --git a/crypto/bio/bio_lib.c b/crypto/bio/bio_lib.c index 5267010cb0..11e0142de8 100644 --- a/crypto/bio/bio_lib.c +++ b/crypto/bio/bio_lib.c @@ -590,5 +590,3 @@ unsigned long BIO_number_written(BIO *bio) return bio->num_write; return 0; } - -IMPLEMENT_STACK_OF(BIO) diff --git a/crypto/conf/conf_api.c b/crypto/conf/conf_api.c index ff73f3822f..cba2de199b 100644 --- a/crypto/conf/conf_api.c +++ b/crypto/conf/conf_api.c @@ -279,5 +279,3 @@ CONF_VALUE *_CONF_new_section(CONF *conf, const char *section) } return (v); } - -IMPLEMENT_STACK_OF(CONF_VALUE) diff --git a/crypto/ex_data.c b/crypto/ex_data.c index 5a3546a2d2..4caddcebb4 100644 --- a/crypto/ex_data.c +++ b/crypto/ex_data.c @@ -640,5 +640,3 @@ void *CRYPTO_get_ex_data(const CRYPTO_EX_DATA *ad, int idx) else return (sk_void_value(ad->sk, idx)); } - -IMPLEMENT_STACK_OF(CRYPTO_EX_DATA_FUNCS) diff --git a/crypto/objects/o_names.c b/crypto/objects/o_names.c index e1e13a6131..d7fa0d853d 100644 --- a/crypto/objects/o_names.c +++ b/crypto/objects/o_names.c @@ -35,7 +35,6 @@ typedef struct name_funcs_st { } NAME_FUNCS; DECLARE_STACK_OF(NAME_FUNCS) -IMPLEMENT_STACK_OF(NAME_FUNCS) static STACK_OF(NAME_FUNCS) *name_funcs_stack; diff --git a/crypto/stack/safestack.h b/crypto/stack/safestack.h index aa2e9939e8..bd0397d5e9 100644 --- a/crypto/stack/safestack.h +++ b/crypto/stack/safestack.h @@ -1,3 +1,4 @@ +/* automatically generated by util/mkstack.pl */ /* ==================================================================== * Copyright (c) 1999 The OpenSSL Project. All rights reserved. * @@ -62,8 +63,7 @@ extern "C" { #endif # ifndef CHECKED_PTR_OF -# define CHECKED_PTR_OF(type, p) \ - ((void*) (1 ? p : (type*)0)) +# define CHECKED_PTR_OF(type, p) ((void*) (1 ? p : (type*)0)) # endif /* @@ -99,9 +99,6 @@ STACK_OF(type) \ _STACK stack; \ }; -/* nada (obsolete in new safestack approach)*/ -# define IMPLEMENT_STACK_OF(type) - /*- * Strings are special: normally an lhash entry will point to a single * (somewhat) mutable object. In the case of strings: @@ -117,17 +114,15 @@ STACK_OF(type) \ * string at all. */ typedef char *OPENSSL_STRING; - typedef const char *OPENSSL_CSTRING; -/* +/*- * Confusingly, LHASH_OF(STRING) deals with char ** throughout, but * STACK_OF(STRING) is really more like STACK_OF(char), only, as mentioned * above, instead of a single char each entry is a NUL-terminated array of * chars. So, we have to implement STRING specially for STACK_OF. This is * dealt with in the autogenerated macros below. */ - DECLARE_SPECIAL_STACK_OF(OPENSSL_STRING, char) /* @@ -138,6 +133,11 @@ typedef void *OPENSSL_BLOCK; DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) /* + * This file is automatically generated by util/mkstack.pl + * Do not edit! + */ + +/* * SKM_sk_... stack macros are internal to safestack.h: never use them * directly, use sk_<type>_... instead */ @@ -187,6 +187,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) sk_sort(CHECKED_STACK_OF(type, st)) # define SKM_sk_is_sorted(type, st) \ sk_is_sorted(CHECKED_STACK_OF(type, st)) + # define SKM_ASN1_SET_OF_d2i(type, st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ (STACK_OF(type) *)d2i_ASN1_SET( \ (STACK_OF(OPENSSL_BLOCK) **)CHECKED_PTR_OF(STACK_OF(type)*, st), \ @@ -198,19 +199,20 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) i2d_ASN1_SET(CHECKED_STACK_OF(type, st), pp, \ CHECKED_I2D_OF(type, i2d_func), \ ex_tag, ex_class, is_set) + # define SKM_ASN1_seq_pack(type, st, i2d_func, buf, len) \ ASN1_seq_pack(CHECKED_PTR_OF(STACK_OF(type), st), \ CHECKED_I2D_OF(type, i2d_func), buf, len) # define SKM_ASN1_seq_unpack(type, buf, len, d2i_func, free_func) \ - (STACK_OF(type) *)ASN1_seq_unpack(buf, len, CHECKED_D2I_OF(type, d2i_func), CHECKED_SK_FREE_FUNC(type, free_func)) + (STACK_OF(type) *)ASN1_seq_unpack(buf, \ + len, CHECKED_D2I_OF(type, d2i_func), \ + CHECKED_SK_FREE_FUNC(type, free_func)) # define SKM_PKCS12_decrypt_d2i(type, algor, d2i_func, free_func, pass, passlen, oct, seq) \ (STACK_OF(type) *)PKCS12_decrypt_d2i(algor, \ CHECKED_D2I_OF(type, d2i_func), \ CHECKED_SK_FREE_FUNC(type, free_func), \ pass, passlen, oct, seq) -/* - * This block of defines is updated by util/mkstack.pl, please do not touch! - */ + # define sk_ACCESS_DESCRIPTION_new(cmp) SKM_sk_new(ACCESS_DESCRIPTION, (cmp)) # define sk_ACCESS_DESCRIPTION_new_null() SKM_sk_new_null(ACCESS_DESCRIPTION) # define sk_ACCESS_DESCRIPTION_free(st) SKM_sk_free(ACCESS_DESCRIPTION, (st)) @@ -233,6 +235,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ACCESS_DESCRIPTION_pop(st) SKM_sk_pop(ACCESS_DESCRIPTION, (st)) # define sk_ACCESS_DESCRIPTION_sort(st) SKM_sk_sort(ACCESS_DESCRIPTION, (st)) # define sk_ACCESS_DESCRIPTION_is_sorted(st) SKM_sk_is_sorted(ACCESS_DESCRIPTION, (st)) + # define sk_ASIdOrRange_new(cmp) SKM_sk_new(ASIdOrRange, (cmp)) # define sk_ASIdOrRange_new_null() SKM_sk_new_null(ASIdOrRange) # define sk_ASIdOrRange_free(st) SKM_sk_free(ASIdOrRange, (st)) @@ -255,6 +258,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASIdOrRange_pop(st) SKM_sk_pop(ASIdOrRange, (st)) # define sk_ASIdOrRange_sort(st) SKM_sk_sort(ASIdOrRange, (st)) # define sk_ASIdOrRange_is_sorted(st) SKM_sk_is_sorted(ASIdOrRange, (st)) + # define sk_ASN1_GENERALSTRING_new(cmp) SKM_sk_new(ASN1_GENERALSTRING, (cmp)) # define sk_ASN1_GENERALSTRING_new_null() SKM_sk_new_null(ASN1_GENERALSTRING) # define sk_ASN1_GENERALSTRING_free(st) SKM_sk_free(ASN1_GENERALSTRING, (st)) @@ -277,6 +281,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_GENERALSTRING_pop(st) SKM_sk_pop(ASN1_GENERALSTRING, (st)) # define sk_ASN1_GENERALSTRING_sort(st) SKM_sk_sort(ASN1_GENERALSTRING, (st)) # define sk_ASN1_GENERALSTRING_is_sorted(st) SKM_sk_is_sorted(ASN1_GENERALSTRING, (st)) + # define sk_ASN1_INTEGER_new(cmp) SKM_sk_new(ASN1_INTEGER, (cmp)) # define sk_ASN1_INTEGER_new_null() SKM_sk_new_null(ASN1_INTEGER) # define sk_ASN1_INTEGER_free(st) SKM_sk_free(ASN1_INTEGER, (st)) @@ -299,6 +304,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_INTEGER_pop(st) SKM_sk_pop(ASN1_INTEGER, (st)) # define sk_ASN1_INTEGER_sort(st) SKM_sk_sort(ASN1_INTEGER, (st)) # define sk_ASN1_INTEGER_is_sorted(st) SKM_sk_is_sorted(ASN1_INTEGER, (st)) + # define sk_ASN1_OBJECT_new(cmp) SKM_sk_new(ASN1_OBJECT, (cmp)) # define sk_ASN1_OBJECT_new_null() SKM_sk_new_null(ASN1_OBJECT) # define sk_ASN1_OBJECT_free(st) SKM_sk_free(ASN1_OBJECT, (st)) @@ -321,6 +327,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_OBJECT_pop(st) SKM_sk_pop(ASN1_OBJECT, (st)) # define sk_ASN1_OBJECT_sort(st) SKM_sk_sort(ASN1_OBJECT, (st)) # define sk_ASN1_OBJECT_is_sorted(st) SKM_sk_is_sorted(ASN1_OBJECT, (st)) + # define sk_ASN1_STRING_TABLE_new(cmp) SKM_sk_new(ASN1_STRING_TABLE, (cmp)) # define sk_ASN1_STRING_TABLE_new_null() SKM_sk_new_null(ASN1_STRING_TABLE) # define sk_ASN1_STRING_TABLE_free(st) SKM_sk_free(ASN1_STRING_TABLE, (st)) @@ -343,6 +350,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_STRING_TABLE_pop(st) SKM_sk_pop(ASN1_STRING_TABLE, (st)) # define sk_ASN1_STRING_TABLE_sort(st) SKM_sk_sort(ASN1_STRING_TABLE, (st)) # define sk_ASN1_STRING_TABLE_is_sorted(st) SKM_sk_is_sorted(ASN1_STRING_TABLE, (st)) + # define sk_ASN1_TYPE_new(cmp) SKM_sk_new(ASN1_TYPE, (cmp)) # define sk_ASN1_TYPE_new_null() SKM_sk_new_null(ASN1_TYPE) # define sk_ASN1_TYPE_free(st) SKM_sk_free(ASN1_TYPE, (st)) @@ -365,6 +373,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_TYPE_pop(st) SKM_sk_pop(ASN1_TYPE, (st)) # define sk_ASN1_TYPE_sort(st) SKM_sk_sort(ASN1_TYPE, (st)) # define sk_ASN1_TYPE_is_sorted(st) SKM_sk_is_sorted(ASN1_TYPE, (st)) + # define sk_ASN1_UTF8STRING_new(cmp) SKM_sk_new(ASN1_UTF8STRING, (cmp)) # define sk_ASN1_UTF8STRING_new_null() SKM_sk_new_null(ASN1_UTF8STRING) # define sk_ASN1_UTF8STRING_free(st) SKM_sk_free(ASN1_UTF8STRING, (st)) @@ -387,6 +396,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_UTF8STRING_pop(st) SKM_sk_pop(ASN1_UTF8STRING, (st)) # define sk_ASN1_UTF8STRING_sort(st) SKM_sk_sort(ASN1_UTF8STRING, (st)) # define sk_ASN1_UTF8STRING_is_sorted(st) SKM_sk_is_sorted(ASN1_UTF8STRING, (st)) + # define sk_ASN1_VALUE_new(cmp) SKM_sk_new(ASN1_VALUE, (cmp)) # define sk_ASN1_VALUE_new_null() SKM_sk_new_null(ASN1_VALUE) # define sk_ASN1_VALUE_free(st) SKM_sk_free(ASN1_VALUE, (st)) @@ -409,6 +419,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ASN1_VALUE_pop(st) SKM_sk_pop(ASN1_VALUE, (st)) # define sk_ASN1_VALUE_sort(st) SKM_sk_sort(ASN1_VALUE, (st)) # define sk_ASN1_VALUE_is_sorted(st) SKM_sk_is_sorted(ASN1_VALUE, (st)) + # define sk_BIO_new(cmp) SKM_sk_new(BIO, (cmp)) # define sk_BIO_new_null() SKM_sk_new_null(BIO) # define sk_BIO_free(st) SKM_sk_free(BIO, (st)) @@ -431,6 +442,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_BIO_pop(st) SKM_sk_pop(BIO, (st)) # define sk_BIO_sort(st) SKM_sk_sort(BIO, (st)) # define sk_BIO_is_sorted(st) SKM_sk_is_sorted(BIO, (st)) + # define sk_BY_DIR_ENTRY_new(cmp) SKM_sk_new(BY_DIR_ENTRY, (cmp)) # define sk_BY_DIR_ENTRY_new_null() SKM_sk_new_null(BY_DIR_ENTRY) # define sk_BY_DIR_ENTRY_free(st) SKM_sk_free(BY_DIR_ENTRY, (st)) @@ -453,6 +465,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_BY_DIR_ENTRY_pop(st) SKM_sk_pop(BY_DIR_ENTRY, (st)) # define sk_BY_DIR_ENTRY_sort(st) SKM_sk_sort(BY_DIR_ENTRY, (st)) # define sk_BY_DIR_ENTRY_is_sorted(st) SKM_sk_is_sorted(BY_DIR_ENTRY, (st)) + # define sk_BY_DIR_HASH_new(cmp) SKM_sk_new(BY_DIR_HASH, (cmp)) # define sk_BY_DIR_HASH_new_null() SKM_sk_new_null(BY_DIR_HASH) # define sk_BY_DIR_HASH_free(st) SKM_sk_free(BY_DIR_HASH, (st)) @@ -475,6 +488,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_BY_DIR_HASH_pop(st) SKM_sk_pop(BY_DIR_HASH, (st)) # define sk_BY_DIR_HASH_sort(st) SKM_sk_sort(BY_DIR_HASH, (st)) # define sk_BY_DIR_HASH_is_sorted(st) SKM_sk_is_sorted(BY_DIR_HASH, (st)) + # define sk_CMS_CertificateChoices_new(cmp) SKM_sk_new(CMS_CertificateChoices, (cmp)) # define sk_CMS_CertificateChoices_new_null() SKM_sk_new_null(CMS_CertificateChoices) # define sk_CMS_CertificateChoices_free(st) SKM_sk_free(CMS_CertificateChoices, (st)) @@ -497,6 +511,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CMS_CertificateChoices_pop(st) SKM_sk_pop(CMS_CertificateChoices, (st)) # define sk_CMS_CertificateChoices_sort(st) SKM_sk_sort(CMS_CertificateChoices, (st)) # define sk_CMS_CertificateChoices_is_sorted(st) SKM_sk_is_sorted(CMS_CertificateChoices, (st)) + # define sk_CMS_RecipientEncryptedKey_new(cmp) SKM_sk_new(CMS_RecipientEncryptedKey, (cmp)) # define sk_CMS_RecipientEncryptedKey_new_null() SKM_sk_new_null(CMS_RecipientEncryptedKey) # define sk_CMS_RecipientEncryptedKey_free(st) SKM_sk_free(CMS_RecipientEncryptedKey, (st)) @@ -519,6 +534,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CMS_RecipientEncryptedKey_pop(st) SKM_sk_pop(CMS_RecipientEncryptedKey, (st)) # define sk_CMS_RecipientEncryptedKey_sort(st) SKM_sk_sort(CMS_RecipientEncryptedKey, (st)) # define sk_CMS_RecipientEncryptedKey_is_sorted(st) SKM_sk_is_sorted(CMS_RecipientEncryptedKey, (st)) + # define sk_CMS_RecipientInfo_new(cmp) SKM_sk_new(CMS_RecipientInfo, (cmp)) # define sk_CMS_RecipientInfo_new_null() SKM_sk_new_null(CMS_RecipientInfo) # define sk_CMS_RecipientInfo_free(st) SKM_sk_free(CMS_RecipientInfo, (st)) @@ -541,6 +557,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CMS_RecipientInfo_pop(st) SKM_sk_pop(CMS_RecipientInfo, (st)) # define sk_CMS_RecipientInfo_sort(st) SKM_sk_sort(CMS_RecipientInfo, (st)) # define sk_CMS_RecipientInfo_is_sorted(st) SKM_sk_is_sorted(CMS_RecipientInfo, (st)) + # define sk_CMS_RevocationInfoChoice_new(cmp) SKM_sk_new(CMS_RevocationInfoChoice, (cmp)) # define sk_CMS_RevocationInfoChoice_new_null() SKM_sk_new_null(CMS_RevocationInfoChoice) # define sk_CMS_RevocationInfoChoice_free(st) SKM_sk_free(CMS_RevocationInfoChoice, (st)) @@ -563,6 +580,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CMS_RevocationInfoChoice_pop(st) SKM_sk_pop(CMS_RevocationInfoChoice, (st)) # define sk_CMS_RevocationInfoChoice_sort(st) SKM_sk_sort(CMS_RevocationInfoChoice, (st)) # define sk_CMS_RevocationInfoChoice_is_sorted(st) SKM_sk_is_sorted(CMS_RevocationInfoChoice, (st)) + # define sk_CMS_SignerInfo_new(cmp) SKM_sk_new(CMS_SignerInfo, (cmp)) # define sk_CMS_SignerInfo_new_null() SKM_sk_new_null(CMS_SignerInfo) # define sk_CMS_SignerInfo_free(st) SKM_sk_free(CMS_SignerInfo, (st)) @@ -585,6 +603,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CMS_SignerInfo_pop(st) SKM_sk_pop(CMS_SignerInfo, (st)) # define sk_CMS_SignerInfo_sort(st) SKM_sk_sort(CMS_SignerInfo, (st)) # define sk_CMS_SignerInfo_is_sorted(st) SKM_sk_is_sorted(CMS_SignerInfo, (st)) + # define sk_CONF_IMODULE_new(cmp) SKM_sk_new(CONF_IMODULE, (cmp)) # define sk_CONF_IMODULE_new_null() SKM_sk_new_null(CONF_IMODULE) # define sk_CONF_IMODULE_free(st) SKM_sk_free(CONF_IMODULE, (st)) @@ -607,6 +626,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CONF_IMODULE_pop(st) SKM_sk_pop(CONF_IMODULE, (st)) # define sk_CONF_IMODULE_sort(st) SKM_sk_sort(CONF_IMODULE, (st)) # define sk_CONF_IMODULE_is_sorted(st) SKM_sk_is_sorted(CONF_IMODULE, (st)) + # define sk_CONF_MODULE_new(cmp) SKM_sk_new(CONF_MODULE, (cmp)) # define sk_CONF_MODULE_new_null() SKM_sk_new_null(CONF_MODULE) # define sk_CONF_MODULE_free(st) SKM_sk_free(CONF_MODULE, (st)) @@ -629,6 +649,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CONF_MODULE_pop(st) SKM_sk_pop(CONF_MODULE, (st)) # define sk_CONF_MODULE_sort(st) SKM_sk_sort(CONF_MODULE, (st)) # define sk_CONF_MODULE_is_sorted(st) SKM_sk_is_sorted(CONF_MODULE, (st)) + # define sk_CONF_VALUE_new(cmp) SKM_sk_new(CONF_VALUE, (cmp)) # define sk_CONF_VALUE_new_null() SKM_sk_new_null(CONF_VALUE) # define sk_CONF_VALUE_free(st) SKM_sk_free(CONF_VALUE, (st)) @@ -651,6 +672,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CONF_VALUE_pop(st) SKM_sk_pop(CONF_VALUE, (st)) # define sk_CONF_VALUE_sort(st) SKM_sk_sort(CONF_VALUE, (st)) # define sk_CONF_VALUE_is_sorted(st) SKM_sk_is_sorted(CONF_VALUE, (st)) + # define sk_CRYPTO_EX_DATA_FUNCS_new(cmp) SKM_sk_new(CRYPTO_EX_DATA_FUNCS, (cmp)) # define sk_CRYPTO_EX_DATA_FUNCS_new_null() SKM_sk_new_null(CRYPTO_EX_DATA_FUNCS) # define sk_CRYPTO_EX_DATA_FUNCS_free(st) SKM_sk_free(CRYPTO_EX_DATA_FUNCS, (st)) @@ -673,6 +695,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CRYPTO_EX_DATA_FUNCS_pop(st) SKM_sk_pop(CRYPTO_EX_DATA_FUNCS, (st)) # define sk_CRYPTO_EX_DATA_FUNCS_sort(st) SKM_sk_sort(CRYPTO_EX_DATA_FUNCS, (st)) # define sk_CRYPTO_EX_DATA_FUNCS_is_sorted(st) SKM_sk_is_sorted(CRYPTO_EX_DATA_FUNCS, (st)) + # define sk_CRYPTO_dynlock_new(cmp) SKM_sk_new(CRYPTO_dynlock, (cmp)) # define sk_CRYPTO_dynlock_new_null() SKM_sk_new_null(CRYPTO_dynlock) # define sk_CRYPTO_dynlock_free(st) SKM_sk_free(CRYPTO_dynlock, (st)) @@ -695,6 +718,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_CRYPTO_dynlock_pop(st) SKM_sk_pop(CRYPTO_dynlock, (st)) # define sk_CRYPTO_dynlock_sort(st) SKM_sk_sort(CRYPTO_dynlock, (st)) # define sk_CRYPTO_dynlock_is_sorted(st) SKM_sk_is_sorted(CRYPTO_dynlock, (st)) + # define sk_DIST_POINT_new(cmp) SKM_sk_new(DIST_POINT, (cmp)) # define sk_DIST_POINT_new_null() SKM_sk_new_null(DIST_POINT) # define sk_DIST_POINT_free(st) SKM_sk_free(DIST_POINT, (st)) @@ -717,6 +741,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_DIST_POINT_pop(st) SKM_sk_pop(DIST_POINT, (st)) # define sk_DIST_POINT_sort(st) SKM_sk_sort(DIST_POINT, (st)) # define sk_DIST_POINT_is_sorted(st) SKM_sk_is_sorted(DIST_POINT, (st)) + # define sk_ENGINE_new(cmp) SKM_sk_new(ENGINE, (cmp)) # define sk_ENGINE_new_null() SKM_sk_new_null(ENGINE) # define sk_ENGINE_free(st) SKM_sk_free(ENGINE, (st)) @@ -739,6 +764,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ENGINE_pop(st) SKM_sk_pop(ENGINE, (st)) # define sk_ENGINE_sort(st) SKM_sk_sort(ENGINE, (st)) # define sk_ENGINE_is_sorted(st) SKM_sk_is_sorted(ENGINE, (st)) + # define sk_ENGINE_CLEANUP_ITEM_new(cmp) SKM_sk_new(ENGINE_CLEANUP_ITEM, (cmp)) # define sk_ENGINE_CLEANUP_ITEM_new_null() SKM_sk_new_null(ENGINE_CLEANUP_ITEM) # define sk_ENGINE_CLEANUP_ITEM_free(st) SKM_sk_free(ENGINE_CLEANUP_ITEM, (st)) @@ -761,6 +787,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ENGINE_CLEANUP_ITEM_pop(st) SKM_sk_pop(ENGINE_CLEANUP_ITEM, (st)) # define sk_ENGINE_CLEANUP_ITEM_sort(st) SKM_sk_sort(ENGINE_CLEANUP_ITEM, (st)) # define sk_ENGINE_CLEANUP_ITEM_is_sorted(st) SKM_sk_is_sorted(ENGINE_CLEANUP_ITEM, (st)) + # define sk_ESS_CERT_ID_new(cmp) SKM_sk_new(ESS_CERT_ID, (cmp)) # define sk_ESS_CERT_ID_new_null() SKM_sk_new_null(ESS_CERT_ID) # define sk_ESS_CERT_ID_free(st) SKM_sk_free(ESS_CERT_ID, (st)) @@ -783,6 +810,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_ESS_CERT_ID_pop(st) SKM_sk_pop(ESS_CERT_ID, (st)) # define sk_ESS_CERT_ID_sort(st) SKM_sk_sort(ESS_CERT_ID, (st)) # define sk_ESS_CERT_ID_is_sorted(st) SKM_sk_is_sorted(ESS_CERT_ID, (st)) + # define sk_EVP_MD_new(cmp) SKM_sk_new(EVP_MD, (cmp)) # define sk_EVP_MD_new_null() SKM_sk_new_null(EVP_MD) # define sk_EVP_MD_free(st) SKM_sk_free(EVP_MD, (st)) @@ -805,6 +833,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_EVP_MD_pop(st) SKM_sk_pop(EVP_MD, (st)) # define sk_EVP_MD_sort(st) SKM_sk_sort(EVP_MD, (st)) # define sk_EVP_MD_is_sorted(st) SKM_sk_is_sorted(EVP_MD, (st)) + # define sk_EVP_PBE_CTL_new(cmp) SKM_sk_new(EVP_PBE_CTL, (cmp)) # define sk_EVP_PBE_CTL_new_null() SKM_sk_new_null(EVP_PBE_CTL) # define sk_EVP_PBE_CTL_free(st) SKM_sk_free(EVP_PBE_CTL, (st)) @@ -827,6 +856,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_EVP_PBE_CTL_pop(st) SKM_sk_pop(EVP_PBE_CTL, (st)) # define sk_EVP_PBE_CTL_sort(st) SKM_sk_sort(EVP_PBE_CTL, (st)) # define sk_EVP_PBE_CTL_is_sorted(st) SKM_sk_is_sorted(EVP_PBE_CTL, (st)) + # define sk_EVP_PKEY_ASN1_METHOD_new(cmp) SKM_sk_new(EVP_PKEY_ASN1_METHOD, (cmp)) # define sk_EVP_PKEY_ASN1_METHOD_new_null() SKM_sk_new_null(EVP_PKEY_ASN1_METHOD) # define sk_EVP_PKEY_ASN1_METHOD_free(st) SKM_sk_free(EVP_PKEY_ASN1_METHOD, (st)) @@ -849,6 +879,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_EVP_PKEY_ASN1_METHOD_pop(st) SKM_sk_pop(EVP_PKEY_ASN1_METHOD, (st)) # define sk_EVP_PKEY_ASN1_METHOD_sort(st) SKM_sk_sort(EVP_PKEY_ASN1_METHOD, (st)) # define sk_EVP_PKEY_ASN1_METHOD_is_sorted(st) SKM_sk_is_sorted(EVP_PKEY_ASN1_METHOD, (st)) + # define sk_EVP_PKEY_METHOD_new(cmp) SKM_sk_new(EVP_PKEY_METHOD, (cmp)) # define sk_EVP_PKEY_METHOD_new_null() SKM_sk_new_null(EVP_PKEY_METHOD) # define sk_EVP_PKEY_METHOD_free(st) SKM_sk_free(EVP_PKEY_METHOD, (st)) @@ -871,6 +902,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_EVP_PKEY_METHOD_pop(st) SKM_sk_pop(EVP_PKEY_METHOD, (st)) # define sk_EVP_PKEY_METHOD_sort(st) SKM_sk_sort(EVP_PKEY_METHOD, (st)) # define sk_EVP_PKEY_METHOD_is_sorted(st) SKM_sk_is_sorted(EVP_PKEY_METHOD, (st)) + # define sk_GENERAL_NAME_new(cmp) SKM_sk_new(GENERAL_NAME, (cmp)) # define sk_GENERAL_NAME_new_null() SKM_sk_new_null(GENERAL_NAME) # define sk_GENERAL_NAME_free(st) SKM_sk_free(GENERAL_NAME, (st)) @@ -893,6 +925,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_GENERAL_NAME_pop(st) SKM_sk_pop(GENERAL_NAME, (st)) # define sk_GENERAL_NAME_sort(st) SKM_sk_sort(GENERAL_NAME, (st)) # define sk_GENERAL_NAME_is_sorted(st) SKM_sk_is_sorted(GENERAL_NAME, (st)) + # define sk_GENERAL_NAMES_new(cmp) SKM_sk_new(GENERAL_NAMES, (cmp)) # define sk_GENERAL_NAMES_new_null() SKM_sk_new_null(GENERAL_NAMES) # define sk_GENERAL_NAMES_free(st) SKM_sk_free(GENERAL_NAMES, (st)) @@ -915,6 +948,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_GENERAL_NAMES_pop(st) SKM_sk_pop(GENERAL_NAMES, (st)) # define sk_GENERAL_NAMES_sort(st) SKM_sk_sort(GENERAL_NAMES, (st)) # define sk_GENERAL_NAMES_is_sorted(st) SKM_sk_is_sorted(GENERAL_NAMES, (st)) + # define sk_GENERAL_SUBTREE_new(cmp) SKM_sk_new(GENERAL_SUBTREE, (cmp)) # define sk_GENERAL_SUBTREE_new_null() SKM_sk_new_null(GENERAL_SUBTREE) # define sk_GENERAL_SUBTREE_free(st) SKM_sk_free(GENERAL_SUBTREE, (st)) @@ -937,6 +971,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_GENERAL_SUBTREE_pop(st) SKM_sk_pop(GENERAL_SUBTREE, (st)) # define sk_GENERAL_SUBTREE_sort(st) SKM_sk_sort(GENERAL_SUBTREE, (st)) # define sk_GENERAL_SUBTREE_is_sorted(st) SKM_sk_is_sorted(GENERAL_SUBTREE, (st)) + # define sk_IPAddressFamily_new(cmp) SKM_sk_new(IPAddressFamily, (cmp)) # define sk_IPAddressFamily_new_null() SKM_sk_new_null(IPAddressFamily) # define sk_IPAddressFamily_free(st) SKM_sk_free(IPAddressFamily, (st)) @@ -959,6 +994,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_IPAddressFamily_pop(st) SKM_sk_pop(IPAddressFamily, (st)) # define sk_IPAddressFamily_sort(st) SKM_sk_sort(IPAddressFamily, (st)) # define sk_IPAddressFamily_is_sorted(st) SKM_sk_is_sorted(IPAddressFamily, (st)) + # define sk_IPAddressOrRange_new(cmp) SKM_sk_new(IPAddressOrRange, (cmp)) # define sk_IPAddressOrRange_new_null() SKM_sk_new_null(IPAddressOrRange) # define sk_IPAddressOrRange_free(st) SKM_sk_free(IPAddressOrRange, (st)) @@ -981,6 +1017,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_IPAddressOrRange_pop(st) SKM_sk_pop(IPAddressOrRange, (st)) # define sk_IPAddressOrRange_sort(st) SKM_sk_sort(IPAddressOrRange, (st)) # define sk_IPAddressOrRange_is_sorted(st) SKM_sk_is_sorted(IPAddressOrRange, (st)) + # define sk_KRB5_APREQBODY_new(cmp) SKM_sk_new(KRB5_APREQBODY, (cmp)) # define sk_KRB5_APREQBODY_new_null() SKM_sk_new_null(KRB5_APREQBODY) # define sk_KRB5_APREQBODY_free(st) SKM_sk_free(KRB5_APREQBODY, (st)) @@ -1003,6 +1040,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_APREQBODY_pop(st) SKM_sk_pop(KRB5_APREQBODY, (st)) # define sk_KRB5_APREQBODY_sort(st) SKM_sk_sort(KRB5_APREQBODY, (st)) # define sk_KRB5_APREQBODY_is_sorted(st) SKM_sk_is_sorted(KRB5_APREQBODY, (st)) + # define sk_KRB5_AUTHDATA_new(cmp) SKM_sk_new(KRB5_AUTHDATA, (cmp)) # define sk_KRB5_AUTHDATA_new_null() SKM_sk_new_null(KRB5_AUTHDATA) # define sk_KRB5_AUTHDATA_free(st) SKM_sk_free(KRB5_AUTHDATA, (st)) @@ -1025,6 +1063,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_AUTHDATA_pop(st) SKM_sk_pop(KRB5_AUTHDATA, (st)) # define sk_KRB5_AUTHDATA_sort(st) SKM_sk_sort(KRB5_AUTHDATA, (st)) # define sk_KRB5_AUTHDATA_is_sorted(st) SKM_sk_is_sorted(KRB5_AUTHDATA, (st)) + # define sk_KRB5_AUTHENTBODY_new(cmp) SKM_sk_new(KRB5_AUTHENTBODY, (cmp)) # define sk_KRB5_AUTHENTBODY_new_null() SKM_sk_new_null(KRB5_AUTHENTBODY) # define sk_KRB5_AUTHENTBODY_free(st) SKM_sk_free(KRB5_AUTHENTBODY, (st)) @@ -1047,6 +1086,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_AUTHENTBODY_pop(st) SKM_sk_pop(KRB5_AUTHENTBODY, (st)) # define sk_KRB5_AUTHENTBODY_sort(st) SKM_sk_sort(KRB5_AUTHENTBODY, (st)) # define sk_KRB5_AUTHENTBODY_is_sorted(st) SKM_sk_is_sorted(KRB5_AUTHENTBODY, (st)) + # define sk_KRB5_CHECKSUM_new(cmp) SKM_sk_new(KRB5_CHECKSUM, (cmp)) # define sk_KRB5_CHECKSUM_new_null() SKM_sk_new_null(KRB5_CHECKSUM) # define sk_KRB5_CHECKSUM_free(st) SKM_sk_free(KRB5_CHECKSUM, (st)) @@ -1069,6 +1109,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_CHECKSUM_pop(st) SKM_sk_pop(KRB5_CHECKSUM, (st)) # define sk_KRB5_CHECKSUM_sort(st) SKM_sk_sort(KRB5_CHECKSUM, (st)) # define sk_KRB5_CHECKSUM_is_sorted(st) SKM_sk_is_sorted(KRB5_CHECKSUM, (st)) + # define sk_KRB5_ENCDATA_new(cmp) SKM_sk_new(KRB5_ENCDATA, (cmp)) # define sk_KRB5_ENCDATA_new_null() SKM_sk_new_null(KRB5_ENCDATA) # define sk_KRB5_ENCDATA_free(st) SKM_sk_free(KRB5_ENCDATA, (st)) @@ -1091,6 +1132,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_ENCDATA_pop(st) SKM_sk_pop(KRB5_ENCDATA, (st)) # define sk_KRB5_ENCDATA_sort(st) SKM_sk_sort(KRB5_ENCDATA, (st)) # define sk_KRB5_ENCDATA_is_sorted(st) SKM_sk_is_sorted(KRB5_ENCDATA, (st)) + # define sk_KRB5_ENCKEY_new(cmp) SKM_sk_new(KRB5_ENCKEY, (cmp)) # define sk_KRB5_ENCKEY_new_null() SKM_sk_new_null(KRB5_ENCKEY) # define sk_KRB5_ENCKEY_free(st) SKM_sk_free(KRB5_ENCKEY, (st)) @@ -1113,6 +1155,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_ENCKEY_pop(st) SKM_sk_pop(KRB5_ENCKEY, (st)) # define sk_KRB5_ENCKEY_sort(st) SKM_sk_sort(KRB5_ENCKEY, (st)) # define sk_KRB5_ENCKEY_is_sorted(st) SKM_sk_is_sorted(KRB5_ENCKEY, (st)) + # define sk_KRB5_PRINCNAME_new(cmp) SKM_sk_new(KRB5_PRINCNAME, (cmp)) # define sk_KRB5_PRINCNAME_new_null() SKM_sk_new_null(KRB5_PRINCNAME) # define sk_KRB5_PRINCNAME_free(st) SKM_sk_free(KRB5_PRINCNAME, (st)) @@ -1135,6 +1178,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_PRINCNAME_pop(st) SKM_sk_pop(KRB5_PRINCNAME, (st)) # define sk_KRB5_PRINCNAME_sort(st) SKM_sk_sort(KRB5_PRINCNAME, (st)) # define sk_KRB5_PRINCNAME_is_sorted(st) SKM_sk_is_sorted(KRB5_PRINCNAME, (st)) + # define sk_KRB5_TKTBODY_new(cmp) SKM_sk_new(KRB5_TKTBODY, (cmp)) # define sk_KRB5_TKTBODY_new_null() SKM_sk_new_null(KRB5_TKTBODY) # define sk_KRB5_TKTBODY_free(st) SKM_sk_free(KRB5_TKTBODY, (st)) @@ -1157,6 +1201,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_KRB5_TKTBODY_pop(st) SKM_sk_pop(KRB5_TKTBODY, (st)) # define sk_KRB5_TKTBODY_sort(st) SKM_sk_sort(KRB5_TKTBODY, (st)) # define sk_KRB5_TKTBODY_is_sorted(st) SKM_sk_is_sorted(KRB5_TKTBODY, (st)) + # define sk_MEM_OBJECT_DATA_new(cmp) SKM_sk_new(MEM_OBJECT_DATA, (cmp)) # define sk_MEM_OBJECT_DATA_new_null() SKM_sk_new_null(MEM_OBJECT_DATA) # define sk_MEM_OBJECT_DATA_free(st) SKM_sk_free(MEM_OBJECT_DATA, (st)) @@ -1179,6 +1224,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_MEM_OBJECT_DATA_pop(st) SKM_sk_pop(MEM_OBJECT_DATA, (st)) # define sk_MEM_OBJECT_DATA_sort(st) SKM_sk_sort(MEM_OBJECT_DATA, (st)) # define sk_MEM_OBJECT_DATA_is_sorted(st) SKM_sk_is_sorted(MEM_OBJECT_DATA, (st)) + # define sk_MIME_HEADER_new(cmp) SKM_sk_new(MIME_HEADER, (cmp)) # define sk_MIME_HEADER_new_null() SKM_sk_new_null(MIME_HEADER) # define sk_MIME_HEADER_free(st) SKM_sk_free(MIME_HEADER, (st)) @@ -1201,6 +1247,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_MIME_HEADER_pop(st) SKM_sk_pop(MIME_HEADER, (st)) # define sk_MIME_HEADER_sort(st) SKM_sk_sort(MIME_HEADER, (st)) # define sk_MIME_HEADER_is_sorted(st) SKM_sk_is_sorted(MIME_HEADER, (st)) + # define sk_MIME_PARAM_new(cmp) SKM_sk_new(MIME_PARAM, (cmp)) # define sk_MIME_PARAM_new_null() SKM_sk_new_null(MIME_PARAM) # define sk_MIME_PARAM_free(st) SKM_sk_free(MIME_PARAM, (st)) @@ -1223,6 +1270,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_MIME_PARAM_pop(st) SKM_sk_pop(MIME_PARAM, (st)) # define sk_MIME_PARAM_sort(st) SKM_sk_sort(MIME_PARAM, (st)) # define sk_MIME_PARAM_is_sorted(st) SKM_sk_is_sorted(MIME_PARAM, (st)) + # define sk_NAME_FUNCS_new(cmp) SKM_sk_new(NAME_FUNCS, (cmp)) # define sk_NAME_FUNCS_new_null() SKM_sk_new_null(NAME_FUNCS) # define sk_NAME_FUNCS_free(st) SKM_sk_free(NAME_FUNCS, (st)) @@ -1245,6 +1293,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_NAME_FUNCS_pop(st) SKM_sk_pop(NAME_FUNCS, (st)) # define sk_NAME_FUNCS_sort(st) SKM_sk_sort(NAME_FUNCS, (st)) # define sk_NAME_FUNCS_is_sorted(st) SKM_sk_is_sorted(NAME_FUNCS, (st)) + # define sk_OCSP_CERTID_new(cmp) SKM_sk_new(OCSP_CERTID, (cmp)) # define sk_OCSP_CERTID_new_null() SKM_sk_new_null(OCSP_CERTID) # define sk_OCSP_CERTID_free(st) SKM_sk_free(OCSP_CERTID, (st)) @@ -1267,6 +1316,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OCSP_CERTID_pop(st) SKM_sk_pop(OCSP_CERTID, (st)) # define sk_OCSP_CERTID_sort(st) SKM_sk_sort(OCSP_CERTID, (st)) # define sk_OCSP_CERTID_is_sorted(st) SKM_sk_is_sorted(OCSP_CERTID, (st)) + # define sk_OCSP_ONEREQ_new(cmp) SKM_sk_new(OCSP_ONEREQ, (cmp)) # define sk_OCSP_ONEREQ_new_null() SKM_sk_new_null(OCSP_ONEREQ) # define sk_OCSP_ONEREQ_free(st) SKM_sk_free(OCSP_ONEREQ, (st)) @@ -1289,6 +1339,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OCSP_ONEREQ_pop(st) SKM_sk_pop(OCSP_ONEREQ, (st)) # define sk_OCSP_ONEREQ_sort(st) SKM_sk_sort(OCSP_ONEREQ, (st)) # define sk_OCSP_ONEREQ_is_sorted(st) SKM_sk_is_sorted(OCSP_ONEREQ, (st)) + # define sk_OCSP_RESPID_new(cmp) SKM_sk_new(OCSP_RESPID, (cmp)) # define sk_OCSP_RESPID_new_null() SKM_sk_new_null(OCSP_RESPID) # define sk_OCSP_RESPID_free(st) SKM_sk_free(OCSP_RESPID, (st)) @@ -1311,6 +1362,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OCSP_RESPID_pop(st) SKM_sk_pop(OCSP_RESPID, (st)) # define sk_OCSP_RESPID_sort(st) SKM_sk_sort(OCSP_RESPID, (st)) # define sk_OCSP_RESPID_is_sorted(st) SKM_sk_is_sorted(OCSP_RESPID, (st)) + # define sk_OCSP_SINGLERESP_new(cmp) SKM_sk_new(OCSP_SINGLERESP, (cmp)) # define sk_OCSP_SINGLERESP_new_null() SKM_sk_new_null(OCSP_SINGLERESP) # define sk_OCSP_SINGLERESP_free(st) SKM_sk_free(OCSP_SINGLERESP, (st)) @@ -1333,6 +1385,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OCSP_SINGLERESP_pop(st) SKM_sk_pop(OCSP_SINGLERESP, (st)) # define sk_OCSP_SINGLERESP_sort(st) SKM_sk_sort(OCSP_SINGLERESP, (st)) # define sk_OCSP_SINGLERESP_is_sorted(st) SKM_sk_is_sorted(OCSP_SINGLERESP, (st)) + # define sk_PKCS12_SAFEBAG_new(cmp) SKM_sk_new(PKCS12_SAFEBAG, (cmp)) # define sk_PKCS12_SAFEBAG_new_null() SKM_sk_new_null(PKCS12_SAFEBAG) # define sk_PKCS12_SAFEBAG_free(st) SKM_sk_free(PKCS12_SAFEBAG, (st)) @@ -1355,6 +1408,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_PKCS12_SAFEBAG_pop(st) SKM_sk_pop(PKCS12_SAFEBAG, (st)) # define sk_PKCS12_SAFEBAG_sort(st) SKM_sk_sort(PKCS12_SAFEBAG, (st)) # define sk_PKCS12_SAFEBAG_is_sorted(st) SKM_sk_is_sorted(PKCS12_SAFEBAG, (st)) + # define sk_PKCS7_new(cmp) SKM_sk_new(PKCS7, (cmp)) # define sk_PKCS7_new_null() SKM_sk_new_null(PKCS7) # define sk_PKCS7_free(st) SKM_sk_free(PKCS7, (st)) @@ -1377,6 +1431,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_PKCS7_pop(st) SKM_sk_pop(PKCS7, (st)) # define sk_PKCS7_sort(st) SKM_sk_sort(PKCS7, (st)) # define sk_PKCS7_is_sorted(st) SKM_sk_is_sorted(PKCS7, (st)) + # define sk_PKCS7_RECIP_INFO_new(cmp) SKM_sk_new(PKCS7_RECIP_INFO, (cmp)) # define sk_PKCS7_RECIP_INFO_new_null() SKM_sk_new_null(PKCS7_RECIP_INFO) # define sk_PKCS7_RECIP_INFO_free(st) SKM_sk_free(PKCS7_RECIP_INFO, (st)) @@ -1399,6 +1454,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_PKCS7_RECIP_INFO_pop(st) SKM_sk_pop(PKCS7_RECIP_INFO, (st)) # define sk_PKCS7_RECIP_INFO_sort(st) SKM_sk_sort(PKCS7_RECIP_INFO, (st)) # define sk_PKCS7_RECIP_INFO_is_sorted(st) SKM_sk_is_sorted(PKCS7_RECIP_INFO, (st)) + # define sk_PKCS7_SIGNER_INFO_new(cmp) SKM_sk_new(PKCS7_SIGNER_INFO, (cmp)) # define sk_PKCS7_SIGNER_INFO_new_null() SKM_sk_new_null(PKCS7_SIGNER_INFO) # define sk_PKCS7_SIGNER_INFO_free(st) SKM_sk_free(PKCS7_SIGNER_INFO, (st)) @@ -1421,6 +1477,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_PKCS7_SIGNER_INFO_pop(st) SKM_sk_pop(PKCS7_SIGNER_INFO, (st)) # define sk_PKCS7_SIGNER_INFO_sort(st) SKM_sk_sort(PKCS7_SIGNER_INFO, (st)) # define sk_PKCS7_SIGNER_INFO_is_sorted(st) SKM_sk_is_sorted(PKCS7_SIGNER_INFO, (st)) + # define sk_POLICYINFO_new(cmp) SKM_sk_new(POLICYINFO, (cmp)) # define sk_POLICYINFO_new_null() SKM_sk_new_null(POLICYINFO) # define sk_POLICYINFO_free(st) SKM_sk_free(POLICYINFO, (st)) @@ -1443,6 +1500,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_POLICYINFO_pop(st) SKM_sk_pop(POLICYINFO, (st)) # define sk_POLICYINFO_sort(st) SKM_sk_sort(POLICYINFO, (st)) # define sk_POLICYINFO_is_sorted(st) SKM_sk_is_sorted(POLICYINFO, (st)) + # define sk_POLICYQUALINFO_new(cmp) SKM_sk_new(POLICYQUALINFO, (cmp)) # define sk_POLICYQUALINFO_new_null() SKM_sk_new_null(POLICYQUALINFO) # define sk_POLICYQUALINFO_free(st) SKM_sk_free(POLICYQUALINFO, (st)) @@ -1465,6 +1523,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_POLICYQUALINFO_pop(st) SKM_sk_pop(POLICYQUALINFO, (st)) # define sk_POLICYQUALINFO_sort(st) SKM_sk_sort(POLICYQUALINFO, (st)) # define sk_POLICYQUALINFO_is_sorted(st) SKM_sk_is_sorted(POLICYQUALINFO, (st)) + # define sk_POLICY_MAPPING_new(cmp) SKM_sk_new(POLICY_MAPPING, (cmp)) # define sk_POLICY_MAPPING_new_null() SKM_sk_new_null(POLICY_MAPPING) # define sk_POLICY_MAPPING_free(st) SKM_sk_free(POLICY_MAPPING, (st)) @@ -1487,6 +1546,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_POLICY_MAPPING_pop(st) SKM_sk_pop(POLICY_MAPPING, (st)) # define sk_POLICY_MAPPING_sort(st) SKM_sk_sort(POLICY_MAPPING, (st)) # define sk_POLICY_MAPPING_is_sorted(st) SKM_sk_is_sorted(POLICY_MAPPING, (st)) + # define sk_SCT_new(cmp) SKM_sk_new(SCT, (cmp)) # define sk_SCT_new_null() SKM_sk_new_null(SCT) # define sk_SCT_free(st) SKM_sk_free(SCT, (st)) @@ -1509,6 +1569,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SCT_pop(st) SKM_sk_pop(SCT, (st)) # define sk_SCT_sort(st) SKM_sk_sort(SCT, (st)) # define sk_SCT_is_sorted(st) SKM_sk_is_sorted(SCT, (st)) + # define sk_SRP_gN_new(cmp) SKM_sk_new(SRP_gN, (cmp)) # define sk_SRP_gN_new_null() SKM_sk_new_null(SRP_gN) # define sk_SRP_gN_free(st) SKM_sk_free(SRP_gN, (st)) @@ -1531,6 +1592,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SRP_gN_pop(st) SKM_sk_pop(SRP_gN, (st)) # define sk_SRP_gN_sort(st) SKM_sk_sort(SRP_gN, (st)) # define sk_SRP_gN_is_sorted(st) SKM_sk_is_sorted(SRP_gN, (st)) + # define sk_SRP_gN_cache_new(cmp) SKM_sk_new(SRP_gN_cache, (cmp)) # define sk_SRP_gN_cache_new_null() SKM_sk_new_null(SRP_gN_cache) # define sk_SRP_gN_cache_free(st) SKM_sk_free(SRP_gN_cache, (st)) @@ -1553,6 +1615,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SRP_gN_cache_pop(st) SKM_sk_pop(SRP_gN_cache, (st)) # define sk_SRP_gN_cache_sort(st) SKM_sk_sort(SRP_gN_cache, (st)) # define sk_SRP_gN_cache_is_sorted(st) SKM_sk_is_sorted(SRP_gN_cache, (st)) + # define sk_SRP_user_pwd_new(cmp) SKM_sk_new(SRP_user_pwd, (cmp)) # define sk_SRP_user_pwd_new_null() SKM_sk_new_null(SRP_user_pwd) # define sk_SRP_user_pwd_free(st) SKM_sk_free(SRP_user_pwd, (st)) @@ -1575,6 +1638,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SRP_user_pwd_pop(st) SKM_sk_pop(SRP_user_pwd, (st)) # define sk_SRP_user_pwd_sort(st) SKM_sk_sort(SRP_user_pwd, (st)) # define sk_SRP_user_pwd_is_sorted(st) SKM_sk_is_sorted(SRP_user_pwd, (st)) + # define sk_SRTP_PROTECTION_PROFILE_new(cmp) SKM_sk_new(SRTP_PROTECTION_PROFILE, (cmp)) # define sk_SRTP_PROTECTION_PROFILE_new_null() SKM_sk_new_null(SRTP_PROTECTION_PROFILE) # define sk_SRTP_PROTECTION_PROFILE_free(st) SKM_sk_free(SRTP_PROTECTION_PROFILE, (st)) @@ -1597,6 +1661,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SRTP_PROTECTION_PROFILE_pop(st) SKM_sk_pop(SRTP_PROTECTION_PROFILE, (st)) # define sk_SRTP_PROTECTION_PROFILE_sort(st) SKM_sk_sort(SRTP_PROTECTION_PROFILE, (st)) # define sk_SRTP_PROTECTION_PROFILE_is_sorted(st) SKM_sk_is_sorted(SRTP_PROTECTION_PROFILE, (st)) + # define sk_SSL_CIPHER_new(cmp) SKM_sk_new(SSL_CIPHER, (cmp)) # define sk_SSL_CIPHER_new_null() SKM_sk_new_null(SSL_CIPHER) # define sk_SSL_CIPHER_free(st) SKM_sk_free(SSL_CIPHER, (st)) @@ -1619,6 +1684,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SSL_CIPHER_pop(st) SKM_sk_pop(SSL_CIPHER, (st)) # define sk_SSL_CIPHER_sort(st) SKM_sk_sort(SSL_CIPHER, (st)) # define sk_SSL_CIPHER_is_sorted(st) SKM_sk_is_sorted(SSL_CIPHER, (st)) + # define sk_SSL_COMP_new(cmp) SKM_sk_new(SSL_COMP, (cmp)) # define sk_SSL_COMP_new_null() SKM_sk_new_null(SSL_COMP) # define sk_SSL_COMP_free(st) SKM_sk_free(SSL_COMP, (st)) @@ -1641,6 +1707,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SSL_COMP_pop(st) SKM_sk_pop(SSL_COMP, (st)) # define sk_SSL_COMP_sort(st) SKM_sk_sort(SSL_COMP, (st)) # define sk_SSL_COMP_is_sorted(st) SKM_sk_is_sorted(SSL_COMP, (st)) + # define sk_STACK_OF_X509_NAME_ENTRY_new(cmp) SKM_sk_new(STACK_OF_X509_NAME_ENTRY, (cmp)) # define sk_STACK_OF_X509_NAME_ENTRY_new_null() SKM_sk_new_null(STACK_OF_X509_NAME_ENTRY) # define sk_STACK_OF_X509_NAME_ENTRY_free(st) SKM_sk_free(STACK_OF_X509_NAME_ENTRY, (st)) @@ -1663,6 +1730,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_STACK_OF_X509_NAME_ENTRY_pop(st) SKM_sk_pop(STACK_OF_X509_NAME_ENTRY, (st)) # define sk_STACK_OF_X509_NAME_ENTRY_sort(st) SKM_sk_sort(STACK_OF_X509_NAME_ENTRY, (st)) # define sk_STACK_OF_X509_NAME_ENTRY_is_sorted(st) SKM_sk_is_sorted(STACK_OF_X509_NAME_ENTRY, (st)) + # define sk_STORE_ATTR_INFO_new(cmp) SKM_sk_new(STORE_ATTR_INFO, (cmp)) # define sk_STORE_ATTR_INFO_new_null() SKM_sk_new_null(STORE_ATTR_INFO) # define sk_STORE_ATTR_INFO_free(st) SKM_sk_free(STORE_ATTR_INFO, (st)) @@ -1685,6 +1753,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_STORE_ATTR_INFO_pop(st) SKM_sk_pop(STORE_ATTR_INFO, (st)) # define sk_STORE_ATTR_INFO_sort(st) SKM_sk_sort(STORE_ATTR_INFO, (st)) # define sk_STORE_ATTR_INFO_is_sorted(st) SKM_sk_is_sorted(STORE_ATTR_INFO, (st)) + # define sk_STORE_OBJECT_new(cmp) SKM_sk_new(STORE_OBJECT, (cmp)) # define sk_STORE_OBJECT_new_null() SKM_sk_new_null(STORE_OBJECT) # define sk_STORE_OBJECT_free(st) SKM_sk_free(STORE_OBJECT, (st)) @@ -1707,6 +1776,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_STORE_OBJECT_pop(st) SKM_sk_pop(STORE_OBJECT, (st)) # define sk_STORE_OBJECT_sort(st) SKM_sk_sort(STORE_OBJECT, (st)) # define sk_STORE_OBJECT_is_sorted(st) SKM_sk_is_sorted(STORE_OBJECT, (st)) + # define sk_SXNETID_new(cmp) SKM_sk_new(SXNETID, (cmp)) # define sk_SXNETID_new_null() SKM_sk_new_null(SXNETID) # define sk_SXNETID_free(st) SKM_sk_free(SXNETID, (st)) @@ -1729,6 +1799,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_SXNETID_pop(st) SKM_sk_pop(SXNETID, (st)) # define sk_SXNETID_sort(st) SKM_sk_sort(SXNETID, (st)) # define sk_SXNETID_is_sorted(st) SKM_sk_is_sorted(SXNETID, (st)) + # define sk_UI_STRING_new(cmp) SKM_sk_new(UI_STRING, (cmp)) # define sk_UI_STRING_new_null() SKM_sk_new_null(UI_STRING) # define sk_UI_STRING_free(st) SKM_sk_free(UI_STRING, (st)) @@ -1751,6 +1822,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_UI_STRING_pop(st) SKM_sk_pop(UI_STRING, (st)) # define sk_UI_STRING_sort(st) SKM_sk_sort(UI_STRING, (st)) # define sk_UI_STRING_is_sorted(st) SKM_sk_is_sorted(UI_STRING, (st)) + # define sk_X509_new(cmp) SKM_sk_new(X509, (cmp)) # define sk_X509_new_null() SKM_sk_new_null(X509) # define sk_X509_free(st) SKM_sk_free(X509, (st)) @@ -1773,6 +1845,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_pop(st) SKM_sk_pop(X509, (st)) # define sk_X509_sort(st) SKM_sk_sort(X509, (st)) # define sk_X509_is_sorted(st) SKM_sk_is_sorted(X509, (st)) + # define sk_X509V3_EXT_METHOD_new(cmp) SKM_sk_new(X509V3_EXT_METHOD, (cmp)) # define sk_X509V3_EXT_METHOD_new_null() SKM_sk_new_null(X509V3_EXT_METHOD) # define sk_X509V3_EXT_METHOD_free(st) SKM_sk_free(X509V3_EXT_METHOD, (st)) @@ -1795,6 +1868,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509V3_EXT_METHOD_pop(st) SKM_sk_pop(X509V3_EXT_METHOD, (st)) # define sk_X509V3_EXT_METHOD_sort(st) SKM_sk_sort(X509V3_EXT_METHOD, (st)) # define sk_X509V3_EXT_METHOD_is_sorted(st) SKM_sk_is_sorted(X509V3_EXT_METHOD, (st)) + # define sk_X509_ALGOR_new(cmp) SKM_sk_new(X509_ALGOR, (cmp)) # define sk_X509_ALGOR_new_null() SKM_sk_new_null(X509_ALGOR) # define sk_X509_ALGOR_free(st) SKM_sk_free(X509_ALGOR, (st)) @@ -1817,6 +1891,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_ALGOR_pop(st) SKM_sk_pop(X509_ALGOR, (st)) # define sk_X509_ALGOR_sort(st) SKM_sk_sort(X509_ALGOR, (st)) # define sk_X509_ALGOR_is_sorted(st) SKM_sk_is_sorted(X509_ALGOR, (st)) + # define sk_X509_ATTRIBUTE_new(cmp) SKM_sk_new(X509_ATTRIBUTE, (cmp)) # define sk_X509_ATTRIBUTE_new_null() SKM_sk_new_null(X509_ATTRIBUTE) # define sk_X509_ATTRIBUTE_free(st) SKM_sk_free(X509_ATTRIBUTE, (st)) @@ -1839,6 +1914,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_ATTRIBUTE_pop(st) SKM_sk_pop(X509_ATTRIBUTE, (st)) # define sk_X509_ATTRIBUTE_sort(st) SKM_sk_sort(X509_ATTRIBUTE, (st)) # define sk_X509_ATTRIBUTE_is_sorted(st) SKM_sk_is_sorted(X509_ATTRIBUTE, (st)) + # define sk_X509_CRL_new(cmp) SKM_sk_new(X509_CRL, (cmp)) # define sk_X509_CRL_new_null() SKM_sk_new_null(X509_CRL) # define sk_X509_CRL_free(st) SKM_sk_free(X509_CRL, (st)) @@ -1861,6 +1937,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_CRL_pop(st) SKM_sk_pop(X509_CRL, (st)) # define sk_X509_CRL_sort(st) SKM_sk_sort(X509_CRL, (st)) # define sk_X509_CRL_is_sorted(st) SKM_sk_is_sorted(X509_CRL, (st)) + # define sk_X509_EXTENSION_new(cmp) SKM_sk_new(X509_EXTENSION, (cmp)) # define sk_X509_EXTENSION_new_null() SKM_sk_new_null(X509_EXTENSION) # define sk_X509_EXTENSION_free(st) SKM_sk_free(X509_EXTENSION, (st)) @@ -1883,6 +1960,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_EXTENSION_pop(st) SKM_sk_pop(X509_EXTENSION, (st)) # define sk_X509_EXTENSION_sort(st) SKM_sk_sort(X509_EXTENSION, (st)) # define sk_X509_EXTENSION_is_sorted(st) SKM_sk_is_sorted(X509_EXTENSION, (st)) + # define sk_X509_INFO_new(cmp) SKM_sk_new(X509_INFO, (cmp)) # define sk_X509_INFO_new_null() SKM_sk_new_null(X509_INFO) # define sk_X509_INFO_free(st) SKM_sk_free(X509_INFO, (st)) @@ -1905,6 +1983,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_INFO_pop(st) SKM_sk_pop(X509_INFO, (st)) # define sk_X509_INFO_sort(st) SKM_sk_sort(X509_INFO, (st)) # define sk_X509_INFO_is_sorted(st) SKM_sk_is_sorted(X509_INFO, (st)) + # define sk_X509_LOOKUP_new(cmp) SKM_sk_new(X509_LOOKUP, (cmp)) # define sk_X509_LOOKUP_new_null() SKM_sk_new_null(X509_LOOKUP) # define sk_X509_LOOKUP_free(st) SKM_sk_free(X509_LOOKUP, (st)) @@ -1927,6 +2006,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_LOOKUP_pop(st) SKM_sk_pop(X509_LOOKUP, (st)) # define sk_X509_LOOKUP_sort(st) SKM_sk_sort(X509_LOOKUP, (st)) # define sk_X509_LOOKUP_is_sorted(st) SKM_sk_is_sorted(X509_LOOKUP, (st)) + # define sk_X509_NAME_new(cmp) SKM_sk_new(X509_NAME, (cmp)) # define sk_X509_NAME_new_null() SKM_sk_new_null(X509_NAME) # define sk_X509_NAME_free(st) SKM_sk_free(X509_NAME, (st)) @@ -1949,6 +2029,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_NAME_pop(st) SKM_sk_pop(X509_NAME, (st)) # define sk_X509_NAME_sort(st) SKM_sk_sort(X509_NAME, (st)) # define sk_X509_NAME_is_sorted(st) SKM_sk_is_sorted(X509_NAME, (st)) + # define sk_X509_NAME_ENTRY_new(cmp) SKM_sk_new(X509_NAME_ENTRY, (cmp)) # define sk_X509_NAME_ENTRY_new_null() SKM_sk_new_null(X509_NAME_ENTRY) # define sk_X509_NAME_ENTRY_free(st) SKM_sk_free(X509_NAME_ENTRY, (st)) @@ -1971,6 +2052,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_NAME_ENTRY_pop(st) SKM_sk_pop(X509_NAME_ENTRY, (st)) # define sk_X509_NAME_ENTRY_sort(st) SKM_sk_sort(X509_NAME_ENTRY, (st)) # define sk_X509_NAME_ENTRY_is_sorted(st) SKM_sk_is_sorted(X509_NAME_ENTRY, (st)) + # define sk_X509_OBJECT_new(cmp) SKM_sk_new(X509_OBJECT, (cmp)) # define sk_X509_OBJECT_new_null() SKM_sk_new_null(X509_OBJECT) # define sk_X509_OBJECT_free(st) SKM_sk_free(X509_OBJECT, (st)) @@ -1993,6 +2075,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_OBJECT_pop(st) SKM_sk_pop(X509_OBJECT, (st)) # define sk_X509_OBJECT_sort(st) SKM_sk_sort(X509_OBJECT, (st)) # define sk_X509_OBJECT_is_sorted(st) SKM_sk_is_sorted(X509_OBJECT, (st)) + # define sk_X509_POLICY_DATA_new(cmp) SKM_sk_new(X509_POLICY_DATA, (cmp)) # define sk_X509_POLICY_DATA_new_null() SKM_sk_new_null(X509_POLICY_DATA) # define sk_X509_POLICY_DATA_free(st) SKM_sk_free(X509_POLICY_DATA, (st)) @@ -2015,6 +2098,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_POLICY_DATA_pop(st) SKM_sk_pop(X509_POLICY_DATA, (st)) # define sk_X509_POLICY_DATA_sort(st) SKM_sk_sort(X509_POLICY_DATA, (st)) # define sk_X509_POLICY_DATA_is_sorted(st) SKM_sk_is_sorted(X509_POLICY_DATA, (st)) + # define sk_X509_POLICY_NODE_new(cmp) SKM_sk_new(X509_POLICY_NODE, (cmp)) # define sk_X509_POLICY_NODE_new_null() SKM_sk_new_null(X509_POLICY_NODE) # define sk_X509_POLICY_NODE_free(st) SKM_sk_free(X509_POLICY_NODE, (st)) @@ -2037,6 +2121,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_POLICY_NODE_pop(st) SKM_sk_pop(X509_POLICY_NODE, (st)) # define sk_X509_POLICY_NODE_sort(st) SKM_sk_sort(X509_POLICY_NODE, (st)) # define sk_X509_POLICY_NODE_is_sorted(st) SKM_sk_is_sorted(X509_POLICY_NODE, (st)) + # define sk_X509_PURPOSE_new(cmp) SKM_sk_new(X509_PURPOSE, (cmp)) # define sk_X509_PURPOSE_new_null() SKM_sk_new_null(X509_PURPOSE) # define sk_X509_PURPOSE_free(st) SKM_sk_free(X509_PURPOSE, (st)) @@ -2059,6 +2144,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_PURPOSE_pop(st) SKM_sk_pop(X509_PURPOSE, (st)) # define sk_X509_PURPOSE_sort(st) SKM_sk_sort(X509_PURPOSE, (st)) # define sk_X509_PURPOSE_is_sorted(st) SKM_sk_is_sorted(X509_PURPOSE, (st)) + # define sk_X509_REVOKED_new(cmp) SKM_sk_new(X509_REVOKED, (cmp)) # define sk_X509_REVOKED_new_null() SKM_sk_new_null(X509_REVOKED) # define sk_X509_REVOKED_free(st) SKM_sk_free(X509_REVOKED, (st)) @@ -2081,6 +2167,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_REVOKED_pop(st) SKM_sk_pop(X509_REVOKED, (st)) # define sk_X509_REVOKED_sort(st) SKM_sk_sort(X509_REVOKED, (st)) # define sk_X509_REVOKED_is_sorted(st) SKM_sk_is_sorted(X509_REVOKED, (st)) + # define sk_X509_TRUST_new(cmp) SKM_sk_new(X509_TRUST, (cmp)) # define sk_X509_TRUST_new_null() SKM_sk_new_null(X509_TRUST) # define sk_X509_TRUST_free(st) SKM_sk_free(X509_TRUST, (st)) @@ -2103,6 +2190,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_TRUST_pop(st) SKM_sk_pop(X509_TRUST, (st)) # define sk_X509_TRUST_sort(st) SKM_sk_sort(X509_TRUST, (st)) # define sk_X509_TRUST_is_sorted(st) SKM_sk_is_sorted(X509_TRUST, (st)) + # define sk_X509_VERIFY_PARAM_new(cmp) SKM_sk_new(X509_VERIFY_PARAM, (cmp)) # define sk_X509_VERIFY_PARAM_new_null() SKM_sk_new_null(X509_VERIFY_PARAM) # define sk_X509_VERIFY_PARAM_free(st) SKM_sk_free(X509_VERIFY_PARAM, (st)) @@ -2125,6 +2213,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_X509_VERIFY_PARAM_pop(st) SKM_sk_pop(X509_VERIFY_PARAM, (st)) # define sk_X509_VERIFY_PARAM_sort(st) SKM_sk_sort(X509_VERIFY_PARAM, (st)) # define sk_X509_VERIFY_PARAM_is_sorted(st) SKM_sk_is_sorted(X509_VERIFY_PARAM, (st)) + # define sk_nid_triple_new(cmp) SKM_sk_new(nid_triple, (cmp)) # define sk_nid_triple_new_null() SKM_sk_new_null(nid_triple) # define sk_nid_triple_free(st) SKM_sk_free(nid_triple, (st)) @@ -2147,6 +2236,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_nid_triple_pop(st) SKM_sk_pop(nid_triple, (st)) # define sk_nid_triple_sort(st) SKM_sk_sort(nid_triple, (st)) # define sk_nid_triple_is_sorted(st) SKM_sk_is_sorted(nid_triple, (st)) + # define sk_void_new(cmp) SKM_sk_new(void, (cmp)) # define sk_void_new_null() SKM_sk_new_null(void) # define sk_void_free(st) SKM_sk_free(void, (st)) @@ -2169,6 +2259,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_void_pop(st) SKM_sk_pop(void, (st)) # define sk_void_sort(st) SKM_sk_sort(void, (st)) # define sk_void_is_sorted(st) SKM_sk_is_sorted(void, (st)) + # define sk_OPENSSL_STRING_new(cmp) ((STACK_OF(OPENSSL_STRING) *)sk_new(CHECKED_SK_CMP_FUNC(char, cmp))) # define sk_OPENSSL_STRING_new_null() ((STACK_OF(OPENSSL_STRING) *)sk_new_null()) # define sk_OPENSSL_STRING_push(st, val) sk_push(CHECKED_STACK_OF(OPENSSL_STRING, st), CHECKED_PTR_OF(char, val)) @@ -2193,6 +2284,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OPENSSL_STRING_pop(st) (char *)sk_pop(CHECKED_STACK_OF(OPENSSL_STRING, st)) # define sk_OPENSSL_STRING_sort(st) SKM_sk_sort(OPENSSL_STRING, (st)) # define sk_OPENSSL_STRING_is_sorted(st) SKM_sk_is_sorted(OPENSSL_STRING, (st)) + # define sk_OPENSSL_BLOCK_new(cmp) ((STACK_OF(OPENSSL_BLOCK) *)sk_new(CHECKED_SK_CMP_FUNC(void, cmp))) # define sk_OPENSSL_BLOCK_new_null() ((STACK_OF(OPENSSL_BLOCK) *)sk_new_null()) # define sk_OPENSSL_BLOCK_push(st, val) sk_push(CHECKED_STACK_OF(OPENSSL_BLOCK, st), CHECKED_PTR_OF(void, val)) @@ -2217,6 +2309,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OPENSSL_BLOCK_pop(st) (void *)sk_pop(CHECKED_STACK_OF(OPENSSL_BLOCK, st)) # define sk_OPENSSL_BLOCK_sort(st) SKM_sk_sort(OPENSSL_BLOCK, (st)) # define sk_OPENSSL_BLOCK_is_sorted(st) SKM_sk_is_sorted(OPENSSL_BLOCK, (st)) + # define sk_OPENSSL_PSTRING_new(cmp) ((STACK_OF(OPENSSL_PSTRING) *)sk_new(CHECKED_SK_CMP_FUNC(OPENSSL_STRING, cmp))) # define sk_OPENSSL_PSTRING_new_null() ((STACK_OF(OPENSSL_PSTRING) *)sk_new_null()) # define sk_OPENSSL_PSTRING_push(st, val) sk_push(CHECKED_STACK_OF(OPENSSL_PSTRING, st), CHECKED_PTR_OF(OPENSSL_STRING, val)) @@ -2241,6 +2334,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define sk_OPENSSL_PSTRING_pop(st) (OPENSSL_STRING *)sk_pop(CHECKED_STACK_OF(OPENSSL_PSTRING, st)) # define sk_OPENSSL_PSTRING_sort(st) SKM_sk_sort(OPENSSL_PSTRING, (st)) # define sk_OPENSSL_PSTRING_is_sorted(st) SKM_sk_is_sorted(OPENSSL_PSTRING, (st)) + # define d2i_ASN1_SET_OF_ACCESS_DESCRIPTION(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(ACCESS_DESCRIPTION, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_ACCESS_DESCRIPTION(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2249,6 +2343,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(ACCESS_DESCRIPTION, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_ACCESS_DESCRIPTION(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(ACCESS_DESCRIPTION, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_ASN1_INTEGER(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(ASN1_INTEGER, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_ASN1_INTEGER(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2257,6 +2352,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(ASN1_INTEGER, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_ASN1_INTEGER(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(ASN1_INTEGER, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_ASN1_OBJECT(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(ASN1_OBJECT, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_ASN1_OBJECT(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2265,6 +2361,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(ASN1_OBJECT, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_ASN1_OBJECT(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(ASN1_OBJECT, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_ASN1_TYPE(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(ASN1_TYPE, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_ASN1_TYPE(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2273,6 +2370,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(ASN1_TYPE, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_ASN1_TYPE(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(ASN1_TYPE, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_ASN1_UTF8STRING(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(ASN1_UTF8STRING, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_ASN1_UTF8STRING(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2281,6 +2379,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(ASN1_UTF8STRING, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_ASN1_UTF8STRING(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(ASN1_UTF8STRING, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_DIST_POINT(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(DIST_POINT, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_DIST_POINT(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2289,6 +2388,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(DIST_POINT, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_DIST_POINT(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(DIST_POINT, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_ESS_CERT_ID(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(ESS_CERT_ID, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_ESS_CERT_ID(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2297,6 +2397,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(ESS_CERT_ID, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_ESS_CERT_ID(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(ESS_CERT_ID, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_EVP_MD(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(EVP_MD, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_EVP_MD(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2305,6 +2406,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(EVP_MD, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_EVP_MD(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(EVP_MD, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_GENERAL_NAME(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(GENERAL_NAME, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_GENERAL_NAME(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2313,6 +2415,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(GENERAL_NAME, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_GENERAL_NAME(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(GENERAL_NAME, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_OCSP_ONEREQ(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(OCSP_ONEREQ, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_OCSP_ONEREQ(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2321,6 +2424,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(OCSP_ONEREQ, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_OCSP_ONEREQ(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(OCSP_ONEREQ, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_OCSP_SINGLERESP(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(OCSP_SINGLERESP, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_OCSP_SINGLERESP(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2329,6 +2433,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(OCSP_SINGLERESP, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_OCSP_SINGLERESP(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(OCSP_SINGLERESP, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_PKCS12_SAFEBAG(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(PKCS12_SAFEBAG, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_PKCS12_SAFEBAG(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2337,6 +2442,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(PKCS12_SAFEBAG, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_PKCS12_SAFEBAG(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(PKCS12_SAFEBAG, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_PKCS7(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(PKCS7, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_PKCS7(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2345,6 +2451,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(PKCS7, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_PKCS7(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(PKCS7, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_PKCS7_RECIP_INFO(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(PKCS7_RECIP_INFO, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_PKCS7_RECIP_INFO(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2353,6 +2460,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(PKCS7_RECIP_INFO, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_PKCS7_RECIP_INFO(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(PKCS7_RECIP_INFO, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_PKCS7_SIGNER_INFO(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(PKCS7_SIGNER_INFO, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_PKCS7_SIGNER_INFO(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2361,6 +2469,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(PKCS7_SIGNER_INFO, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_PKCS7_SIGNER_INFO(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(PKCS7_SIGNER_INFO, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_POLICYINFO(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(POLICYINFO, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_POLICYINFO(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2369,6 +2478,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(POLICYINFO, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_POLICYINFO(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(POLICYINFO, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_POLICYQUALINFO(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(POLICYQUALINFO, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_POLICYQUALINFO(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2377,6 +2487,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(POLICYQUALINFO, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_POLICYQUALINFO(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(POLICYQUALINFO, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_SXNETID(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(SXNETID, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_SXNETID(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2385,6 +2496,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(SXNETID, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_SXNETID(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(SXNETID, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2393,6 +2505,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509_ALGOR(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509_ALGOR, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509_ALGOR(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2401,6 +2514,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509_ALGOR, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509_ALGOR(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509_ALGOR, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509_ATTRIBUTE(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509_ATTRIBUTE, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509_ATTRIBUTE(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2409,6 +2523,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509_ATTRIBUTE, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509_ATTRIBUTE(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509_ATTRIBUTE, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509_CRL(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509_CRL, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509_CRL(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2417,6 +2532,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509_CRL, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509_CRL(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509_CRL, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509_EXTENSION(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509_EXTENSION, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509_EXTENSION(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2425,6 +2541,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509_EXTENSION, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509_EXTENSION(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509_EXTENSION, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509_NAME_ENTRY(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509_NAME_ENTRY, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509_NAME_ENTRY(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2433,6 +2550,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509_NAME_ENTRY, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509_NAME_ENTRY(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509_NAME_ENTRY, (buf), (len), (d2i_func), (free_func)) + # define d2i_ASN1_SET_OF_X509_REVOKED(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ SKM_ASN1_SET_OF_d2i(X509_REVOKED, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) # define i2d_ASN1_SET_OF_X509_REVOKED(st, pp, i2d_func, ex_tag, ex_class, is_set) \ @@ -2441,10 +2559,13 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) SKM_ASN1_seq_pack(X509_REVOKED, (st), (i2d_func), (buf), (len)) # define ASN1_seq_unpack_X509_REVOKED(buf, len, d2i_func, free_func) \ SKM_ASN1_seq_unpack(X509_REVOKED, (buf), (len), (d2i_func), (free_func)) + # define PKCS12_decrypt_d2i_PKCS12_SAFEBAG(algor, d2i_func, free_func, pass, passlen, oct, seq) \ SKM_PKCS12_decrypt_d2i(PKCS12_SAFEBAG, (algor), (d2i_func), (free_func), (pass), (passlen), (oct), (seq)) + # define PKCS12_decrypt_d2i_PKCS7(algor, d2i_func, free_func, pass, passlen, oct, seq) \ SKM_PKCS12_decrypt_d2i(PKCS7, (algor), (d2i_func), (free_func), (pass), (passlen), (oct), (seq)) + # define lh_ADDED_OBJ_new() LHM_lh_new(ADDED_OBJ,added_obj) # define lh_ADDED_OBJ_insert(lh,inst) LHM_lh_insert(ADDED_OBJ,lh,inst) # define lh_ADDED_OBJ_retrieve(lh,inst) LHM_lh_retrieve(ADDED_OBJ,lh,inst) @@ -2462,6 +2583,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_ADDED_OBJ_stats_bio(lh,out) \ LHM_lh_stats_bio(ADDED_OBJ,lh,out) # define lh_ADDED_OBJ_free(lh) LHM_lh_free(ADDED_OBJ,lh) + # define lh_APP_INFO_new() LHM_lh_new(APP_INFO,app_info) # define lh_APP_INFO_insert(lh,inst) LHM_lh_insert(APP_INFO,lh,inst) # define lh_APP_INFO_retrieve(lh,inst) LHM_lh_retrieve(APP_INFO,lh,inst) @@ -2479,6 +2601,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_APP_INFO_stats_bio(lh,out) \ LHM_lh_stats_bio(APP_INFO,lh,out) # define lh_APP_INFO_free(lh) LHM_lh_free(APP_INFO,lh) + # define lh_CONF_VALUE_new() LHM_lh_new(CONF_VALUE,conf_value) # define lh_CONF_VALUE_insert(lh,inst) LHM_lh_insert(CONF_VALUE,lh,inst) # define lh_CONF_VALUE_retrieve(lh,inst) LHM_lh_retrieve(CONF_VALUE,lh,inst) @@ -2496,6 +2619,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_CONF_VALUE_stats_bio(lh,out) \ LHM_lh_stats_bio(CONF_VALUE,lh,out) # define lh_CONF_VALUE_free(lh) LHM_lh_free(CONF_VALUE,lh) + # define lh_ENGINE_PILE_new() LHM_lh_new(ENGINE_PILE,engine_pile) # define lh_ENGINE_PILE_insert(lh,inst) LHM_lh_insert(ENGINE_PILE,lh,inst) # define lh_ENGINE_PILE_retrieve(lh,inst) LHM_lh_retrieve(ENGINE_PILE,lh,inst) @@ -2513,6 +2637,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_ENGINE_PILE_stats_bio(lh,out) \ LHM_lh_stats_bio(ENGINE_PILE,lh,out) # define lh_ENGINE_PILE_free(lh) LHM_lh_free(ENGINE_PILE,lh) + # define lh_ERR_STATE_new() LHM_lh_new(ERR_STATE,err_state) # define lh_ERR_STATE_insert(lh,inst) LHM_lh_insert(ERR_STATE,lh,inst) # define lh_ERR_STATE_retrieve(lh,inst) LHM_lh_retrieve(ERR_STATE,lh,inst) @@ -2530,6 +2655,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_ERR_STATE_stats_bio(lh,out) \ LHM_lh_stats_bio(ERR_STATE,lh,out) # define lh_ERR_STATE_free(lh) LHM_lh_free(ERR_STATE,lh) + # define lh_ERR_STRING_DATA_new() LHM_lh_new(ERR_STRING_DATA,err_string_data) # define lh_ERR_STRING_DATA_insert(lh,inst) LHM_lh_insert(ERR_STRING_DATA,lh,inst) # define lh_ERR_STRING_DATA_retrieve(lh,inst) LHM_lh_retrieve(ERR_STRING_DATA,lh,inst) @@ -2547,6 +2673,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_ERR_STRING_DATA_stats_bio(lh,out) \ LHM_lh_stats_bio(ERR_STRING_DATA,lh,out) # define lh_ERR_STRING_DATA_free(lh) LHM_lh_free(ERR_STRING_DATA,lh) + # define lh_EX_CLASS_ITEM_new() LHM_lh_new(EX_CLASS_ITEM,ex_class_item) # define lh_EX_CLASS_ITEM_insert(lh,inst) LHM_lh_insert(EX_CLASS_ITEM,lh,inst) # define lh_EX_CLASS_ITEM_retrieve(lh,inst) LHM_lh_retrieve(EX_CLASS_ITEM,lh,inst) @@ -2564,6 +2691,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_EX_CLASS_ITEM_stats_bio(lh,out) \ LHM_lh_stats_bio(EX_CLASS_ITEM,lh,out) # define lh_EX_CLASS_ITEM_free(lh) LHM_lh_free(EX_CLASS_ITEM,lh) + # define lh_FUNCTION_new() LHM_lh_new(FUNCTION,function) # define lh_FUNCTION_insert(lh,inst) LHM_lh_insert(FUNCTION,lh,inst) # define lh_FUNCTION_retrieve(lh,inst) LHM_lh_retrieve(FUNCTION,lh,inst) @@ -2581,6 +2709,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_FUNCTION_stats_bio(lh,out) \ LHM_lh_stats_bio(FUNCTION,lh,out) # define lh_FUNCTION_free(lh) LHM_lh_free(FUNCTION,lh) + # define lh_MEM_new() LHM_lh_new(MEM,mem) # define lh_MEM_insert(lh,inst) LHM_lh_insert(MEM,lh,inst) # define lh_MEM_retrieve(lh,inst) LHM_lh_retrieve(MEM,lh,inst) @@ -2598,6 +2727,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_MEM_stats_bio(lh,out) \ LHM_lh_stats_bio(MEM,lh,out) # define lh_MEM_free(lh) LHM_lh_free(MEM,lh) + # define lh_OBJ_NAME_new() LHM_lh_new(OBJ_NAME,obj_name) # define lh_OBJ_NAME_insert(lh,inst) LHM_lh_insert(OBJ_NAME,lh,inst) # define lh_OBJ_NAME_retrieve(lh,inst) LHM_lh_retrieve(OBJ_NAME,lh,inst) @@ -2615,6 +2745,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_OBJ_NAME_stats_bio(lh,out) \ LHM_lh_stats_bio(OBJ_NAME,lh,out) # define lh_OBJ_NAME_free(lh) LHM_lh_free(OBJ_NAME,lh) + # define lh_OPENSSL_CSTRING_new() LHM_lh_new(OPENSSL_CSTRING,openssl_cstring) # define lh_OPENSSL_CSTRING_insert(lh,inst) LHM_lh_insert(OPENSSL_CSTRING,lh,inst) # define lh_OPENSSL_CSTRING_retrieve(lh,inst) LHM_lh_retrieve(OPENSSL_CSTRING,lh,inst) @@ -2632,6 +2763,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_OPENSSL_CSTRING_stats_bio(lh,out) \ LHM_lh_stats_bio(OPENSSL_CSTRING,lh,out) # define lh_OPENSSL_CSTRING_free(lh) LHM_lh_free(OPENSSL_CSTRING,lh) + # define lh_OPENSSL_STRING_new() LHM_lh_new(OPENSSL_STRING,openssl_string) # define lh_OPENSSL_STRING_insert(lh,inst) LHM_lh_insert(OPENSSL_STRING,lh,inst) # define lh_OPENSSL_STRING_retrieve(lh,inst) LHM_lh_retrieve(OPENSSL_STRING,lh,inst) @@ -2649,6 +2781,7 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_OPENSSL_STRING_stats_bio(lh,out) \ LHM_lh_stats_bio(OPENSSL_STRING,lh,out) # define lh_OPENSSL_STRING_free(lh) LHM_lh_free(OPENSSL_STRING,lh) + # define lh_SSL_SESSION_new() LHM_lh_new(SSL_SESSION,ssl_session) # define lh_SSL_SESSION_insert(lh,inst) LHM_lh_insert(SSL_SESSION,lh,inst) # define lh_SSL_SESSION_retrieve(lh,inst) LHM_lh_retrieve(SSL_SESSION,lh,inst) @@ -2666,8 +2799,8 @@ DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) # define lh_SSL_SESSION_stats_bio(lh,out) \ LHM_lh_stats_bio(SSL_SESSION,lh,out) # define lh_SSL_SESSION_free(lh) LHM_lh_free(SSL_SESSION,lh) -/* End of util/mkstack.pl block, you may now edit :-) */ -#ifdef __cplusplus + +# ifdef __cplusplus } +# endif #endif -#endif /* !defined HEADER_SAFESTACK_H */ diff --git a/crypto/store/str_lib.c b/crypto/store/str_lib.c index 227b797b59..d683fd8ecd 100644 --- a/crypto/store/str_lib.c +++ b/crypto/store/str_lib.c @@ -1187,8 +1187,6 @@ void STORE_OBJECT_free(STORE_OBJECT *data) OPENSSL_free(data); } -IMPLEMENT_STACK_OF(STORE_OBJECT*) - struct STORE_attr_info_st { unsigned char set[(STORE_ATTR_TYPE_NUM + 8) / 8]; union { diff --git a/crypto/ui/ui_lib.c b/crypto/ui/ui_lib.c index 2d6b7de73b..06e6cd849c 100644 --- a/crypto/ui/ui_lib.c +++ b/crypto/ui/ui_lib.c @@ -65,8 +65,6 @@ #include <openssl/err.h> #include "ui_locl.h" -IMPLEMENT_STACK_OF(UI_STRING_ST) - static const UI_METHOD *default_UI_meth = NULL; UI *UI_new(void) diff --git a/crypto/x509/x509_ext.c b/crypto/x509/x509_ext.c index fb4e311d71..1790b1b8c3 100644 --- a/crypto/x509/x509_ext.c +++ b/crypto/x509/x509_ext.c @@ -206,6 +206,4 @@ int X509_REVOKED_add1_ext_i2d(X509_REVOKED *x, int nid, void *value, int crit, return X509V3_add1_i2d(&x->extensions, nid, value, crit, flags); } -IMPLEMENT_STACK_OF(X509_EXTENSION) - IMPLEMENT_ASN1_SET_OF(X509_EXTENSION) diff --git a/crypto/x509/x509_lu.c b/crypto/x509/x509_lu.c index 85fb59cb13..f77e59df37 100644 --- a/crypto/x509/x509_lu.c +++ b/crypto/x509/x509_lu.c @@ -717,7 +717,3 @@ X509_STORE *X509_STORE_CTX_get0_store(X509_STORE_CTX *ctx) { return ctx->ctx; } - -IMPLEMENT_STACK_OF(X509_LOOKUP) - -IMPLEMENT_STACK_OF(X509_OBJECT) diff --git a/crypto/x509/x509_trs.c b/crypto/x509/x509_trs.c index 11e0763403..92ea2b586f 100644 --- a/crypto/x509/x509_trs.c +++ b/crypto/x509/x509_trs.c @@ -96,8 +96,6 @@ static X509_TRUST trstandard[] = { #define X509_TRUST_COUNT (sizeof(trstandard)/sizeof(X509_TRUST)) -IMPLEMENT_STACK_OF(X509_TRUST) - static STACK_OF(X509_TRUST) *trtable = NULL; static int tr_cmp(const X509_TRUST *const *a, const X509_TRUST *const *b) diff --git a/crypto/x509/x509_vfy.c b/crypto/x509/x509_vfy.c index 31bb95b688..22c1f6859f 100644 --- a/crypto/x509/x509_vfy.c +++ b/crypto/x509/x509_vfy.c @@ -2403,12 +2403,6 @@ void X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param) ctx->param = param; } -IMPLEMENT_STACK_OF(X509) - IMPLEMENT_ASN1_SET_OF(X509) -IMPLEMENT_STACK_OF(X509_NAME) - -IMPLEMENT_STACK_OF(X509_ATTRIBUTE) - IMPLEMENT_ASN1_SET_OF(X509_ATTRIBUTE) diff --git a/crypto/x509v3/v3_cpols.c b/crypto/x509v3/v3_cpols.c index 476d51c0bd..139b8f273a 100644 --- a/crypto/x509v3/v3_cpols.c +++ b/crypto/x509v3/v3_cpols.c @@ -472,8 +472,3 @@ void X509_POLICY_NODE_print(BIO *out, X509_POLICY_NODE *node, int indent) else BIO_printf(out, "%*sNo Qualifiers\n", indent + 2, ""); } - - -IMPLEMENT_STACK_OF(X509_POLICY_NODE) - -IMPLEMENT_STACK_OF(X509_POLICY_DATA) diff --git a/crypto/x509v3/v3_crld.c b/crypto/x509v3/v3_crld.c index d3e1d1b057..0dbed9f96b 100644 --- a/crypto/x509v3/v3_crld.c +++ b/crypto/x509v3/v3_crld.c @@ -341,8 +341,6 @@ static void *v2i_crld(const X509V3_EXT_METHOD *method, return NULL; } -IMPLEMENT_STACK_OF(DIST_POINT) - IMPLEMENT_ASN1_SET_OF(DIST_POINT) static int dpn_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it, diff --git a/crypto/x509v3/v3_lib.c b/crypto/x509v3/v3_lib.c index b5598c9a3e..90ddd86f40 100644 --- a/crypto/x509v3/v3_lib.c +++ b/crypto/x509v3/v3_lib.c @@ -337,5 +337,3 @@ int X509V3_add1_i2d(STACK_OF(X509_EXTENSION) **x, int nid, void *value, X509V3err(X509V3_F_X509V3_ADD1_I2D, errcode); return 0; } - -IMPLEMENT_STACK_OF(X509V3_EXT_METHOD) diff --git a/crypto/x509v3/v3_purp.c b/crypto/x509v3/v3_purp.c index b748e98b2c..d51f93f3f7 100644 --- a/crypto/x509v3/v3_purp.c +++ b/crypto/x509v3/v3_purp.c @@ -110,8 +110,6 @@ static X509_PURPOSE xstandard[] = { #define X509_PURPOSE_COUNT (sizeof(xstandard)/sizeof(X509_PURPOSE)) -IMPLEMENT_STACK_OF(X509_PURPOSE) - static STACK_OF(X509_PURPOSE) *xptable = NULL; static int xp_cmp(const X509_PURPOSE *const *a, const X509_PURPOSE *const *b) diff --git a/crypto/x509v3/v3_sxnet.c b/crypto/x509v3/v3_sxnet.c index a4e6a93e0b..6bff278d21 100644 --- a/crypto/x509v3/v3_sxnet.c +++ b/crypto/x509v3/v3_sxnet.c @@ -268,6 +268,4 @@ ASN1_OCTET_STRING *SXNET_get_id_INTEGER(SXNET *sx, ASN1_INTEGER *zone) return NULL; } -IMPLEMENT_STACK_OF(SXNETID) - IMPLEMENT_ASN1_SET_OF(SXNETID) diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 4289fb9581..2bb1866b8c 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -3599,8 +3599,4 @@ void *SSL_CTX_get0_security_ex_data(const SSL_CTX *ctx) return ctx->cert->sec_ex; } -IMPLEMENT_STACK_OF(SSL_CIPHER) - -IMPLEMENT_STACK_OF(SSL_COMP) - IMPLEMENT_OBJ_BSEARCH_GLOBAL_CMP_FN(SSL_CIPHER, SSL_CIPHER, ssl_cipher_id); diff --git a/util/mkstack.pl b/util/mkstack.pl index 2bd96cd0c1..5295cddcb6 100755 --- a/util/mkstack.pl +++ b/util/mkstack.pl @@ -1,194 +1,396 @@ #!/usr/local/bin/perl -w -# This is a utility that searches out "DECLARE_STACK_OF()" -# declarations in .h and .c files, and updates/creates/replaces -# the corresponding macro declarations in crypto/stack/safestack.h. -# As it's not generally possible to have macros that generate macros, -# we need to control this from the "outside", here in this script. -# -# Geoff Thorpe, June, 2000 (with massive Perl-hacking -# help from Steve Robb) - -my $safestack = "crypto/stack/safestack"; - -my $do_write; -while (@ARGV) { - my $arg = $ARGV[0]; - if($arg eq "-write") { - $do_write = 1; - } - shift @ARGV; -} +# Search out "DECLARE_STACK_OF()" # declarations in .h and .c files, +# and create corresponding macro declarations for crypto/stack/safestack.h. + +my $safestack = "crypto/stack/safestack.h"; +my $do_write = 0; +foreach ( @ARGV ) { + $do_write = 1 if $_ eq "-write"; +} -@source = (<crypto/*.[ch]>, <crypto/*/*.[ch]>, <ssl/*.[ch]>, <apps/*.[ch]>); +my @stacklst; +my @sstacklst; +my @asn1setlst; +my @p12stklst; +my @lhashlst; +my @source = (<crypto/*.[ch]>, <crypto/*/*.[ch]>, <ssl/*.[ch]>, <apps/*.[ch]>); foreach $file (@source) { - next if -l $file; - - # Open the .c/.h file for reading - open(IN, "< $file") || die "Can't open $file for reading: $!"; - - while(<IN>) { - if (/^DECLARE_STACK_OF\(([^)]+)\)/) { - push @stacklst, $1; - } - if (/^DECLARE_SPECIAL_STACK_OF\(([^,\s]+)\s*,\s*([^>\s]+)\)/) { - push @sstacklst, [$1, $2]; - } - if (/^DECLARE_ASN1_SET_OF\(([^)]+)\)/) { - push @asn1setlst, $1; - } - if (/^DECLARE_PKCS12_STACK_OF\(([^)]+)\)/) { - push @p12stklst, $1; - } - if (/^DECLARE_LHASH_OF\(([^)]+)\)/) { - push @lhashlst, $1; - } - } - close(IN); + next if -l $file; + + # Open the .c/.h file for reading + open(IN, "< $file") || die "Can't open $file for reading, $!"; + + while(<IN>) { + next unless /^DECLARE_/; + if (/^DECLARE_STACK_OF\(([^)]+)\)/) { + push @stacklst, $1; + } + elsif (/^DECLARE_SPECIAL_STACK_OF\(([^,\s]+)\s*,\s*([^>\s]+)\)/) { + push @sstacklst, [$1, $2]; + } + elsif (/^DECLARE_ASN1_SET_OF\(([^)]+)\)/) { + push @asn1setlst, $1; + } + elsif (/^DECLARE_PKCS12_STACK_OF\(([^)]+)\)/) { + push @p12stklst, $1; + } + elsif (/^DECLARE_LHASH_OF\(([^)]+)\)/) { + push @lhashlst, $1; + } + } + close(IN); } +my $new_stackfile = <<'EOF'; +/* automatically generated by util/mkstack.pl */ +/* ==================================================================== + * Copyright (c) 1999 The OpenSSL Project. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * 3. All advertising materials mentioning features or use of this + * software must display the following acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" + * + * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to + * endorse or promote products derived from this software without + * prior written permission. For written permission, please contact + * openssl-core@openssl.org. + * + * 5. Products derived from this software may not be called "OpenSSL" + * nor may "OpenSSL" appear in their names without prior written + * permission of the OpenSSL Project. + * + * 6. Redistributions of any form whatsoever must retain the following + * acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit (http://www.openssl.org/)" + * + * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY + * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED + * OF THE POSSIBILITY OF SUCH DAMAGE. + * ==================================================================== + * + * This product includes cryptographic software written by Eric Young + * (eay@cryptsoft.com). This product includes software written by Tim + * Hudson (tjh@cryptsoft.com). + * + */ + +#ifndef HEADER_SAFESTACK_H +# define HEADER_SAFESTACK_H + +# include <openssl/stack.h> + +#ifdef __cplusplus +extern "C" { +#endif + +# ifndef CHECKED_PTR_OF +# define CHECKED_PTR_OF(type, p) ((void*) (1 ? p : (type*)0)) +# endif + +/* + * In C++ we get problems because an explicit cast is needed from (void *) we + * use CHECKED_STACK_OF to ensure the correct type is passed in the macros + * below. + */ + +# define CHECKED_STACK_OF(type, p) \ + ((_STACK*) (1 ? p : (STACK_OF(type)*)0)) + +# define CHECKED_SK_COPY_FUNC(type, p) \ + ((void *(*)(void *)) ((1 ? p : (type *(*)(const type *))0))) + +# define CHECKED_SK_FREE_FUNC(type, p) \ + ((void (*)(void *)) ((1 ? p : (void (*)(type *))0))) + +# define CHECKED_SK_CMP_FUNC(type, p) \ + ((int (*)(const void *, const void *)) \ + ((1 ? p : (int (*)(const type * const *, const type * const *))0))) + +# define STACK_OF(type) struct stack_st_##type +# define PREDECLARE_STACK_OF(type) STACK_OF(type); + +# define DECLARE_STACK_OF(type) \ +STACK_OF(type) \ + { \ + _STACK stack; \ + }; +# define DECLARE_SPECIAL_STACK_OF(type, type2) \ +STACK_OF(type) \ + { \ + _STACK stack; \ + }; + +/*- + * Strings are special: normally an lhash entry will point to a single + * (somewhat) mutable object. In the case of strings: + * + * a) Instead of a single char, there is an array of chars, NUL-terminated. + * b) The string may have be immutable. + * + * So, they need their own declarations. Especially important for + * type-checking tools, such as Deputy. + * + * In practice, however, it appears to be hard to have a const + * string. For now, I'm settling for dealing with the fact it is a + * string at all. + */ +typedef char *OPENSSL_STRING; +typedef const char *OPENSSL_CSTRING; + +/*- + * Confusingly, LHASH_OF(STRING) deals with char ** throughout, but + * STACK_OF(STRING) is really more like STACK_OF(char), only, as mentioned + * above, instead of a single char each entry is a NUL-terminated array of + * chars. So, we have to implement STRING specially for STACK_OF. This is + * dealt with in the autogenerated macros below. + */ +DECLARE_SPECIAL_STACK_OF(OPENSSL_STRING, char) + +/* + * Similarly, we sometimes use a block of characters, NOT nul-terminated. + * These should also be distinguished from "normal" stacks. + */ +typedef void *OPENSSL_BLOCK; +DECLARE_SPECIAL_STACK_OF(OPENSSL_BLOCK, void) + +/* + * This file is automatically generated by util/mkstack.pl + * Do not edit! + */ + +/* + * SKM_sk_... stack macros are internal to safestack.h: never use them + * directly, use sk_<type>_... instead + */ +# define SKM_sk_new(type, cmp) \ + ((STACK_OF(type) *)sk_new(CHECKED_SK_CMP_FUNC(type, cmp))) +# define SKM_sk_new_null(type) \ + ((STACK_OF(type) *)sk_new_null()) +# define SKM_sk_free(type, st) \ + sk_free(CHECKED_STACK_OF(type, st)) +# define SKM_sk_num(type, st) \ + sk_num(CHECKED_STACK_OF(type, st)) +# define SKM_sk_value(type, st,i) \ + ((type *)sk_value(CHECKED_STACK_OF(type, st), i)) +# define SKM_sk_set(type, st,i,val) \ + sk_set(CHECKED_STACK_OF(type, st), i, CHECKED_PTR_OF(type, val)) +# define SKM_sk_zero(type, st) \ + sk_zero(CHECKED_STACK_OF(type, st)) +# define SKM_sk_push(type, st, val) \ + sk_push(CHECKED_STACK_OF(type, st), CHECKED_PTR_OF(type, val)) +# define SKM_sk_unshift(type, st, val) \ + sk_unshift(CHECKED_STACK_OF(type, st), CHECKED_PTR_OF(type, val)) +# define SKM_sk_find(type, st, val) \ + sk_find(CHECKED_STACK_OF(type, st), CHECKED_PTR_OF(type, val)) +# define SKM_sk_find_ex(type, st, val) \ + sk_find_ex(CHECKED_STACK_OF(type, st), \ + CHECKED_PTR_OF(type, val)) +# define SKM_sk_delete(type, st, i) \ + (type *)sk_delete(CHECKED_STACK_OF(type, st), i) +# define SKM_sk_delete_ptr(type, st, ptr) \ + (type *)sk_delete_ptr(CHECKED_STACK_OF(type, st), CHECKED_PTR_OF(type, ptr)) +# define SKM_sk_insert(type, st,val, i) \ + sk_insert(CHECKED_STACK_OF(type, st), CHECKED_PTR_OF(type, val), i) +# define SKM_sk_set_cmp_func(type, st, cmp) \ + ((int (*)(const type * const *,const type * const *)) \ + sk_set_cmp_func(CHECKED_STACK_OF(type, st), CHECKED_SK_CMP_FUNC(type, cmp))) +# define SKM_sk_dup(type, st) \ + (STACK_OF(type) *)sk_dup(CHECKED_STACK_OF(type, st)) +# define SKM_sk_pop_free(type, st, free_func) \ + sk_pop_free(CHECKED_STACK_OF(type, st), CHECKED_SK_FREE_FUNC(type, free_func)) +# define SKM_sk_deep_copy(type, st, copy_func, free_func) \ + (STACK_OF(type) *)sk_deep_copy(CHECKED_STACK_OF(type, st), CHECKED_SK_COPY_FUNC(type, copy_func), CHECKED_SK_FREE_FUNC(type, free_func)) +# define SKM_sk_shift(type, st) \ + (type *)sk_shift(CHECKED_STACK_OF(type, st)) +# define SKM_sk_pop(type, st) \ + (type *)sk_pop(CHECKED_STACK_OF(type, st)) +# define SKM_sk_sort(type, st) \ + sk_sort(CHECKED_STACK_OF(type, st)) +# define SKM_sk_is_sorted(type, st) \ + sk_is_sorted(CHECKED_STACK_OF(type, st)) +# define SKM_ASN1_SET_OF_d2i(type, st, pp, length, d2i_func, free_func, ex_tag, ex_class) \ + (STACK_OF(type) *)d2i_ASN1_SET( \ + (STACK_OF(OPENSSL_BLOCK) **)CHECKED_PTR_OF(STACK_OF(type)*, st), \ + pp, length, \ + CHECKED_D2I_OF(type, d2i_func), \ + CHECKED_SK_FREE_FUNC(type, free_func), \ + ex_tag, ex_class) +# define SKM_ASN1_SET_OF_i2d(type, st, pp, i2d_func, ex_tag, ex_class, is_set) \ + i2d_ASN1_SET(CHECKED_STACK_OF(type, st), pp, \ + CHECKED_I2D_OF(type, i2d_func), \ + ex_tag, ex_class, is_set) + +# define SKM_ASN1_seq_pack(type, st, i2d_func, buf, len) \ + ASN1_seq_pack(CHECKED_PTR_OF(STACK_OF(type), st), \ + CHECKED_I2D_OF(type, i2d_func), buf, len) +# define SKM_ASN1_seq_unpack(type, buf, len, d2i_func, free_func) \ + (STACK_OF(type) *)ASN1_seq_unpack(buf, \ + len, CHECKED_D2I_OF(type, d2i_func), \ + CHECKED_SK_FREE_FUNC(type, free_func)) +# define SKM_PKCS12_decrypt_d2i(type, algor, d2i_func, free_func, pass, passlen, oct, seq) \ + (STACK_OF(type) *)PKCS12_decrypt_d2i(algor, \ + CHECKED_D2I_OF(type, d2i_func), \ + CHECKED_SK_FREE_FUNC(type, free_func), \ + pass, passlen, oct, seq) +EOF + +my $old_stackfile; +{ + local $/ = undef; + open(IN, "$safestack") || die "Can't open $safestack, $!"; + $old_stackfile = <IN>; + close(IN); +} -my $old_stackfile = ""; -my $new_stackfile = ""; -my $inside_block = 0; my $type_thing; +foreach $type_thing (sort @stacklst) { + $new_stackfile .= <<EOF; -open(IN, "< $safestack.h") || die "Can't open input file: $!"; -while(<IN>) { - $old_stackfile .= $_; - - if (m|^/\* This block of defines is updated by util/mkstack.pl, please do not touch! \*/|) { - $inside_block = 1; - } - if (m|^/\* End of util/mkstack.pl block, you may now edit :-\) \*/|) { - $inside_block = 0; - } elsif ($inside_block == 0) { - $new_stackfile .= $_; - } - next if($inside_block != 1); - $new_stackfile .= "/* This block of defines is updated by util/mkstack.pl, please do not touch! */"; - - foreach $type_thing (sort @stacklst) { - $new_stackfile .= <<EOF; - -#define sk_${type_thing}_new(cmp) SKM_sk_new($type_thing, (cmp)) -#define sk_${type_thing}_new_null() SKM_sk_new_null($type_thing) -#define sk_${type_thing}_free(st) SKM_sk_free($type_thing, (st)) -#define sk_${type_thing}_num(st) SKM_sk_num($type_thing, (st)) -#define sk_${type_thing}_value(st, i) SKM_sk_value($type_thing, (st), (i)) -#define sk_${type_thing}_set(st, i, val) SKM_sk_set($type_thing, (st), (i), (val)) -#define sk_${type_thing}_zero(st) SKM_sk_zero($type_thing, (st)) -#define sk_${type_thing}_push(st, val) SKM_sk_push($type_thing, (st), (val)) -#define sk_${type_thing}_unshift(st, val) SKM_sk_unshift($type_thing, (st), (val)) -#define sk_${type_thing}_find(st, val) SKM_sk_find($type_thing, (st), (val)) -#define sk_${type_thing}_find_ex(st, val) SKM_sk_find_ex($type_thing, (st), (val)) -#define sk_${type_thing}_delete(st, i) SKM_sk_delete($type_thing, (st), (i)) -#define sk_${type_thing}_delete_ptr(st, ptr) SKM_sk_delete_ptr($type_thing, (st), (ptr)) -#define sk_${type_thing}_insert(st, val, i) SKM_sk_insert($type_thing, (st), (val), (i)) -#define sk_${type_thing}_set_cmp_func(st, cmp) SKM_sk_set_cmp_func($type_thing, (st), (cmp)) -#define sk_${type_thing}_dup(st) SKM_sk_dup($type_thing, st) -#define sk_${type_thing}_pop_free(st, free_func) SKM_sk_pop_free($type_thing, (st), (free_func)) -#define sk_${type_thing}_deep_copy(st, copy_func, free_func) SKM_sk_deep_copy($type_thing, (st), (copy_func), (free_func)) -#define sk_${type_thing}_shift(st) SKM_sk_shift($type_thing, (st)) -#define sk_${type_thing}_pop(st) SKM_sk_pop($type_thing, (st)) -#define sk_${type_thing}_sort(st) SKM_sk_sort($type_thing, (st)) -#define sk_${type_thing}_is_sorted(st) SKM_sk_is_sorted($type_thing, (st)) +# define sk_${type_thing}_new(cmp) SKM_sk_new($type_thing, (cmp)) +# define sk_${type_thing}_new_null() SKM_sk_new_null($type_thing) +# define sk_${type_thing}_free(st) SKM_sk_free($type_thing, (st)) +# define sk_${type_thing}_num(st) SKM_sk_num($type_thing, (st)) +# define sk_${type_thing}_value(st, i) SKM_sk_value($type_thing, (st), (i)) +# define sk_${type_thing}_set(st, i, val) SKM_sk_set($type_thing, (st), (i), (val)) +# define sk_${type_thing}_zero(st) SKM_sk_zero($type_thing, (st)) +# define sk_${type_thing}_push(st, val) SKM_sk_push($type_thing, (st), (val)) +# define sk_${type_thing}_unshift(st, val) SKM_sk_unshift($type_thing, (st), (val)) +# define sk_${type_thing}_find(st, val) SKM_sk_find($type_thing, (st), (val)) +# define sk_${type_thing}_find_ex(st, val) SKM_sk_find_ex($type_thing, (st), (val)) +# define sk_${type_thing}_delete(st, i) SKM_sk_delete($type_thing, (st), (i)) +# define sk_${type_thing}_delete_ptr(st, ptr) SKM_sk_delete_ptr($type_thing, (st), (ptr)) +# define sk_${type_thing}_insert(st, val, i) SKM_sk_insert($type_thing, (st), (val), (i)) +# define sk_${type_thing}_set_cmp_func(st, cmp) SKM_sk_set_cmp_func($type_thing, (st), (cmp)) +# define sk_${type_thing}_dup(st) SKM_sk_dup($type_thing, st) +# define sk_${type_thing}_pop_free(st, free_func) SKM_sk_pop_free($type_thing, (st), (free_func)) +# define sk_${type_thing}_deep_copy(st, copy_func, free_func) SKM_sk_deep_copy($type_thing, (st), (copy_func), (free_func)) +# define sk_${type_thing}_shift(st) SKM_sk_shift($type_thing, (st)) +# define sk_${type_thing}_pop(st) SKM_sk_pop($type_thing, (st)) +# define sk_${type_thing}_sort(st) SKM_sk_sort($type_thing, (st)) +# define sk_${type_thing}_is_sorted(st) SKM_sk_is_sorted($type_thing, (st)) EOF - } - - foreach $type_thing (sort @sstacklst) { - my $t1 = $type_thing->[0]; - my $t2 = $type_thing->[1]; - $new_stackfile .= <<EOF; - -#define sk_${t1}_new(cmp) ((STACK_OF($t1) *)sk_new(CHECKED_SK_CMP_FUNC($t2, cmp))) -#define sk_${t1}_new_null() ((STACK_OF($t1) *)sk_new_null()) -#define sk_${t1}_push(st, val) sk_push(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val)) -#define sk_${t1}_find(st, val) sk_find(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val)) -#define sk_${t1}_value(st, i) (($t1)sk_value(CHECKED_STACK_OF($t1, st), i)) -#define sk_${t1}_num(st) SKM_sk_num($t1, st) -#define sk_${t1}_pop_free(st, free_func) sk_pop_free(CHECKED_STACK_OF($t1, st), CHECKED_SK_FREE_FUNC($t2, free_func)) -#define sk_${t1}_deep_copy(st, copy_func, free_func) ((STACK_OF($t1) *)sk_deep_copy(CHECKED_STACK_OF($t1, st), CHECKED_SK_COPY_FUNC($t2, copy_func), CHECKED_SK_FREE_FUNC($t2, free_func))) -#define sk_${t1}_insert(st, val, i) sk_insert(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val), i) -#define sk_${t1}_free(st) SKM_sk_free(${t1}, st) -#define sk_${t1}_set(st, i, val) sk_set(CHECKED_STACK_OF($t1, st), i, CHECKED_PTR_OF($t2, val)) -#define sk_${t1}_zero(st) SKM_sk_zero($t1, (st)) -#define sk_${t1}_unshift(st, val) sk_unshift(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val)) -#define sk_${t1}_find_ex(st, val) sk_find_ex((_STACK *)CHECKED_CONST_PTR_OF(STACK_OF($t1), st), CHECKED_CONST_PTR_OF($t2, val)) -#define sk_${t1}_delete(st, i) SKM_sk_delete($t1, (st), (i)) -#define sk_${t1}_delete_ptr(st, ptr) ($t1 *)sk_delete_ptr(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, ptr)) -#define sk_${t1}_set_cmp_func(st, cmp) \\ - ((int (*)(const $t2 * const *,const $t2 * const *)) \\ - sk_set_cmp_func(CHECKED_STACK_OF($t1, st), CHECKED_SK_CMP_FUNC($t2, cmp))) -#define sk_${t1}_dup(st) SKM_sk_dup($t1, st) -#define sk_${t1}_shift(st) SKM_sk_shift($t1, (st)) -#define sk_${t1}_pop(st) ($t2 *)sk_pop(CHECKED_STACK_OF($t1, st)) -#define sk_${t1}_sort(st) SKM_sk_sort($t1, (st)) -#define sk_${t1}_is_sorted(st) SKM_sk_is_sorted($t1, (st)) +} +foreach $type_thing (sort @sstacklst) { + my $t1 = $type_thing->[0]; + my $t2 = $type_thing->[1]; + $new_stackfile .= <<EOF; + +# define sk_${t1}_new(cmp) ((STACK_OF($t1) *)sk_new(CHECKED_SK_CMP_FUNC($t2, cmp))) +# define sk_${t1}_new_null() ((STACK_OF($t1) *)sk_new_null()) +# define sk_${t1}_push(st, val) sk_push(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val)) +# define sk_${t1}_find(st, val) sk_find(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val)) +# define sk_${t1}_value(st, i) (($t1)sk_value(CHECKED_STACK_OF($t1, st), i)) +# define sk_${t1}_num(st) SKM_sk_num($t1, st) +# define sk_${t1}_pop_free(st, free_func) sk_pop_free(CHECKED_STACK_OF($t1, st), CHECKED_SK_FREE_FUNC($t2, free_func)) +# define sk_${t1}_deep_copy(st, copy_func, free_func) ((STACK_OF($t1) *)sk_deep_copy(CHECKED_STACK_OF($t1, st), CHECKED_SK_COPY_FUNC($t2, copy_func), CHECKED_SK_FREE_FUNC($t2, free_func))) +# define sk_${t1}_insert(st, val, i) sk_insert(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val), i) +# define sk_${t1}_free(st) SKM_sk_free(${t1}, st) +# define sk_${t1}_set(st, i, val) sk_set(CHECKED_STACK_OF($t1, st), i, CHECKED_PTR_OF($t2, val)) +# define sk_${t1}_zero(st) SKM_sk_zero($t1, (st)) +# define sk_${t1}_unshift(st, val) sk_unshift(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, val)) +# define sk_${t1}_find_ex(st, val) sk_find_ex((_STACK *)CHECKED_CONST_PTR_OF(STACK_OF($t1), st), CHECKED_CONST_PTR_OF($t2, val)) +# define sk_${t1}_delete(st, i) SKM_sk_delete($t1, (st), (i)) +# define sk_${t1}_delete_ptr(st, ptr) ($t1 *)sk_delete_ptr(CHECKED_STACK_OF($t1, st), CHECKED_PTR_OF($t2, ptr)) +# define sk_${t1}_set_cmp_func(st, cmp) \\ + ((int (*)(const $t2 * const *,const $t2 * const *)) \\ + sk_set_cmp_func(CHECKED_STACK_OF($t1, st), CHECKED_SK_CMP_FUNC($t2, cmp))) +# define sk_${t1}_dup(st) SKM_sk_dup($t1, st) +# define sk_${t1}_shift(st) SKM_sk_shift($t1, (st)) +# define sk_${t1}_pop(st) ($t2 *)sk_pop(CHECKED_STACK_OF($t1, st)) +# define sk_${t1}_sort(st) SKM_sk_sort($t1, (st)) +# define sk_${t1}_is_sorted(st) SKM_sk_is_sorted($t1, (st)) EOF - } - - foreach $type_thing (sort @asn1setlst) { - $new_stackfile .= <<EOF; - -#define d2i_ASN1_SET_OF_${type_thing}(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \\ - SKM_ASN1_SET_OF_d2i($type_thing, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) -#define i2d_ASN1_SET_OF_${type_thing}(st, pp, i2d_func, ex_tag, ex_class, is_set) \\ - SKM_ASN1_SET_OF_i2d($type_thing, (st), (pp), (i2d_func), (ex_tag), (ex_class), (is_set)) -#define ASN1_seq_pack_${type_thing}(st, i2d_func, buf, len) \\ - SKM_ASN1_seq_pack($type_thing, (st), (i2d_func), (buf), (len)) -#define ASN1_seq_unpack_${type_thing}(buf, len, d2i_func, free_func) \\ - SKM_ASN1_seq_unpack($type_thing, (buf), (len), (d2i_func), (free_func)) +} + +foreach $type_thing (sort @asn1setlst) { + $new_stackfile .= <<EOF; + +# define d2i_ASN1_SET_OF_${type_thing}(st, pp, length, d2i_func, free_func, ex_tag, ex_class) \\ + SKM_ASN1_SET_OF_d2i($type_thing, (st), (pp), (length), (d2i_func), (free_func), (ex_tag), (ex_class)) +# define i2d_ASN1_SET_OF_${type_thing}(st, pp, i2d_func, ex_tag, ex_class, is_set) \\ + SKM_ASN1_SET_OF_i2d($type_thing, (st), (pp), (i2d_func), (ex_tag), (ex_class), (is_set)) +# define ASN1_seq_pack_${type_thing}(st, i2d_func, buf, len) \\ + SKM_ASN1_seq_pack($type_thing, (st), (i2d_func), (buf), (len)) +# define ASN1_seq_unpack_${type_thing}(buf, len, d2i_func, free_func) \\ + SKM_ASN1_seq_unpack($type_thing, (buf), (len), (d2i_func), (free_func)) EOF - } - foreach $type_thing (sort @p12stklst) { - $new_stackfile .= <<EOF; +} -#define PKCS12_decrypt_d2i_${type_thing}(algor, d2i_func, free_func, pass, passlen, oct, seq) \\ - SKM_PKCS12_decrypt_d2i($type_thing, (algor), (d2i_func), (free_func), (pass), (passlen), (oct), (seq)) +foreach $type_thing (sort @p12stklst) { + $new_stackfile .= <<EOF; + +# define PKCS12_decrypt_d2i_${type_thing}(algor, d2i_func, free_func, pass, passlen, oct, seq) \\ + SKM_PKCS12_decrypt_d2i($type_thing, (algor), (d2i_func), (free_func), (pass), (passlen), (oct), (seq)) EOF - } - - foreach $type_thing (sort @lhashlst) { - my $lc_tt = lc $type_thing; - $new_stackfile .= <<EOF; - -#define lh_${type_thing}_new() LHM_lh_new(${type_thing},${lc_tt}) -#define lh_${type_thing}_insert(lh,inst) LHM_lh_insert(${type_thing},lh,inst) -#define lh_${type_thing}_retrieve(lh,inst) LHM_lh_retrieve(${type_thing},lh,inst) -#define lh_${type_thing}_delete(lh,inst) LHM_lh_delete(${type_thing},lh,inst) -#define lh_${type_thing}_doall(lh,fn) LHM_lh_doall(${type_thing},lh,fn) -#define lh_${type_thing}_doall_arg(lh,fn,arg_type,arg) \\ +} + +foreach $type_thing (sort @lhashlst) { + my $lc_tt = lc $type_thing; + $new_stackfile .= <<EOF; + +# define lh_${type_thing}_new() LHM_lh_new(${type_thing},${lc_tt}) +# define lh_${type_thing}_insert(lh,inst) LHM_lh_insert(${type_thing},lh,inst) +# define lh_${type_thing}_retrieve(lh,inst) LHM_lh_retrieve(${type_thing},lh,inst) +# define lh_${type_thing}_delete(lh,inst) LHM_lh_delete(${type_thing},lh,inst) +# define lh_${type_thing}_doall(lh,fn) LHM_lh_doall(${type_thing},lh,fn) +# define lh_${type_thing}_doall_arg(lh,fn,arg_type,arg) \\ LHM_lh_doall_arg(${type_thing},lh,fn,arg_type,arg) -#define lh_${type_thing}_error(lh) LHM_lh_error(${type_thing},lh) -#define lh_${type_thing}_num_items(lh) LHM_lh_num_items(${type_thing},lh) -#define lh_${type_thing}_down_load(lh) LHM_lh_down_load(${type_thing},lh) -#define lh_${type_thing}_node_stats_bio(lh,out) \\ +# define lh_${type_thing}_error(lh) LHM_lh_error(${type_thing},lh) +# define lh_${type_thing}_num_items(lh) LHM_lh_num_items(${type_thing},lh) +# define lh_${type_thing}_down_load(lh) LHM_lh_down_load(${type_thing},lh) +# define lh_${type_thing}_node_stats_bio(lh,out) \\ LHM_lh_node_stats_bio(${type_thing},lh,out) -#define lh_${type_thing}_node_usage_stats_bio(lh,out) \\ +# define lh_${type_thing}_node_usage_stats_bio(lh,out) \\ LHM_lh_node_usage_stats_bio(${type_thing},lh,out) -#define lh_${type_thing}_stats_bio(lh,out) \\ +# define lh_${type_thing}_stats_bio(lh,out) \\ LHM_lh_stats_bio(${type_thing},lh,out) -#define lh_${type_thing}_free(lh) LHM_lh_free(${type_thing},lh) +# define lh_${type_thing}_free(lh) LHM_lh_free(${type_thing},lh) EOF - } - - $new_stackfile .= "/* End of util/mkstack.pl block, you may now edit :-) */\n"; - $inside_block = 2; } +$new_stackfile .= <<'EOF'; -if ($new_stackfile eq $old_stackfile) { - print "No changes to $safestack.h.\n"; - exit 0; # avoid unnecessary rebuild +# ifdef __cplusplus } +# endif +#endif +EOF -if ($do_write) { - print "Writing new $safestack.h.\n"; - open OUT, ">$safestack.h" || die "Can't open output file"; - print OUT $new_stackfile; - close OUT; +if ($new_stackfile eq $old_stackfile) { + print "No changes to $safestack.\n"; } +elsif ($do_write) { + print "Writing new $safestack.\n"; + open OUT, ">$safestack" || die "Can't open $safestack for writing, $!"; + print OUT $new_stackfile; + close OUT; +} + +exit 0; |