summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/evp/e_aes.c
diff options
context:
space:
mode:
authorbeck <>2023-07-07 13:54:46 +0000
committerbeck <>2023-07-07 13:54:46 +0000
commit6bba0b0cef45b790c7a98a818e6018c91de8af0b (patch)
tree8637b2fb4bca234d55b598e035f23335be46ce49 /src/lib/libcrypto/evp/e_aes.c
parentfcdb286fc308a6ce5c66d8a4653f2e2e6c4903ed (diff)
downloadopenbsd-6bba0b0cef45b790c7a98a818e6018c91de8af0b.tar.gz
openbsd-6bba0b0cef45b790c7a98a818e6018c91de8af0b.tar.bz2
openbsd-6bba0b0cef45b790c7a98a818e6018c91de8af0b.zip
Hide symbols in hkdf, evp, err, ecdsa, and ec
(part 2 of commit) ok jsing@
Diffstat (limited to 'src/lib/libcrypto/evp/e_aes.c')
-rw-r--r--src/lib/libcrypto/evp/e_aes.c33
1 files changed, 32 insertions, 1 deletions
diff --git a/src/lib/libcrypto/evp/e_aes.c b/src/lib/libcrypto/evp/e_aes.c
index 790b26384d..35c8d944ed 100644
--- a/src/lib/libcrypto/evp/e_aes.c
+++ b/src/lib/libcrypto/evp/e_aes.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: e_aes.c,v 1.51 2023/03/01 11:16:06 tb Exp $ */ 1/* $OpenBSD: e_aes.c,v 1.52 2023/07/07 13:54:45 beck Exp $ */
2/* ==================================================================== 2/* ====================================================================
3 * Copyright (c) 2001-2011 The OpenSSL Project. All rights reserved. 3 * Copyright (c) 2001-2011 The OpenSSL Project. All rights reserved.
4 * 4 *
@@ -572,6 +572,7 @@ EVP_aes_128_cbc(void)
572 return &aes_128_cbc; 572 return &aes_128_cbc;
573#endif 573#endif
574} 574}
575LCRYPTO_ALIAS(EVP_aes_128_cbc);
575 576
576#ifdef AESNI_CAPABLE 577#ifdef AESNI_CAPABLE
577static const EVP_CIPHER aesni_128_ecb = { 578static const EVP_CIPHER aesni_128_ecb = {
@@ -606,6 +607,7 @@ EVP_aes_128_ecb(void)
606 return &aes_128_ecb; 607 return &aes_128_ecb;
607#endif 608#endif
608} 609}
610LCRYPTO_ALIAS(EVP_aes_128_ecb);
609 611
610#ifdef AESNI_CAPABLE 612#ifdef AESNI_CAPABLE
611static const EVP_CIPHER aesni_128_ofb = { 613static const EVP_CIPHER aesni_128_ofb = {
@@ -640,6 +642,7 @@ EVP_aes_128_ofb(void)
640 return &aes_128_ofb; 642 return &aes_128_ofb;
641#endif 643#endif
642} 644}
645LCRYPTO_ALIAS(EVP_aes_128_ofb);
643 646
644#ifdef AESNI_CAPABLE 647#ifdef AESNI_CAPABLE
645static const EVP_CIPHER aesni_128_cfb = { 648static const EVP_CIPHER aesni_128_cfb = {
@@ -708,6 +711,7 @@ EVP_aes_128_cfb1(void)
708 return &aes_128_cfb1; 711 return &aes_128_cfb1;
709#endif 712#endif
710} 713}
714LCRYPTO_ALIAS(EVP_aes_128_cfb1);
711 715
712#ifdef AESNI_CAPABLE 716#ifdef AESNI_CAPABLE
713static const EVP_CIPHER aesni_128_cfb8 = { 717static const EVP_CIPHER aesni_128_cfb8 = {
@@ -742,6 +746,7 @@ EVP_aes_128_cfb8(void)
742 return &aes_128_cfb8; 746 return &aes_128_cfb8;
743#endif 747#endif
744} 748}
749LCRYPTO_ALIAS(EVP_aes_128_cfb8);
745 750
746#ifdef AESNI_CAPABLE 751#ifdef AESNI_CAPABLE
747static const EVP_CIPHER aesni_128_ctr = { 752static const EVP_CIPHER aesni_128_ctr = {
@@ -776,6 +781,7 @@ EVP_aes_128_ctr(void)
776 return &aes_128_ctr; 781 return &aes_128_ctr;
777#endif 782#endif
778} 783}
784LCRYPTO_ALIAS(EVP_aes_128_ctr);
779 785
780 786
781#ifdef AESNI_CAPABLE 787#ifdef AESNI_CAPABLE
@@ -811,6 +817,7 @@ EVP_aes_192_cbc(void)
811 return &aes_192_cbc; 817 return &aes_192_cbc;
812#endif 818#endif
813} 819}
820LCRYPTO_ALIAS(EVP_aes_192_cbc);
814 821
815#ifdef AESNI_CAPABLE 822#ifdef AESNI_CAPABLE
816static const EVP_CIPHER aesni_192_ecb = { 823static const EVP_CIPHER aesni_192_ecb = {
@@ -845,6 +852,7 @@ EVP_aes_192_ecb(void)
845 return &aes_192_ecb; 852 return &aes_192_ecb;
846#endif 853#endif
847} 854}
855LCRYPTO_ALIAS(EVP_aes_192_ecb);
848 856
849#ifdef AESNI_CAPABLE 857#ifdef AESNI_CAPABLE
850static const EVP_CIPHER aesni_192_ofb = { 858static const EVP_CIPHER aesni_192_ofb = {
@@ -879,6 +887,7 @@ EVP_aes_192_ofb(void)
879 return &aes_192_ofb; 887 return &aes_192_ofb;
880#endif 888#endif
881} 889}
890LCRYPTO_ALIAS(EVP_aes_192_ofb);
882 891
883#ifdef AESNI_CAPABLE 892#ifdef AESNI_CAPABLE
884static const EVP_CIPHER aesni_192_cfb = { 893static const EVP_CIPHER aesni_192_cfb = {
@@ -947,6 +956,7 @@ EVP_aes_192_cfb1(void)
947 return &aes_192_cfb1; 956 return &aes_192_cfb1;
948#endif 957#endif
949} 958}
959LCRYPTO_ALIAS(EVP_aes_192_cfb1);
950 960
951#ifdef AESNI_CAPABLE 961#ifdef AESNI_CAPABLE
952static const EVP_CIPHER aesni_192_cfb8 = { 962static const EVP_CIPHER aesni_192_cfb8 = {
@@ -981,6 +991,7 @@ EVP_aes_192_cfb8(void)
981 return &aes_192_cfb8; 991 return &aes_192_cfb8;
982#endif 992#endif
983} 993}
994LCRYPTO_ALIAS(EVP_aes_192_cfb8);
984 995
985#ifdef AESNI_CAPABLE 996#ifdef AESNI_CAPABLE
986static const EVP_CIPHER aesni_192_ctr = { 997static const EVP_CIPHER aesni_192_ctr = {
@@ -1015,6 +1026,7 @@ EVP_aes_192_ctr(void)
1015 return &aes_192_ctr; 1026 return &aes_192_ctr;
1016#endif 1027#endif
1017} 1028}
1029LCRYPTO_ALIAS(EVP_aes_192_ctr);
1018 1030
1019 1031
1020#ifdef AESNI_CAPABLE 1032#ifdef AESNI_CAPABLE
@@ -1050,6 +1062,7 @@ EVP_aes_256_cbc(void)
1050 return &aes_256_cbc; 1062 return &aes_256_cbc;
1051#endif 1063#endif
1052} 1064}
1065LCRYPTO_ALIAS(EVP_aes_256_cbc);
1053 1066
1054#ifdef AESNI_CAPABLE 1067#ifdef AESNI_CAPABLE
1055static const EVP_CIPHER aesni_256_ecb = { 1068static const EVP_CIPHER aesni_256_ecb = {
@@ -1084,6 +1097,7 @@ EVP_aes_256_ecb(void)
1084 return &aes_256_ecb; 1097 return &aes_256_ecb;
1085#endif 1098#endif
1086} 1099}
1100LCRYPTO_ALIAS(EVP_aes_256_ecb);
1087 1101
1088#ifdef AESNI_CAPABLE 1102#ifdef AESNI_CAPABLE
1089static const EVP_CIPHER aesni_256_ofb = { 1103static const EVP_CIPHER aesni_256_ofb = {
@@ -1118,6 +1132,7 @@ EVP_aes_256_ofb(void)
1118 return &aes_256_ofb; 1132 return &aes_256_ofb;
1119#endif 1133#endif
1120} 1134}
1135LCRYPTO_ALIAS(EVP_aes_256_ofb);
1121 1136
1122#ifdef AESNI_CAPABLE 1137#ifdef AESNI_CAPABLE
1123static const EVP_CIPHER aesni_256_cfb = { 1138static const EVP_CIPHER aesni_256_cfb = {
@@ -1186,6 +1201,7 @@ EVP_aes_256_cfb1(void)
1186 return &aes_256_cfb1; 1201 return &aes_256_cfb1;
1187#endif 1202#endif
1188} 1203}
1204LCRYPTO_ALIAS(EVP_aes_256_cfb1);
1189 1205
1190#ifdef AESNI_CAPABLE 1206#ifdef AESNI_CAPABLE
1191static const EVP_CIPHER aesni_256_cfb8 = { 1207static const EVP_CIPHER aesni_256_cfb8 = {
@@ -1220,6 +1236,7 @@ EVP_aes_256_cfb8(void)
1220 return &aes_256_cfb8; 1236 return &aes_256_cfb8;
1221#endif 1237#endif
1222} 1238}
1239LCRYPTO_ALIAS(EVP_aes_256_cfb8);
1223 1240
1224#ifdef AESNI_CAPABLE 1241#ifdef AESNI_CAPABLE
1225static const EVP_CIPHER aesni_256_ctr = { 1242static const EVP_CIPHER aesni_256_ctr = {
@@ -1254,6 +1271,7 @@ EVP_aes_256_ctr(void)
1254 return &aes_256_ctr; 1271 return &aes_256_ctr;
1255#endif 1272#endif
1256} 1273}
1274LCRYPTO_ALIAS(EVP_aes_256_ctr);
1257 1275
1258static int 1276static int
1259aes_gcm_cleanup(EVP_CIPHER_CTX *c) 1277aes_gcm_cleanup(EVP_CIPHER_CTX *c)
@@ -1672,6 +1690,7 @@ EVP_aes_128_gcm(void)
1672 return &aes_128_gcm; 1690 return &aes_128_gcm;
1673#endif 1691#endif
1674} 1692}
1693LCRYPTO_ALIAS(EVP_aes_128_gcm);
1675 1694
1676#ifdef AESNI_CAPABLE 1695#ifdef AESNI_CAPABLE
1677static const EVP_CIPHER aesni_192_gcm = { 1696static const EVP_CIPHER aesni_192_gcm = {
@@ -1710,6 +1729,7 @@ EVP_aes_192_gcm(void)
1710 return &aes_192_gcm; 1729 return &aes_192_gcm;
1711#endif 1730#endif
1712} 1731}
1732LCRYPTO_ALIAS(EVP_aes_192_gcm);
1713 1733
1714#ifdef AESNI_CAPABLE 1734#ifdef AESNI_CAPABLE
1715static const EVP_CIPHER aesni_256_gcm = { 1735static const EVP_CIPHER aesni_256_gcm = {
@@ -1748,6 +1768,7 @@ EVP_aes_256_gcm(void)
1748 return &aes_256_gcm; 1768 return &aes_256_gcm;
1749#endif 1769#endif
1750} 1770}
1771LCRYPTO_ALIAS(EVP_aes_256_gcm);
1751 1772
1752static int 1773static int
1753aes_xts_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr) 1774aes_xts_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
@@ -1914,6 +1935,7 @@ EVP_aes_128_xts(void)
1914 return &aes_128_xts; 1935 return &aes_128_xts;
1915#endif 1936#endif
1916} 1937}
1938LCRYPTO_ALIAS(EVP_aes_128_xts);
1917 1939
1918#ifdef AESNI_CAPABLE 1940#ifdef AESNI_CAPABLE
1919static const EVP_CIPHER aesni_256_xts = { 1941static const EVP_CIPHER aesni_256_xts = {
@@ -1952,6 +1974,7 @@ EVP_aes_256_xts(void)
1952 return &aes_256_xts; 1974 return &aes_256_xts;
1953#endif 1975#endif
1954} 1976}
1977LCRYPTO_ALIAS(EVP_aes_256_xts);
1955 1978
1956static int 1979static int
1957aes_ccm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr) 1980aes_ccm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
@@ -2148,6 +2171,7 @@ EVP_aes_128_ccm(void)
2148 return &aes_128_ccm; 2171 return &aes_128_ccm;
2149#endif 2172#endif
2150} 2173}
2174LCRYPTO_ALIAS(EVP_aes_128_ccm);
2151 2175
2152#ifdef AESNI_CAPABLE 2176#ifdef AESNI_CAPABLE
2153static const EVP_CIPHER aesni_192_ccm = { 2177static const EVP_CIPHER aesni_192_ccm = {
@@ -2186,6 +2210,7 @@ EVP_aes_192_ccm(void)
2186 return &aes_192_ccm; 2210 return &aes_192_ccm;
2187#endif 2211#endif
2188} 2212}
2213LCRYPTO_ALIAS(EVP_aes_192_ccm);
2189 2214
2190#ifdef AESNI_CAPABLE 2215#ifdef AESNI_CAPABLE
2191static const EVP_CIPHER aesni_256_ccm = { 2216static const EVP_CIPHER aesni_256_ccm = {
@@ -2224,6 +2249,7 @@ EVP_aes_256_ccm(void)
2224 return &aes_256_ccm; 2249 return &aes_256_ccm;
2225#endif 2250#endif
2226} 2251}
2252LCRYPTO_ALIAS(EVP_aes_256_ccm);
2227 2253
2228#define EVP_AEAD_AES_GCM_TAG_LEN 16 2254#define EVP_AEAD_AES_GCM_TAG_LEN 16
2229 2255
@@ -2414,12 +2440,14 @@ EVP_aead_aes_128_gcm(void)
2414{ 2440{
2415 return &aead_aes_128_gcm; 2441 return &aead_aes_128_gcm;
2416} 2442}
2443LCRYPTO_ALIAS(EVP_aead_aes_128_gcm);
2417 2444
2418const EVP_AEAD * 2445const EVP_AEAD *
2419EVP_aead_aes_256_gcm(void) 2446EVP_aead_aes_256_gcm(void)
2420{ 2447{
2421 return &aead_aes_256_gcm; 2448 return &aead_aes_256_gcm;
2422} 2449}
2450LCRYPTO_ALIAS(EVP_aead_aes_256_gcm);
2423 2451
2424typedef struct { 2452typedef struct {
2425 union { 2453 union {
@@ -2545,6 +2573,7 @@ EVP_aes_128_wrap(void)
2545{ 2573{
2546 return &aes_128_wrap; 2574 return &aes_128_wrap;
2547} 2575}
2576LCRYPTO_ALIAS(EVP_aes_128_wrap);
2548 2577
2549static const EVP_CIPHER aes_192_wrap = { 2578static const EVP_CIPHER aes_192_wrap = {
2550 .nid = NID_id_aes192_wrap, 2579 .nid = NID_id_aes192_wrap,
@@ -2567,6 +2596,7 @@ EVP_aes_192_wrap(void)
2567{ 2596{
2568 return &aes_192_wrap; 2597 return &aes_192_wrap;
2569} 2598}
2599LCRYPTO_ALIAS(EVP_aes_192_wrap);
2570 2600
2571static const EVP_CIPHER aes_256_wrap = { 2601static const EVP_CIPHER aes_256_wrap = {
2572 .nid = NID_id_aes256_wrap, 2602 .nid = NID_id_aes256_wrap,
@@ -2589,5 +2619,6 @@ EVP_aes_256_wrap(void)
2589{ 2619{
2590 return &aes_256_wrap; 2620 return &aes_256_wrap;
2591} 2621}
2622LCRYPTO_ALIAS(EVP_aes_256_wrap);
2592 2623
2593#endif 2624#endif