diff options
Diffstat (limited to 'src/lib/libssl/ssl_sess.c')
-rw-r--r-- | src/lib/libssl/ssl_sess.c | 54 |
1 files changed, 53 insertions, 1 deletions
diff --git a/src/lib/libssl/ssl_sess.c b/src/lib/libssl/ssl_sess.c index 5847a43dcd..aa6b08eae6 100644 --- a/src/lib/libssl/ssl_sess.c +++ b/src/lib/libssl/ssl_sess.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssl_sess.c,v 1.121 2022/11/26 16:08:56 tb Exp $ */ | 1 | /* $OpenBSD: ssl_sess.c,v 1.122 2023/07/08 16:40:13 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -154,6 +154,7 @@ SSL_get_session(const SSL *ssl) | |||
154 | { | 154 | { |
155 | return (ssl->session); | 155 | return (ssl->session); |
156 | } | 156 | } |
157 | LSSL_ALIAS(SSL_get_session); | ||
157 | 158 | ||
158 | /* variant of SSL_get_session: caller really gets something */ | 159 | /* variant of SSL_get_session: caller really gets something */ |
159 | SSL_SESSION * | 160 | SSL_SESSION * |
@@ -174,6 +175,7 @@ SSL_get1_session(SSL *ssl) | |||
174 | 175 | ||
175 | return (sess); | 176 | return (sess); |
176 | } | 177 | } |
178 | LSSL_ALIAS(SSL_get1_session); | ||
177 | 179 | ||
178 | int | 180 | int |
179 | SSL_SESSION_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, | 181 | SSL_SESSION_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, |
@@ -182,30 +184,35 @@ SSL_SESSION_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, | |||
182 | return CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_SSL_SESSION, | 184 | return CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_SSL_SESSION, |
183 | argl, argp, new_func, dup_func, free_func); | 185 | argl, argp, new_func, dup_func, free_func); |
184 | } | 186 | } |
187 | LSSL_ALIAS(SSL_SESSION_get_ex_new_index); | ||
185 | 188 | ||
186 | int | 189 | int |
187 | SSL_SESSION_set_ex_data(SSL_SESSION *s, int idx, void *arg) | 190 | SSL_SESSION_set_ex_data(SSL_SESSION *s, int idx, void *arg) |
188 | { | 191 | { |
189 | return (CRYPTO_set_ex_data(&s->ex_data, idx, arg)); | 192 | return (CRYPTO_set_ex_data(&s->ex_data, idx, arg)); |
190 | } | 193 | } |
194 | LSSL_ALIAS(SSL_SESSION_set_ex_data); | ||
191 | 195 | ||
192 | void * | 196 | void * |
193 | SSL_SESSION_get_ex_data(const SSL_SESSION *s, int idx) | 197 | SSL_SESSION_get_ex_data(const SSL_SESSION *s, int idx) |
194 | { | 198 | { |
195 | return (CRYPTO_get_ex_data(&s->ex_data, idx)); | 199 | return (CRYPTO_get_ex_data(&s->ex_data, idx)); |
196 | } | 200 | } |
201 | LSSL_ALIAS(SSL_SESSION_get_ex_data); | ||
197 | 202 | ||
198 | uint32_t | 203 | uint32_t |
199 | SSL_SESSION_get_max_early_data(const SSL_SESSION *s) | 204 | SSL_SESSION_get_max_early_data(const SSL_SESSION *s) |
200 | { | 205 | { |
201 | return 0; | 206 | return 0; |
202 | } | 207 | } |
208 | LSSL_ALIAS(SSL_SESSION_get_max_early_data); | ||
203 | 209 | ||
204 | int | 210 | int |
205 | SSL_SESSION_set_max_early_data(SSL_SESSION *s, uint32_t max_early_data) | 211 | SSL_SESSION_set_max_early_data(SSL_SESSION *s, uint32_t max_early_data) |
206 | { | 212 | { |
207 | return 1; | 213 | return 1; |
208 | } | 214 | } |
215 | LSSL_ALIAS(SSL_SESSION_set_max_early_data); | ||
209 | 216 | ||
210 | SSL_SESSION * | 217 | SSL_SESSION * |
211 | SSL_SESSION_new(void) | 218 | SSL_SESSION_new(void) |
@@ -241,6 +248,7 @@ SSL_SESSION_new(void) | |||
241 | 248 | ||
242 | return (ss); | 249 | return (ss); |
243 | } | 250 | } |
251 | LSSL_ALIAS(SSL_SESSION_new); | ||
244 | 252 | ||
245 | SSL_SESSION * | 253 | SSL_SESSION * |
246 | ssl_session_dup(SSL_SESSION *sess, int include_ticket) | 254 | ssl_session_dup(SSL_SESSION *sess, int include_ticket) |
@@ -354,6 +362,7 @@ SSL_SESSION_get_id(const SSL_SESSION *ss, unsigned int *len) | |||
354 | *len = (unsigned int)ss->session_id_length; | 362 | *len = (unsigned int)ss->session_id_length; |
355 | return ss->session_id; | 363 | return ss->session_id; |
356 | } | 364 | } |
365 | LSSL_ALIAS(SSL_SESSION_get_id); | ||
357 | 366 | ||
358 | const unsigned char * | 367 | const unsigned char * |
359 | SSL_SESSION_get0_id_context(const SSL_SESSION *ss, unsigned int *len) | 368 | SSL_SESSION_get0_id_context(const SSL_SESSION *ss, unsigned int *len) |
@@ -362,24 +371,28 @@ SSL_SESSION_get0_id_context(const SSL_SESSION *ss, unsigned int *len) | |||
362 | *len = (unsigned int)ss->sid_ctx_length; | 371 | *len = (unsigned int)ss->sid_ctx_length; |
363 | return ss->sid_ctx; | 372 | return ss->sid_ctx; |
364 | } | 373 | } |
374 | LSSL_ALIAS(SSL_SESSION_get0_id_context); | ||
365 | 375 | ||
366 | unsigned int | 376 | unsigned int |
367 | SSL_SESSION_get_compress_id(const SSL_SESSION *ss) | 377 | SSL_SESSION_get_compress_id(const SSL_SESSION *ss) |
368 | { | 378 | { |
369 | return 0; | 379 | return 0; |
370 | } | 380 | } |
381 | LSSL_ALIAS(SSL_SESSION_get_compress_id); | ||
371 | 382 | ||
372 | unsigned long | 383 | unsigned long |
373 | SSL_SESSION_get_ticket_lifetime_hint(const SSL_SESSION *s) | 384 | SSL_SESSION_get_ticket_lifetime_hint(const SSL_SESSION *s) |
374 | { | 385 | { |
375 | return s->tlsext_tick_lifetime_hint; | 386 | return s->tlsext_tick_lifetime_hint; |
376 | } | 387 | } |
388 | LSSL_ALIAS(SSL_SESSION_get_ticket_lifetime_hint); | ||
377 | 389 | ||
378 | int | 390 | int |
379 | SSL_SESSION_has_ticket(const SSL_SESSION *s) | 391 | SSL_SESSION_has_ticket(const SSL_SESSION *s) |
380 | { | 392 | { |
381 | return (s->tlsext_ticklen > 0) ? 1 : 0; | 393 | return (s->tlsext_ticklen > 0) ? 1 : 0; |
382 | } | 394 | } |
395 | LSSL_ALIAS(SSL_SESSION_has_ticket); | ||
383 | 396 | ||
384 | /* | 397 | /* |
385 | * SSLv3/TLSv1 has 32 bytes (256 bits) of session ID space. As such, filling | 398 | * SSLv3/TLSv1 has 32 bytes (256 bits) of session ID space. As such, filling |
@@ -815,12 +828,14 @@ SSL_CTX_add_session(SSL_CTX *ctx, SSL_SESSION *c) | |||
815 | CRYPTO_w_unlock(CRYPTO_LOCK_SSL_CTX); | 828 | CRYPTO_w_unlock(CRYPTO_LOCK_SSL_CTX); |
816 | return (ret); | 829 | return (ret); |
817 | } | 830 | } |
831 | LSSL_ALIAS(SSL_CTX_add_session); | ||
818 | 832 | ||
819 | int | 833 | int |
820 | SSL_CTX_remove_session(SSL_CTX *ctx, SSL_SESSION *c) | 834 | SSL_CTX_remove_session(SSL_CTX *ctx, SSL_SESSION *c) |
821 | { | 835 | { |
822 | return remove_session_lock(ctx, c, 1); | 836 | return remove_session_lock(ctx, c, 1); |
823 | } | 837 | } |
838 | LSSL_ALIAS(SSL_CTX_remove_session); | ||
824 | 839 | ||
825 | static int | 840 | static int |
826 | remove_session_lock(SSL_CTX *ctx, SSL_SESSION *c, int lck) | 841 | remove_session_lock(SSL_CTX *ctx, SSL_SESSION *c, int lck) |
@@ -881,6 +896,7 @@ SSL_SESSION_free(SSL_SESSION *ss) | |||
881 | 896 | ||
882 | freezero(ss, sizeof(*ss)); | 897 | freezero(ss, sizeof(*ss)); |
883 | } | 898 | } |
899 | LSSL_ALIAS(SSL_SESSION_free); | ||
884 | 900 | ||
885 | int | 901 | int |
886 | SSL_SESSION_up_ref(SSL_SESSION *ss) | 902 | SSL_SESSION_up_ref(SSL_SESSION *ss) |
@@ -888,6 +904,7 @@ SSL_SESSION_up_ref(SSL_SESSION *ss) | |||
888 | int refs = CRYPTO_add(&ss->references, 1, CRYPTO_LOCK_SSL_SESSION); | 904 | int refs = CRYPTO_add(&ss->references, 1, CRYPTO_LOCK_SSL_SESSION); |
889 | return (refs > 1) ? 1 : 0; | 905 | return (refs > 1) ? 1 : 0; |
890 | } | 906 | } |
907 | LSSL_ALIAS(SSL_SESSION_up_ref); | ||
891 | 908 | ||
892 | int | 909 | int |
893 | SSL_set_session(SSL *s, SSL_SESSION *session) | 910 | SSL_set_session(SSL *s, SSL_SESSION *session) |
@@ -916,6 +933,7 @@ SSL_set_session(SSL *s, SSL_SESSION *session) | |||
916 | 933 | ||
917 | return (1); | 934 | return (1); |
918 | } | 935 | } |
936 | LSSL_ALIAS(SSL_set_session); | ||
919 | 937 | ||
920 | size_t | 938 | size_t |
921 | SSL_SESSION_get_master_key(const SSL_SESSION *ss, unsigned char *out, | 939 | SSL_SESSION_get_master_key(const SSL_SESSION *ss, unsigned char *out, |
@@ -933,6 +951,7 @@ SSL_SESSION_get_master_key(const SSL_SESSION *ss, unsigned char *out, | |||
933 | 951 | ||
934 | return len; | 952 | return len; |
935 | } | 953 | } |
954 | LSSL_ALIAS(SSL_SESSION_get_master_key); | ||
936 | 955 | ||
937 | long | 956 | long |
938 | SSL_SESSION_set_timeout(SSL_SESSION *s, long t) | 957 | SSL_SESSION_set_timeout(SSL_SESSION *s, long t) |
@@ -942,6 +961,7 @@ SSL_SESSION_set_timeout(SSL_SESSION *s, long t) | |||
942 | s->timeout = t; | 961 | s->timeout = t; |
943 | return (1); | 962 | return (1); |
944 | } | 963 | } |
964 | LSSL_ALIAS(SSL_SESSION_set_timeout); | ||
945 | 965 | ||
946 | long | 966 | long |
947 | SSL_SESSION_get_timeout(const SSL_SESSION *s) | 967 | SSL_SESSION_get_timeout(const SSL_SESSION *s) |
@@ -950,6 +970,7 @@ SSL_SESSION_get_timeout(const SSL_SESSION *s) | |||
950 | return (0); | 970 | return (0); |
951 | return (s->timeout); | 971 | return (s->timeout); |
952 | } | 972 | } |
973 | LSSL_ALIAS(SSL_SESSION_get_timeout); | ||
953 | 974 | ||
954 | /* XXX 2038 */ | 975 | /* XXX 2038 */ |
955 | long | 976 | long |
@@ -959,6 +980,7 @@ SSL_SESSION_get_time(const SSL_SESSION *s) | |||
959 | return (0); | 980 | return (0); |
960 | return (s->time); | 981 | return (s->time); |
961 | } | 982 | } |
983 | LSSL_ALIAS(SSL_SESSION_get_time); | ||
962 | 984 | ||
963 | /* XXX 2038 */ | 985 | /* XXX 2038 */ |
964 | long | 986 | long |
@@ -969,24 +991,28 @@ SSL_SESSION_set_time(SSL_SESSION *s, long t) | |||
969 | s->time = t; | 991 | s->time = t; |
970 | return (t); | 992 | return (t); |
971 | } | 993 | } |
994 | LSSL_ALIAS(SSL_SESSION_set_time); | ||
972 | 995 | ||
973 | int | 996 | int |
974 | SSL_SESSION_get_protocol_version(const SSL_SESSION *s) | 997 | SSL_SESSION_get_protocol_version(const SSL_SESSION *s) |
975 | { | 998 | { |
976 | return s->ssl_version; | 999 | return s->ssl_version; |
977 | } | 1000 | } |
1001 | LSSL_ALIAS(SSL_SESSION_get_protocol_version); | ||
978 | 1002 | ||
979 | const SSL_CIPHER * | 1003 | const SSL_CIPHER * |
980 | SSL_SESSION_get0_cipher(const SSL_SESSION *s) | 1004 | SSL_SESSION_get0_cipher(const SSL_SESSION *s) |
981 | { | 1005 | { |
982 | return s->cipher; | 1006 | return s->cipher; |
983 | } | 1007 | } |
1008 | LSSL_ALIAS(SSL_SESSION_get0_cipher); | ||
984 | 1009 | ||
985 | X509 * | 1010 | X509 * |
986 | SSL_SESSION_get0_peer(SSL_SESSION *s) | 1011 | SSL_SESSION_get0_peer(SSL_SESSION *s) |
987 | { | 1012 | { |
988 | return s->peer_cert; | 1013 | return s->peer_cert; |
989 | } | 1014 | } |
1015 | LSSL_ALIAS(SSL_SESSION_get0_peer); | ||
990 | 1016 | ||
991 | int | 1017 | int |
992 | SSL_SESSION_set1_id(SSL_SESSION *s, const unsigned char *sid, | 1018 | SSL_SESSION_set1_id(SSL_SESSION *s, const unsigned char *sid, |
@@ -1000,6 +1026,7 @@ SSL_SESSION_set1_id(SSL_SESSION *s, const unsigned char *sid, | |||
1000 | memmove(s->session_id, sid, sid_len); | 1026 | memmove(s->session_id, sid, sid_len); |
1001 | return 1; | 1027 | return 1; |
1002 | } | 1028 | } |
1029 | LSSL_ALIAS(SSL_SESSION_set1_id); | ||
1003 | 1030 | ||
1004 | int | 1031 | int |
1005 | SSL_SESSION_set1_id_context(SSL_SESSION *s, const unsigned char *sid_ctx, | 1032 | SSL_SESSION_set1_id_context(SSL_SESSION *s, const unsigned char *sid_ctx, |
@@ -1014,12 +1041,14 @@ SSL_SESSION_set1_id_context(SSL_SESSION *s, const unsigned char *sid_ctx, | |||
1014 | 1041 | ||
1015 | return 1; | 1042 | return 1; |
1016 | } | 1043 | } |
1044 | LSSL_ALIAS(SSL_SESSION_set1_id_context); | ||
1017 | 1045 | ||
1018 | int | 1046 | int |
1019 | SSL_SESSION_is_resumable(const SSL_SESSION *s) | 1047 | SSL_SESSION_is_resumable(const SSL_SESSION *s) |
1020 | { | 1048 | { |
1021 | return 0; | 1049 | return 0; |
1022 | } | 1050 | } |
1051 | LSSL_ALIAS(SSL_SESSION_is_resumable); | ||
1023 | 1052 | ||
1024 | long | 1053 | long |
1025 | SSL_CTX_set_timeout(SSL_CTX *s, long t) | 1054 | SSL_CTX_set_timeout(SSL_CTX *s, long t) |
@@ -1033,6 +1062,7 @@ SSL_CTX_set_timeout(SSL_CTX *s, long t) | |||
1033 | 1062 | ||
1034 | return (l); | 1063 | return (l); |
1035 | } | 1064 | } |
1065 | LSSL_ALIAS(SSL_CTX_set_timeout); | ||
1036 | 1066 | ||
1037 | long | 1067 | long |
1038 | SSL_CTX_get_timeout(const SSL_CTX *s) | 1068 | SSL_CTX_get_timeout(const SSL_CTX *s) |
@@ -1041,6 +1071,7 @@ SSL_CTX_get_timeout(const SSL_CTX *s) | |||
1041 | return (0); | 1071 | return (0); |
1042 | return (s->session_timeout); | 1072 | return (s->session_timeout); |
1043 | } | 1073 | } |
1074 | LSSL_ALIAS(SSL_CTX_get_timeout); | ||
1044 | 1075 | ||
1045 | int | 1076 | int |
1046 | SSL_set_session_secret_cb(SSL *s, int (*tls_session_secret_cb)(SSL *s, | 1077 | SSL_set_session_secret_cb(SSL *s, int (*tls_session_secret_cb)(SSL *s, |
@@ -1053,6 +1084,7 @@ SSL_set_session_secret_cb(SSL *s, int (*tls_session_secret_cb)(SSL *s, | |||
1053 | s->tls_session_secret_cb_arg = arg; | 1084 | s->tls_session_secret_cb_arg = arg; |
1054 | return (1); | 1085 | return (1); |
1055 | } | 1086 | } |
1087 | LSSL_ALIAS(SSL_set_session_secret_cb); | ||
1056 | 1088 | ||
1057 | int | 1089 | int |
1058 | SSL_set_session_ticket_ext_cb(SSL *s, tls_session_ticket_ext_cb_fn cb, | 1090 | SSL_set_session_ticket_ext_cb(SSL *s, tls_session_ticket_ext_cb_fn cb, |
@@ -1064,6 +1096,7 @@ SSL_set_session_ticket_ext_cb(SSL *s, tls_session_ticket_ext_cb_fn cb, | |||
1064 | s->tls_session_ticket_ext_cb_arg = arg; | 1096 | s->tls_session_ticket_ext_cb_arg = arg; |
1065 | return (1); | 1097 | return (1); |
1066 | } | 1098 | } |
1099 | LSSL_ALIAS(SSL_set_session_ticket_ext_cb); | ||
1067 | 1100 | ||
1068 | int | 1101 | int |
1069 | SSL_set_session_ticket_ext(SSL *s, void *ext_data, int ext_len) | 1102 | SSL_set_session_ticket_ext(SSL *s, void *ext_data, int ext_len) |
@@ -1093,6 +1126,7 @@ SSL_set_session_ticket_ext(SSL *s, void *ext_data, int ext_len) | |||
1093 | 1126 | ||
1094 | return 0; | 1127 | return 0; |
1095 | } | 1128 | } |
1129 | LSSL_ALIAS(SSL_set_session_ticket_ext); | ||
1096 | 1130 | ||
1097 | typedef struct timeout_param_st { | 1131 | typedef struct timeout_param_st { |
1098 | SSL_CTX *ctx; | 1132 | SSL_CTX *ctx; |
@@ -1145,6 +1179,7 @@ SSL_CTX_flush_sessions(SSL_CTX *s, long t) | |||
1145 | CHECKED_LHASH_OF(SSL_SESSION, tp.cache)->down_load = i; | 1179 | CHECKED_LHASH_OF(SSL_SESSION, tp.cache)->down_load = i; |
1146 | CRYPTO_w_unlock(CRYPTO_LOCK_SSL_CTX); | 1180 | CRYPTO_w_unlock(CRYPTO_LOCK_SSL_CTX); |
1147 | } | 1181 | } |
1182 | LSSL_ALIAS(SSL_CTX_flush_sessions); | ||
1148 | 1183 | ||
1149 | int | 1184 | int |
1150 | ssl_clear_bad_session(SSL *s) | 1185 | ssl_clear_bad_session(SSL *s) |
@@ -1214,12 +1249,14 @@ SSL_CTX_sess_set_new_cb(SSL_CTX *ctx, | |||
1214 | int (*cb)(struct ssl_st *ssl, SSL_SESSION *sess)) { | 1249 | int (*cb)(struct ssl_st *ssl, SSL_SESSION *sess)) { |
1215 | ctx->new_session_cb = cb; | 1250 | ctx->new_session_cb = cb; |
1216 | } | 1251 | } |
1252 | LSSL_ALIAS(SSL_CTX_sess_set_new_cb); | ||
1217 | 1253 | ||
1218 | int | 1254 | int |
1219 | (*SSL_CTX_sess_get_new_cb(SSL_CTX *ctx))(SSL *ssl, SSL_SESSION *sess) | 1255 | (*SSL_CTX_sess_get_new_cb(SSL_CTX *ctx))(SSL *ssl, SSL_SESSION *sess) |
1220 | { | 1256 | { |
1221 | return ctx->new_session_cb; | 1257 | return ctx->new_session_cb; |
1222 | } | 1258 | } |
1259 | LSSL_ALIAS(SSL_CTX_sess_get_new_cb); | ||
1223 | 1260 | ||
1224 | void | 1261 | void |
1225 | SSL_CTX_sess_set_remove_cb(SSL_CTX *ctx, | 1262 | SSL_CTX_sess_set_remove_cb(SSL_CTX *ctx, |
@@ -1227,12 +1264,14 @@ SSL_CTX_sess_set_remove_cb(SSL_CTX *ctx, | |||
1227 | { | 1264 | { |
1228 | ctx->remove_session_cb = cb; | 1265 | ctx->remove_session_cb = cb; |
1229 | } | 1266 | } |
1267 | LSSL_ALIAS(SSL_CTX_sess_set_remove_cb); | ||
1230 | 1268 | ||
1231 | void | 1269 | void |
1232 | (*SSL_CTX_sess_get_remove_cb(SSL_CTX *ctx))(SSL_CTX * ctx, SSL_SESSION *sess) | 1270 | (*SSL_CTX_sess_get_remove_cb(SSL_CTX *ctx))(SSL_CTX * ctx, SSL_SESSION *sess) |
1233 | { | 1271 | { |
1234 | return ctx->remove_session_cb; | 1272 | return ctx->remove_session_cb; |
1235 | } | 1273 | } |
1274 | LSSL_ALIAS(SSL_CTX_sess_get_remove_cb); | ||
1236 | 1275 | ||
1237 | void | 1276 | void |
1238 | SSL_CTX_sess_set_get_cb(SSL_CTX *ctx, SSL_SESSION *(*cb)(struct ssl_st *ssl, | 1277 | SSL_CTX_sess_set_get_cb(SSL_CTX *ctx, SSL_SESSION *(*cb)(struct ssl_st *ssl, |
@@ -1240,6 +1279,7 @@ SSL_CTX_sess_set_get_cb(SSL_CTX *ctx, SSL_SESSION *(*cb)(struct ssl_st *ssl, | |||
1240 | { | 1279 | { |
1241 | ctx->get_session_cb = cb; | 1280 | ctx->get_session_cb = cb; |
1242 | } | 1281 | } |
1282 | LSSL_ALIAS(SSL_CTX_sess_set_get_cb); | ||
1243 | 1283 | ||
1244 | SSL_SESSION * | 1284 | SSL_SESSION * |
1245 | (*SSL_CTX_sess_get_get_cb(SSL_CTX *ctx))(SSL *ssl, const unsigned char *data, | 1285 | (*SSL_CTX_sess_get_get_cb(SSL_CTX *ctx))(SSL *ssl, const unsigned char *data, |
@@ -1247,6 +1287,7 @@ SSL_SESSION * | |||
1247 | { | 1287 | { |
1248 | return ctx->get_session_cb; | 1288 | return ctx->get_session_cb; |
1249 | } | 1289 | } |
1290 | LSSL_ALIAS(SSL_CTX_sess_get_get_cb); | ||
1250 | 1291 | ||
1251 | void | 1292 | void |
1252 | SSL_CTX_set_info_callback(SSL_CTX *ctx, | 1293 | SSL_CTX_set_info_callback(SSL_CTX *ctx, |
@@ -1254,12 +1295,14 @@ SSL_CTX_set_info_callback(SSL_CTX *ctx, | |||
1254 | { | 1295 | { |
1255 | ctx->info_callback = cb; | 1296 | ctx->info_callback = cb; |
1256 | } | 1297 | } |
1298 | LSSL_ALIAS(SSL_CTX_set_info_callback); | ||
1257 | 1299 | ||
1258 | void | 1300 | void |
1259 | (*SSL_CTX_get_info_callback(SSL_CTX *ctx))(const SSL *ssl, int type, int val) | 1301 | (*SSL_CTX_get_info_callback(SSL_CTX *ctx))(const SSL *ssl, int type, int val) |
1260 | { | 1302 | { |
1261 | return ctx->info_callback; | 1303 | return ctx->info_callback; |
1262 | } | 1304 | } |
1305 | LSSL_ALIAS(SSL_CTX_get_info_callback); | ||
1263 | 1306 | ||
1264 | void | 1307 | void |
1265 | SSL_CTX_set_client_cert_cb(SSL_CTX *ctx, | 1308 | SSL_CTX_set_client_cert_cb(SSL_CTX *ctx, |
@@ -1267,6 +1310,7 @@ SSL_CTX_set_client_cert_cb(SSL_CTX *ctx, | |||
1267 | { | 1310 | { |
1268 | ctx->client_cert_cb = cb; | 1311 | ctx->client_cert_cb = cb; |
1269 | } | 1312 | } |
1313 | LSSL_ALIAS(SSL_CTX_set_client_cert_cb); | ||
1270 | 1314 | ||
1271 | int | 1315 | int |
1272 | (*SSL_CTX_get_client_cert_cb(SSL_CTX *ctx))(SSL * ssl, X509 ** x509, | 1316 | (*SSL_CTX_get_client_cert_cb(SSL_CTX *ctx))(SSL * ssl, X509 ** x509, |
@@ -1274,6 +1318,7 @@ int | |||
1274 | { | 1318 | { |
1275 | return ctx->client_cert_cb; | 1319 | return ctx->client_cert_cb; |
1276 | } | 1320 | } |
1321 | LSSL_ALIAS(SSL_CTX_get_client_cert_cb); | ||
1277 | 1322 | ||
1278 | #ifndef OPENSSL_NO_ENGINE | 1323 | #ifndef OPENSSL_NO_ENGINE |
1279 | int | 1324 | int |
@@ -1291,6 +1336,7 @@ SSL_CTX_set_client_cert_engine(SSL_CTX *ctx, ENGINE *e) | |||
1291 | ctx->client_cert_engine = e; | 1336 | ctx->client_cert_engine = e; |
1292 | return 1; | 1337 | return 1; |
1293 | } | 1338 | } |
1339 | LSSL_ALIAS(SSL_CTX_set_client_cert_engine); | ||
1294 | #endif | 1340 | #endif |
1295 | 1341 | ||
1296 | void | 1342 | void |
@@ -1299,6 +1345,7 @@ SSL_CTX_set_cookie_generate_cb(SSL_CTX *ctx, | |||
1299 | { | 1345 | { |
1300 | ctx->app_gen_cookie_cb = cb; | 1346 | ctx->app_gen_cookie_cb = cb; |
1301 | } | 1347 | } |
1348 | LSSL_ALIAS(SSL_CTX_set_cookie_generate_cb); | ||
1302 | 1349 | ||
1303 | void | 1350 | void |
1304 | SSL_CTX_set_cookie_verify_cb(SSL_CTX *ctx, | 1351 | SSL_CTX_set_cookie_verify_cb(SSL_CTX *ctx, |
@@ -1306,6 +1353,7 @@ SSL_CTX_set_cookie_verify_cb(SSL_CTX *ctx, | |||
1306 | { | 1353 | { |
1307 | ctx->app_verify_cookie_cb = cb; | 1354 | ctx->app_verify_cookie_cb = cb; |
1308 | } | 1355 | } |
1356 | LSSL_ALIAS(SSL_CTX_set_cookie_verify_cb); | ||
1309 | 1357 | ||
1310 | int | 1358 | int |
1311 | PEM_write_SSL_SESSION(FILE *fp, SSL_SESSION *x) | 1359 | PEM_write_SSL_SESSION(FILE *fp, SSL_SESSION *x) |
@@ -1313,6 +1361,7 @@ PEM_write_SSL_SESSION(FILE *fp, SSL_SESSION *x) | |||
1313 | return PEM_ASN1_write((i2d_of_void *)i2d_SSL_SESSION, | 1361 | return PEM_ASN1_write((i2d_of_void *)i2d_SSL_SESSION, |
1314 | PEM_STRING_SSL_SESSION, fp, x, NULL, NULL, 0, NULL, NULL); | 1362 | PEM_STRING_SSL_SESSION, fp, x, NULL, NULL, 0, NULL, NULL); |
1315 | } | 1363 | } |
1364 | LSSL_ALIAS(PEM_write_SSL_SESSION); | ||
1316 | 1365 | ||
1317 | SSL_SESSION * | 1366 | SSL_SESSION * |
1318 | PEM_read_SSL_SESSION(FILE *fp, SSL_SESSION **x, pem_password_cb *cb, void *u) | 1367 | PEM_read_SSL_SESSION(FILE *fp, SSL_SESSION **x, pem_password_cb *cb, void *u) |
@@ -1320,6 +1369,7 @@ PEM_read_SSL_SESSION(FILE *fp, SSL_SESSION **x, pem_password_cb *cb, void *u) | |||
1320 | return PEM_ASN1_read((d2i_of_void *)d2i_SSL_SESSION, | 1369 | return PEM_ASN1_read((d2i_of_void *)d2i_SSL_SESSION, |
1321 | PEM_STRING_SSL_SESSION, fp, (void **)x, cb, u); | 1370 | PEM_STRING_SSL_SESSION, fp, (void **)x, cb, u); |
1322 | } | 1371 | } |
1372 | LSSL_ALIAS(PEM_read_SSL_SESSION); | ||
1323 | 1373 | ||
1324 | SSL_SESSION * | 1374 | SSL_SESSION * |
1325 | PEM_read_bio_SSL_SESSION(BIO *bp, SSL_SESSION **x, pem_password_cb *cb, void *u) | 1375 | PEM_read_bio_SSL_SESSION(BIO *bp, SSL_SESSION **x, pem_password_cb *cb, void *u) |
@@ -1327,6 +1377,7 @@ PEM_read_bio_SSL_SESSION(BIO *bp, SSL_SESSION **x, pem_password_cb *cb, void *u) | |||
1327 | return PEM_ASN1_read_bio((d2i_of_void *)d2i_SSL_SESSION, | 1377 | return PEM_ASN1_read_bio((d2i_of_void *)d2i_SSL_SESSION, |
1328 | PEM_STRING_SSL_SESSION, bp, (void **)x, cb, u); | 1378 | PEM_STRING_SSL_SESSION, bp, (void **)x, cb, u); |
1329 | } | 1379 | } |
1380 | LSSL_ALIAS(PEM_read_bio_SSL_SESSION); | ||
1330 | 1381 | ||
1331 | int | 1382 | int |
1332 | PEM_write_bio_SSL_SESSION(BIO *bp, SSL_SESSION *x) | 1383 | PEM_write_bio_SSL_SESSION(BIO *bp, SSL_SESSION *x) |
@@ -1334,3 +1385,4 @@ PEM_write_bio_SSL_SESSION(BIO *bp, SSL_SESSION *x) | |||
1334 | return PEM_ASN1_write_bio((i2d_of_void *)i2d_SSL_SESSION, | 1385 | return PEM_ASN1_write_bio((i2d_of_void *)i2d_SSL_SESSION, |
1335 | PEM_STRING_SSL_SESSION, bp, x, NULL, NULL, 0, NULL, NULL); | 1386 | PEM_STRING_SSL_SESSION, bp, x, NULL, NULL, 0, NULL, NULL); |
1336 | } | 1387 | } |
1388 | LSSL_ALIAS(PEM_write_bio_SSL_SESSION); | ||