From: beck Date: Mon, 8 Jul 2024 14:52:31 +0000 (+0000) Subject: Hide global _it variables in asn1.h X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=7523ec26178c68c06fc1f025204fb3301df44cec;p=openbsd Hide global _it variables in asn1.h ok tb@ --- diff --git a/lib/libcrypto/Symbols.namespace b/lib/libcrypto/Symbols.namespace index f876f3721e2..8e0760f8e61 100644 --- a/lib/libcrypto/Symbols.namespace +++ b/lib/libcrypto/Symbols.namespace @@ -3271,3 +3271,26 @@ _libre_NETSCAPE_SPKI_it _libre_NETSCAPE_SPKAC_it _libre_PBEPARAM_it _libre_PKCS8_PRIV_KEY_INFO_it +_libre_ASN1_SEQUENCE_ANY_it +_libre_ASN1_SET_ANY_it +_libre_ASN1_ANY_it +_libre_ASN1_OBJECT_it +_libre_ASN1_BIT_STRING_it +_libre_ASN1_INTEGER_it +_libre_ASN1_ENUMERATED_it +_libre_ASN1_OCTET_STRING_it +_libre_ASN1_VISIBLESTRING_it +_libre_ASN1_UNIVERSALSTRING_it +_libre_ASN1_UTF8STRING_it +_libre_ASN1_NULL_it +_libre_ASN1_BMPSTRING_it +_libre_ASN1_PRINTABLE_it +_libre_DIRECTORYSTRING_it +_libre_DISPLAYTEXT_it +_libre_ASN1_PRINTABLESTRING_it +_libre_ASN1_T61STRING_it +_libre_ASN1_IA5STRING_it +_libre_ASN1_GENERALSTRING_it +_libre_ASN1_UTCTIME_it +_libre_ASN1_GENERALIZEDTIME_it +_libre_ASN1_TIME_it diff --git a/lib/libcrypto/asn1/a_bitstr.c b/lib/libcrypto/asn1/a_bitstr.c index 851a3a3d514..d5d00c4d44a 100644 --- a/lib/libcrypto/asn1/a_bitstr.c +++ b/lib/libcrypto/asn1/a_bitstr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_bitstr.c,v 1.42 2023/12/25 22:02:59 tb Exp $ */ +/* $OpenBSD: a_bitstr.c,v 1.43 2024/07/08 14:52:31 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -73,6 +73,7 @@ const ASN1_ITEM ASN1_BIT_STRING_it = { .utype = V_ASN1_BIT_STRING, .sname = "ASN1_BIT_STRING", }; +LCRYPTO_ALIAS(ASN1_BIT_STRING_it); ASN1_BIT_STRING * ASN1_BIT_STRING_new(void) diff --git a/lib/libcrypto/asn1/a_enum.c b/lib/libcrypto/asn1/a_enum.c index 483fe1c2712..5d3a3dd0c74 100644 --- a/lib/libcrypto/asn1/a_enum.c +++ b/lib/libcrypto/asn1/a_enum.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_enum.c,v 1.29 2023/07/05 21:23:36 beck Exp $ */ +/* $OpenBSD: a_enum.c,v 1.30 2024/07/08 14:52:31 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -78,6 +78,7 @@ const ASN1_ITEM ASN1_ENUMERATED_it = { .utype = V_ASN1_ENUMERATED, .sname = "ASN1_ENUMERATED", }; +LCRYPTO_ALIAS(ASN1_ENUMERATED_it); ASN1_ENUMERATED * ASN1_ENUMERATED_new(void) diff --git a/lib/libcrypto/asn1/a_int.c b/lib/libcrypto/asn1/a_int.c index 643ad2e0f0c..0d9b6577d79 100644 --- a/lib/libcrypto/asn1/a_int.c +++ b/lib/libcrypto/asn1/a_int.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_int.c,v 1.47 2023/07/05 21:23:36 beck Exp $ */ +/* $OpenBSD: a_int.c,v 1.48 2024/07/08 14:52:31 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -73,6 +73,7 @@ const ASN1_ITEM ASN1_INTEGER_it = { .utype = V_ASN1_INTEGER, .sname = "ASN1_INTEGER", }; +LCRYPTO_ALIAS(ASN1_INTEGER_it); ASN1_INTEGER * ASN1_INTEGER_new(void) diff --git a/lib/libcrypto/asn1/a_object.c b/lib/libcrypto/asn1/a_object.c index ed9e9287c4d..2f3ca1398fe 100644 --- a/lib/libcrypto/asn1/a_object.c +++ b/lib/libcrypto/asn1/a_object.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_object.c,v 1.54 2024/05/29 16:14:38 tb Exp $ */ +/* $OpenBSD: a_object.c,v 1.55 2024/07/08 14:52:31 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -73,6 +73,7 @@ const ASN1_ITEM ASN1_OBJECT_it = { .utype = V_ASN1_OBJECT, .sname = "ASN1_OBJECT", }; +LCRYPTO_ALIAS(ASN1_OBJECT_it); ASN1_OBJECT * ASN1_OBJECT_new(void) diff --git a/lib/libcrypto/asn1/a_octet.c b/lib/libcrypto/asn1/a_octet.c index 47eae5a4aa4..e82de62c5f1 100644 --- a/lib/libcrypto/asn1/a_octet.c +++ b/lib/libcrypto/asn1/a_octet.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_octet.c,v 1.12 2023/07/05 21:23:36 beck Exp $ */ +/* $OpenBSD: a_octet.c,v 1.13 2024/07/08 14:52:31 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -66,6 +66,7 @@ const ASN1_ITEM ASN1_OCTET_STRING_it = { .utype = V_ASN1_OCTET_STRING, .sname = "ASN1_OCTET_STRING", }; +LCRYPTO_ALIAS(ASN1_OCTET_STRING_it); ASN1_OCTET_STRING * ASN1_OCTET_STRING_new(void) diff --git a/lib/libcrypto/asn1/a_time.c b/lib/libcrypto/asn1/a_time.c index f4ddb4d5d85..15ac1af5c42 100644 --- a/lib/libcrypto/asn1/a_time.c +++ b/lib/libcrypto/asn1/a_time.c @@ -1,4 +1,4 @@ -/* $OpenBSD: a_time.c,v 1.37 2023/07/05 21:23:36 beck Exp $ */ +/* $OpenBSD: a_time.c,v 1.38 2024/07/08 14:52:31 beck Exp $ */ /* ==================================================================== * Copyright (c) 1999 The OpenSSL Project. All rights reserved. * @@ -78,6 +78,7 @@ const ASN1_ITEM ASN1_TIME_it = { .size = sizeof(ASN1_STRING), .sname = "ASN1_TIME", }; +LCRYPTO_ALIAS(ASN1_TIME_it); ASN1_TIME * ASN1_TIME_new(void) diff --git a/lib/libcrypto/asn1/tasn_typ.c b/lib/libcrypto/asn1/tasn_typ.c index 21e38858513..488d8ff44df 100644 --- a/lib/libcrypto/asn1/tasn_typ.c +++ b/lib/libcrypto/asn1/tasn_typ.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tasn_typ.c,v 1.18 2023/07/05 21:23:37 beck Exp $ */ +/* $OpenBSD: tasn_typ.c,v 1.19 2024/07/08 14:52:31 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2000. */ @@ -66,6 +66,7 @@ const ASN1_ITEM ASN1_NULL_it = { .utype = V_ASN1_NULL, .sname = "ASN1_NULL", }; +LCRYPTO_ALIAS(ASN1_NULL_it); ASN1_NULL * d2i_ASN1_NULL(ASN1_NULL **a, const unsigned char **in, long len) @@ -102,6 +103,7 @@ const ASN1_ITEM ASN1_UTF8STRING_it = { .utype = V_ASN1_UTF8STRING, .sname = "ASN1_UTF8STRING", }; +LCRYPTO_ALIAS(ASN1_UTF8STRING_it); ASN1_UTF8STRING * d2i_ASN1_UTF8STRING(ASN1_UTF8STRING **a, const unsigned char **in, long len) @@ -138,6 +140,7 @@ const ASN1_ITEM ASN1_PRINTABLESTRING_it = { .utype = V_ASN1_PRINTABLESTRING, .sname = "ASN1_PRINTABLESTRING", }; +LCRYPTO_ALIAS(ASN1_PRINTABLESTRING_it); ASN1_PRINTABLESTRING * d2i_ASN1_PRINTABLESTRING(ASN1_PRINTABLESTRING **a, const unsigned char **in, @@ -175,6 +178,7 @@ const ASN1_ITEM ASN1_T61STRING_it = { .utype = V_ASN1_T61STRING, .sname = "ASN1_T61STRING", }; +LCRYPTO_ALIAS(ASN1_T61STRING_it); ASN1_T61STRING * d2i_ASN1_T61STRING(ASN1_T61STRING **a, const unsigned char **in, long len) @@ -211,6 +215,7 @@ const ASN1_ITEM ASN1_IA5STRING_it = { .utype = V_ASN1_IA5STRING, .sname = "ASN1_IA5STRING", }; +LCRYPTO_ALIAS(ASN1_IA5STRING_it); ASN1_IA5STRING * d2i_ASN1_IA5STRING(ASN1_IA5STRING **a, const unsigned char **in, long len) @@ -247,6 +252,7 @@ const ASN1_ITEM ASN1_GENERALSTRING_it = { .utype = V_ASN1_GENERALSTRING, .sname = "ASN1_GENERALSTRING", }; +LCRYPTO_ALIAS(ASN1_GENERALSTRING_it); ASN1_GENERALSTRING * d2i_ASN1_GENERALSTRING(ASN1_GENERALSTRING **a, const unsigned char **in, @@ -284,6 +290,7 @@ const ASN1_ITEM ASN1_UTCTIME_it = { .utype = V_ASN1_UTCTIME, .sname = "ASN1_UTCTIME", }; +LCRYPTO_ALIAS(ASN1_UTCTIME_it); ASN1_UTCTIME * d2i_ASN1_UTCTIME(ASN1_UTCTIME **a, const unsigned char **in, long len) @@ -320,6 +327,7 @@ const ASN1_ITEM ASN1_GENERALIZEDTIME_it = { .utype = V_ASN1_GENERALIZEDTIME, .sname = "ASN1_GENERALIZEDTIME", }; +LCRYPTO_ALIAS(ASN1_GENERALIZEDTIME_it); ASN1_GENERALIZEDTIME * d2i_ASN1_GENERALIZEDTIME(ASN1_GENERALIZEDTIME **a, const unsigned char **in, @@ -357,6 +365,7 @@ const ASN1_ITEM ASN1_VISIBLESTRING_it = { .utype = V_ASN1_VISIBLESTRING, .sname = "ASN1_VISIBLESTRING", }; +LCRYPTO_ALIAS(ASN1_VISIBLESTRING_it); ASN1_VISIBLESTRING * d2i_ASN1_VISIBLESTRING(ASN1_VISIBLESTRING **a, const unsigned char **in, @@ -394,6 +403,7 @@ const ASN1_ITEM ASN1_UNIVERSALSTRING_it = { .utype = V_ASN1_UNIVERSALSTRING, .sname = "ASN1_UNIVERSALSTRING", }; +LCRYPTO_ALIAS(ASN1_UNIVERSALSTRING_it); ASN1_UNIVERSALSTRING * d2i_ASN1_UNIVERSALSTRING(ASN1_UNIVERSALSTRING **a, const unsigned char **in, @@ -431,6 +441,7 @@ const ASN1_ITEM ASN1_BMPSTRING_it = { .utype = V_ASN1_BMPSTRING, .sname = "ASN1_BMPSTRING", }; +LCRYPTO_ALIAS(ASN1_BMPSTRING_it); ASN1_BMPSTRING * d2i_ASN1_BMPSTRING(ASN1_BMPSTRING **a, const unsigned char **in, long len) @@ -466,6 +477,7 @@ const ASN1_ITEM ASN1_ANY_it = { .utype = V_ASN1_ANY, .sname = "ASN1_ANY", }; +LCRYPTO_ALIAS(ASN1_ANY_it); /* Just swallow an ASN1_SEQUENCE in an ASN1_STRING */ @@ -489,6 +501,7 @@ const ASN1_ITEM ASN1_PRINTABLE_it = { .size = sizeof(ASN1_STRING), .sname = "ASN1_PRINTABLE", }; +LCRYPTO_ALIAS(ASN1_PRINTABLE_it); ASN1_STRING * d2i_ASN1_PRINTABLE(ASN1_STRING **a, const unsigned char **in, long len) @@ -529,6 +542,7 @@ const ASN1_ITEM DISPLAYTEXT_it = { .size = sizeof(ASN1_STRING), .sname = "DISPLAYTEXT", }; +LCRYPTO_ALIAS(DISPLAYTEXT_it); ASN1_STRING * d2i_DISPLAYTEXT(ASN1_STRING **a, const unsigned char **in, long len) @@ -569,6 +583,7 @@ const ASN1_ITEM DIRECTORYSTRING_it = { .size = sizeof(ASN1_STRING), .sname = "DIRECTORYSTRING", }; +LCRYPTO_ALIAS(DIRECTORYSTRING_it); ASN1_STRING * d2i_DIRECTORYSTRING(ASN1_STRING **a, const unsigned char **in, long len) @@ -670,6 +685,7 @@ const ASN1_ITEM ASN1_SEQUENCE_ANY_it = { .size = 0, .sname = "ASN1_SEQUENCE_ANY", }; +LCRYPTO_ALIAS(ASN1_SEQUENCE_ANY_it); static const ASN1_TEMPLATE ASN1_SET_ANY_item_tt = { .flags = ASN1_TFLG_SET_OF, @@ -688,6 +704,7 @@ const ASN1_ITEM ASN1_SET_ANY_it = { .size = 0, .sname = "ASN1_SET_ANY", }; +LCRYPTO_ALIAS(ASN1_SET_ANY_it); ASN1_SEQUENCE_ANY * diff --git a/lib/libcrypto/hidden/openssl/asn1.h b/lib/libcrypto/hidden/openssl/asn1.h index 91595d1da05..d45d6770d9b 100644 --- a/lib/libcrypto/hidden/openssl/asn1.h +++ b/lib/libcrypto/hidden/openssl/asn1.h @@ -1,4 +1,4 @@ -/* $OpenBSD: asn1.h,v 1.13 2024/04/10 14:55:12 beck Exp $ */ +/* $OpenBSD: asn1.h,v 1.14 2024/07/08 14:52:31 beck Exp $ */ /* * Copyright (c) 2023 Bob Beck * @@ -233,5 +233,28 @@ LCRYPTO_USED(SMIME_text); LCRYPTO_USED(ERR_load_ASN1_strings); LCRYPTO_UNUSED(ASN1_UTCTIME_cmp_time_t); LCRYPTO_UNUSED(ASN1_dup); +extern LCRYPTO_USED(ASN1_SEQUENCE_ANY_it); +extern LCRYPTO_USED(ASN1_SET_ANY_it); +extern LCRYPTO_USED(ASN1_ANY_it); +extern LCRYPTO_USED(ASN1_OBJECT_it); +extern LCRYPTO_USED(ASN1_BIT_STRING_it); +extern LCRYPTO_USED(ASN1_INTEGER_it); +extern LCRYPTO_USED(ASN1_ENUMERATED_it); +extern LCRYPTO_USED(ASN1_OCTET_STRING_it); +extern LCRYPTO_USED(ASN1_VISIBLESTRING_it); +extern LCRYPTO_USED(ASN1_UNIVERSALSTRING_it); +extern LCRYPTO_USED(ASN1_UTF8STRING_it); +extern LCRYPTO_USED(ASN1_NULL_it); +extern LCRYPTO_USED(ASN1_BMPSTRING_it); +extern LCRYPTO_USED(ASN1_PRINTABLE_it); +extern LCRYPTO_USED(DIRECTORYSTRING_it); +extern LCRYPTO_USED(DISPLAYTEXT_it); +extern LCRYPTO_USED(ASN1_PRINTABLESTRING_it); +extern LCRYPTO_USED(ASN1_T61STRING_it); +extern LCRYPTO_USED(ASN1_IA5STRING_it); +extern LCRYPTO_USED(ASN1_GENERALSTRING_it); +extern LCRYPTO_USED(ASN1_UTCTIME_it); +extern LCRYPTO_USED(ASN1_GENERALIZEDTIME_it); +extern LCRYPTO_USED(ASN1_TIME_it); #endif /* _LIBCRYPTO_ASN1_H */