summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/x509/x509_vfy.c
diff options
context:
space:
mode:
authorbeck <>2022-11-14 17:48:50 +0000
committerbeck <>2022-11-14 17:48:50 +0000
commit109899f1b36632f5f1c469c4f562df69585eb21e (patch)
treec42f727f8848b4a56e738422f26e8b44150174e4 /src/lib/libcrypto/x509/x509_vfy.c
parentfd2db7678bc81cd8abe106c7bd1c724c8b01888d (diff)
downloadopenbsd-109899f1b36632f5f1c469c4f562df69585eb21e.tar.gz
openbsd-109899f1b36632f5f1c469c4f562df69585eb21e.tar.bz2
openbsd-109899f1b36632f5f1c469c4f562df69585eb21e.zip
Hide public symbols in libcrypto/x509 .c files
ok tb@
Diffstat (limited to 'src/lib/libcrypto/x509/x509_vfy.c')
-rw-r--r--src/lib/libcrypto/x509/x509_vfy.c54
1 files changed, 53 insertions, 1 deletions
diff --git a/src/lib/libcrypto/x509/x509_vfy.c b/src/lib/libcrypto/x509/x509_vfy.c
index 11bf3d9292..09c0b8105e 100644
--- a/src/lib/libcrypto/x509/x509_vfy.c
+++ b/src/lib/libcrypto/x509/x509_vfy.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: x509_vfy.c,v 1.104 2022/11/13 18:37:32 beck Exp $ */ 1/* $OpenBSD: x509_vfy.c,v 1.105 2022/11/14 17:48:50 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 *
@@ -668,6 +668,7 @@ X509_verify_cert(X509_STORE_CTX *ctx)
668 /* if we succeed we have a chain in ctx->chain */ 668 /* if we succeed we have a chain in ctx->chain */
669 return (chain_count > 0 && ctx->chain != NULL); 669 return (chain_count > 0 && ctx->chain != NULL);
670} 670}
671LCRYPTO_ALIAS(X509_verify_cert)
671 672
672/* Given a STACK_OF(X509) find the issuer of cert (if any) 673/* Given a STACK_OF(X509) find the issuer of cert (if any)
673 */ 674 */
@@ -2062,6 +2063,7 @@ X509_cmp_current_time(const ASN1_TIME *ctm)
2062{ 2063{
2063 return X509_cmp_time(ctm, NULL); 2064 return X509_cmp_time(ctm, NULL);
2064} 2065}
2066LCRYPTO_ALIAS(X509_cmp_current_time)
2065 2067
2066/* 2068/*
2067 * Compare a possibly unvalidated ASN1_TIME string against a time_t 2069 * Compare a possibly unvalidated ASN1_TIME string against a time_t
@@ -2101,6 +2103,7 @@ X509_cmp_time(const ASN1_TIME *ctm, time_t *cmp_time)
2101{ 2103{
2102 return X509_cmp_time_internal(ctm, cmp_time, 0); 2104 return X509_cmp_time_internal(ctm, cmp_time, 0);
2103} 2105}
2106LCRYPTO_ALIAS(X509_cmp_time)
2104 2107
2105 2108
2106ASN1_TIME * 2109ASN1_TIME *
@@ -2108,12 +2111,14 @@ X509_gmtime_adj(ASN1_TIME *s, long adj)
2108{ 2111{
2109 return X509_time_adj(s, adj, NULL); 2112 return X509_time_adj(s, adj, NULL);
2110} 2113}
2114LCRYPTO_ALIAS(X509_gmtime_adj)
2111 2115
2112ASN1_TIME * 2116ASN1_TIME *
2113X509_time_adj(ASN1_TIME *s, long offset_sec, time_t *in_time) 2117X509_time_adj(ASN1_TIME *s, long offset_sec, time_t *in_time)
2114{ 2118{
2115 return X509_time_adj_ex(s, 0, offset_sec, in_time); 2119 return X509_time_adj_ex(s, 0, offset_sec, in_time);
2116} 2120}
2121LCRYPTO_ALIAS(X509_time_adj)
2117 2122
2118ASN1_TIME * 2123ASN1_TIME *
2119X509_time_adj_ex(ASN1_TIME *s, int offset_day, long offset_sec, time_t *in_time) 2124X509_time_adj_ex(ASN1_TIME *s, int offset_day, long offset_sec, time_t *in_time)
@@ -2126,6 +2131,7 @@ X509_time_adj_ex(ASN1_TIME *s, int offset_day, long offset_sec, time_t *in_time)
2126 2131
2127 return ASN1_TIME_adj(s, t, offset_day, offset_sec); 2132 return ASN1_TIME_adj(s, t, offset_day, offset_sec);
2128} 2133}
2134LCRYPTO_ALIAS(X509_time_adj_ex)
2129 2135
2130int 2136int
2131X509_get_pubkey_parameters(EVP_PKEY *pkey, STACK_OF(X509) *chain) 2137X509_get_pubkey_parameters(EVP_PKEY *pkey, STACK_OF(X509) *chain)
@@ -2165,6 +2171,7 @@ X509_get_pubkey_parameters(EVP_PKEY *pkey, STACK_OF(X509) *chain)
2165 return 0; 2171 return 0;
2166 return 1; 2172 return 1;
2167} 2173}
2174LCRYPTO_ALIAS(X509_get_pubkey_parameters)
2168 2175
2169int 2176int
2170X509_STORE_CTX_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, 2177X509_STORE_CTX_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func,
@@ -2175,66 +2182,77 @@ X509_STORE_CTX_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func,
2175 return CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_X509_STORE_CTX, 2182 return CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_X509_STORE_CTX,
2176 argl, argp, new_func, dup_func, free_func); 2183 argl, argp, new_func, dup_func, free_func);
2177} 2184}
2185LCRYPTO_ALIAS(X509_STORE_CTX_get_ex_new_index)
2178 2186
2179int 2187int
2180X509_STORE_CTX_set_ex_data(X509_STORE_CTX *ctx, int idx, void *data) 2188X509_STORE_CTX_set_ex_data(X509_STORE_CTX *ctx, int idx, void *data)
2181{ 2189{
2182 return CRYPTO_set_ex_data(&ctx->ex_data, idx, data); 2190 return CRYPTO_set_ex_data(&ctx->ex_data, idx, data);
2183} 2191}
2192LCRYPTO_ALIAS(X509_STORE_CTX_set_ex_data)
2184 2193
2185void * 2194void *
2186X509_STORE_CTX_get_ex_data(X509_STORE_CTX *ctx, int idx) 2195X509_STORE_CTX_get_ex_data(X509_STORE_CTX *ctx, int idx)
2187{ 2196{
2188 return CRYPTO_get_ex_data(&ctx->ex_data, idx); 2197 return CRYPTO_get_ex_data(&ctx->ex_data, idx);
2189} 2198}
2199LCRYPTO_ALIAS(X509_STORE_CTX_get_ex_data)
2190 2200
2191int 2201int
2192X509_STORE_CTX_get_error(X509_STORE_CTX *ctx) 2202X509_STORE_CTX_get_error(X509_STORE_CTX *ctx)
2193{ 2203{
2194 return ctx->error; 2204 return ctx->error;
2195} 2205}
2206LCRYPTO_ALIAS(X509_STORE_CTX_get_error)
2196 2207
2197void 2208void
2198X509_STORE_CTX_set_error(X509_STORE_CTX *ctx, int err) 2209X509_STORE_CTX_set_error(X509_STORE_CTX *ctx, int err)
2199{ 2210{
2200 ctx->error = err; 2211 ctx->error = err;
2201} 2212}
2213LCRYPTO_ALIAS(X509_STORE_CTX_set_error)
2202 2214
2203int 2215int
2204X509_STORE_CTX_get_error_depth(X509_STORE_CTX *ctx) 2216X509_STORE_CTX_get_error_depth(X509_STORE_CTX *ctx)
2205{ 2217{
2206 return ctx->error_depth; 2218 return ctx->error_depth;
2207} 2219}
2220LCRYPTO_ALIAS(X509_STORE_CTX_get_error_depth)
2208 2221
2209void 2222void
2210X509_STORE_CTX_set_error_depth(X509_STORE_CTX *ctx, int depth) 2223X509_STORE_CTX_set_error_depth(X509_STORE_CTX *ctx, int depth)
2211{ 2224{
2212 ctx->error_depth = depth; 2225 ctx->error_depth = depth;
2213} 2226}
2227LCRYPTO_ALIAS(X509_STORE_CTX_set_error_depth)
2214 2228
2215X509 * 2229X509 *
2216X509_STORE_CTX_get_current_cert(X509_STORE_CTX *ctx) 2230X509_STORE_CTX_get_current_cert(X509_STORE_CTX *ctx)
2217{ 2231{
2218 return ctx->current_cert; 2232 return ctx->current_cert;
2219} 2233}
2234LCRYPTO_ALIAS(X509_STORE_CTX_get_current_cert)
2220 2235
2221void 2236void
2222X509_STORE_CTX_set_current_cert(X509_STORE_CTX *ctx, X509 *x) 2237X509_STORE_CTX_set_current_cert(X509_STORE_CTX *ctx, X509 *x)
2223{ 2238{
2224 ctx->current_cert = x; 2239 ctx->current_cert = x;
2225} 2240}
2241LCRYPTO_ALIAS(X509_STORE_CTX_set_current_cert)
2226 2242
2227STACK_OF(X509) * 2243STACK_OF(X509) *
2228X509_STORE_CTX_get_chain(X509_STORE_CTX *ctx) 2244X509_STORE_CTX_get_chain(X509_STORE_CTX *ctx)
2229{ 2245{
2230 return ctx->chain; 2246 return ctx->chain;
2231} 2247}
2248LCRYPTO_ALIAS(X509_STORE_CTX_get_chain)
2232 2249
2233STACK_OF(X509) * 2250STACK_OF(X509) *
2234X509_STORE_CTX_get0_chain(X509_STORE_CTX *xs) 2251X509_STORE_CTX_get0_chain(X509_STORE_CTX *xs)
2235{ 2252{
2236 return xs->chain; 2253 return xs->chain;
2237} 2254}
2255LCRYPTO_ALIAS(X509_STORE_CTX_get0_chain)
2238 2256
2239STACK_OF(X509) * 2257STACK_OF(X509) *
2240X509_STORE_CTX_get1_chain(X509_STORE_CTX *ctx) 2258X509_STORE_CTX_get1_chain(X509_STORE_CTX *ctx)
@@ -2251,60 +2269,70 @@ X509_STORE_CTX_get1_chain(X509_STORE_CTX *ctx)
2251 } 2269 }
2252 return chain; 2270 return chain;
2253} 2271}
2272LCRYPTO_ALIAS(X509_STORE_CTX_get1_chain)
2254 2273
2255X509 * 2274X509 *
2256X509_STORE_CTX_get0_current_issuer(X509_STORE_CTX *ctx) 2275X509_STORE_CTX_get0_current_issuer(X509_STORE_CTX *ctx)
2257{ 2276{
2258 return ctx->current_issuer; 2277 return ctx->current_issuer;
2259} 2278}
2279LCRYPTO_ALIAS(X509_STORE_CTX_get0_current_issuer)
2260 2280
2261X509_CRL * 2281X509_CRL *
2262X509_STORE_CTX_get0_current_crl(X509_STORE_CTX *ctx) 2282X509_STORE_CTX_get0_current_crl(X509_STORE_CTX *ctx)
2263{ 2283{
2264 return ctx->current_crl; 2284 return ctx->current_crl;
2265} 2285}
2286LCRYPTO_ALIAS(X509_STORE_CTX_get0_current_crl)
2266 2287
2267X509_STORE_CTX * 2288X509_STORE_CTX *
2268X509_STORE_CTX_get0_parent_ctx(X509_STORE_CTX *ctx) 2289X509_STORE_CTX_get0_parent_ctx(X509_STORE_CTX *ctx)
2269{ 2290{
2270 return ctx->parent; 2291 return ctx->parent;
2271} 2292}
2293LCRYPTO_ALIAS(X509_STORE_CTX_get0_parent_ctx)
2272 2294
2273X509_STORE * 2295X509_STORE *
2274X509_STORE_CTX_get0_store(X509_STORE_CTX *xs) 2296X509_STORE_CTX_get0_store(X509_STORE_CTX *xs)
2275{ 2297{
2276 return xs->store; 2298 return xs->store;
2277} 2299}
2300LCRYPTO_ALIAS(X509_STORE_CTX_get0_store)
2278 2301
2279void 2302void
2280X509_STORE_CTX_set_cert(X509_STORE_CTX *ctx, X509 *x) 2303X509_STORE_CTX_set_cert(X509_STORE_CTX *ctx, X509 *x)
2281{ 2304{
2282 ctx->cert = x; 2305 ctx->cert = x;
2283} 2306}
2307LCRYPTO_ALIAS(X509_STORE_CTX_set_cert)
2284 2308
2285void 2309void
2286X509_STORE_CTX_set_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk) 2310X509_STORE_CTX_set_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk)
2287{ 2311{
2288 ctx->untrusted = sk; 2312 ctx->untrusted = sk;
2289} 2313}
2314LCRYPTO_ALIAS(X509_STORE_CTX_set_chain)
2290 2315
2291void 2316void
2292X509_STORE_CTX_set0_crls(X509_STORE_CTX *ctx, STACK_OF(X509_CRL) *sk) 2317X509_STORE_CTX_set0_crls(X509_STORE_CTX *ctx, STACK_OF(X509_CRL) *sk)
2293{ 2318{
2294 ctx->crls = sk; 2319 ctx->crls = sk;
2295} 2320}
2321LCRYPTO_ALIAS(X509_STORE_CTX_set0_crls)
2296 2322
2297int 2323int
2298X509_STORE_CTX_set_purpose(X509_STORE_CTX *ctx, int purpose) 2324X509_STORE_CTX_set_purpose(X509_STORE_CTX *ctx, int purpose)
2299{ 2325{
2300 return X509_STORE_CTX_purpose_inherit(ctx, 0, purpose, 0); 2326 return X509_STORE_CTX_purpose_inherit(ctx, 0, purpose, 0);
2301} 2327}
2328LCRYPTO_ALIAS(X509_STORE_CTX_set_purpose)
2302 2329
2303int 2330int
2304X509_STORE_CTX_set_trust(X509_STORE_CTX *ctx, int trust) 2331X509_STORE_CTX_set_trust(X509_STORE_CTX *ctx, int trust)
2305{ 2332{
2306 return X509_STORE_CTX_purpose_inherit(ctx, 0, 0, trust); 2333 return X509_STORE_CTX_purpose_inherit(ctx, 0, 0, trust);
2307} 2334}
2335LCRYPTO_ALIAS(X509_STORE_CTX_set_trust)
2308 2336
2309/* This function is used to set the X509_STORE_CTX purpose and trust 2337/* This function is used to set the X509_STORE_CTX purpose and trust
2310 * values. This is intended to be used when another structure has its 2338 * values. This is intended to be used when another structure has its
@@ -2360,6 +2388,7 @@ X509_STORE_CTX_purpose_inherit(X509_STORE_CTX *ctx, int def_purpose,
2360 ctx->param->trust = trust; 2388 ctx->param->trust = trust;
2361 return 1; 2389 return 1;
2362} 2390}
2391LCRYPTO_ALIAS(X509_STORE_CTX_purpose_inherit)
2363 2392
2364X509_STORE_CTX * 2393X509_STORE_CTX *
2365X509_STORE_CTX_new(void) 2394X509_STORE_CTX_new(void)
@@ -2373,6 +2402,7 @@ X509_STORE_CTX_new(void)
2373 } 2402 }
2374 return ctx; 2403 return ctx;
2375} 2404}
2405LCRYPTO_ALIAS(X509_STORE_CTX_new)
2376 2406
2377void 2407void
2378X509_STORE_CTX_free(X509_STORE_CTX *ctx) 2408X509_STORE_CTX_free(X509_STORE_CTX *ctx)
@@ -2383,6 +2413,7 @@ X509_STORE_CTX_free(X509_STORE_CTX *ctx)
2383 X509_STORE_CTX_cleanup(ctx); 2413 X509_STORE_CTX_cleanup(ctx);
2384 free(ctx); 2414 free(ctx);
2385} 2415}
2416LCRYPTO_ALIAS(X509_STORE_CTX_free)
2386 2417
2387int 2418int
2388X509_STORE_CTX_init(X509_STORE_CTX *ctx, X509_STORE *store, X509 *x509, 2419X509_STORE_CTX_init(X509_STORE_CTX *ctx, X509_STORE *store, X509 *x509,
@@ -2504,6 +2535,7 @@ X509_STORE_CTX_init(X509_STORE_CTX *ctx, X509_STORE *store, X509 *x509,
2504 } 2535 }
2505 return 1; 2536 return 1;
2506} 2537}
2538LCRYPTO_ALIAS(X509_STORE_CTX_init)
2507 2539
2508/* Set alternative lookup method: just a STACK of trusted certificates. 2540/* Set alternative lookup method: just a STACK of trusted certificates.
2509 * This avoids X509_STORE nastiness where it isn't needed. 2541 * This avoids X509_STORE nastiness where it isn't needed.
@@ -2515,12 +2547,14 @@ X509_STORE_CTX_trusted_stack(X509_STORE_CTX *ctx, STACK_OF(X509) *sk)
2515 ctx->other_ctx = sk; 2547 ctx->other_ctx = sk;
2516 ctx->get_issuer = get_issuer_sk; 2548 ctx->get_issuer = get_issuer_sk;
2517} 2549}
2550LCRYPTO_ALIAS(X509_STORE_CTX_trusted_stack)
2518 2551
2519void 2552void
2520X509_STORE_CTX_set0_trusted_stack(X509_STORE_CTX *ctx, STACK_OF(X509) *sk) 2553X509_STORE_CTX_set0_trusted_stack(X509_STORE_CTX *ctx, STACK_OF(X509) *sk)
2521{ 2554{
2522 X509_STORE_CTX_trusted_stack(ctx, sk); 2555 X509_STORE_CTX_trusted_stack(ctx, sk);
2523} 2556}
2557LCRYPTO_ALIAS(X509_STORE_CTX_set0_trusted_stack)
2524 2558
2525void 2559void
2526X509_STORE_CTX_cleanup(X509_STORE_CTX *ctx) 2560X509_STORE_CTX_cleanup(X509_STORE_CTX *ctx)
@@ -2544,30 +2578,35 @@ X509_STORE_CTX_cleanup(X509_STORE_CTX *ctx)
2544 ctx, &(ctx->ex_data)); 2578 ctx, &(ctx->ex_data));
2545 memset(&ctx->ex_data, 0, sizeof(CRYPTO_EX_DATA)); 2579 memset(&ctx->ex_data, 0, sizeof(CRYPTO_EX_DATA));
2546} 2580}
2581LCRYPTO_ALIAS(X509_STORE_CTX_cleanup)
2547 2582
2548void 2583void
2549X509_STORE_CTX_set_depth(X509_STORE_CTX *ctx, int depth) 2584X509_STORE_CTX_set_depth(X509_STORE_CTX *ctx, int depth)
2550{ 2585{
2551 X509_VERIFY_PARAM_set_depth(ctx->param, depth); 2586 X509_VERIFY_PARAM_set_depth(ctx->param, depth);
2552} 2587}
2588LCRYPTO_ALIAS(X509_STORE_CTX_set_depth)
2553 2589
2554void 2590void
2555X509_STORE_CTX_set_flags(X509_STORE_CTX *ctx, unsigned long flags) 2591X509_STORE_CTX_set_flags(X509_STORE_CTX *ctx, unsigned long flags)
2556{ 2592{
2557 X509_VERIFY_PARAM_set_flags(ctx->param, flags); 2593 X509_VERIFY_PARAM_set_flags(ctx->param, flags);
2558} 2594}
2595LCRYPTO_ALIAS(X509_STORE_CTX_set_flags)
2559 2596
2560void 2597void
2561X509_STORE_CTX_set_time(X509_STORE_CTX *ctx, unsigned long flags, time_t t) 2598X509_STORE_CTX_set_time(X509_STORE_CTX *ctx, unsigned long flags, time_t t)
2562{ 2599{
2563 X509_VERIFY_PARAM_set_time(ctx->param, t); 2600 X509_VERIFY_PARAM_set_time(ctx->param, t);
2564} 2601}
2602LCRYPTO_ALIAS(X509_STORE_CTX_set_time)
2565 2603
2566int 2604int
2567(*X509_STORE_CTX_get_verify_cb(X509_STORE_CTX *ctx))(int, X509_STORE_CTX *) 2605(*X509_STORE_CTX_get_verify_cb(X509_STORE_CTX *ctx))(int, X509_STORE_CTX *)
2568{ 2606{
2569 return ctx->verify_cb; 2607 return ctx->verify_cb;
2570} 2608}
2609LCRYPTO_ALIAS(X509_STORE_CTX_get_verify_cb)
2571 2610
2572void 2611void
2573X509_STORE_CTX_set_verify_cb(X509_STORE_CTX *ctx, 2612X509_STORE_CTX_set_verify_cb(X509_STORE_CTX *ctx,
@@ -2575,36 +2614,42 @@ X509_STORE_CTX_set_verify_cb(X509_STORE_CTX *ctx,
2575{ 2614{
2576 ctx->verify_cb = verify_cb; 2615 ctx->verify_cb = verify_cb;
2577} 2616}
2617LCRYPTO_ALIAS(X509_STORE_CTX_set_verify_cb)
2578 2618
2579int 2619int
2580(*X509_STORE_CTX_get_verify(X509_STORE_CTX *ctx))(X509_STORE_CTX *) 2620(*X509_STORE_CTX_get_verify(X509_STORE_CTX *ctx))(X509_STORE_CTX *)
2581{ 2621{
2582 return ctx->verify; 2622 return ctx->verify;
2583} 2623}
2624LCRYPTO_ALIAS(X509_STORE_CTX_get_verify)
2584 2625
2585void 2626void
2586X509_STORE_CTX_set_verify(X509_STORE_CTX *ctx, int (*verify)(X509_STORE_CTX *)) 2627X509_STORE_CTX_set_verify(X509_STORE_CTX *ctx, int (*verify)(X509_STORE_CTX *))
2587{ 2628{
2588 ctx->verify = verify; 2629 ctx->verify = verify;
2589} 2630}
2631LCRYPTO_ALIAS(X509_STORE_CTX_set_verify)
2590 2632
2591X509 * 2633X509 *
2592X509_STORE_CTX_get0_cert(X509_STORE_CTX *ctx) 2634X509_STORE_CTX_get0_cert(X509_STORE_CTX *ctx)
2593{ 2635{
2594 return ctx->cert; 2636 return ctx->cert;
2595} 2637}
2638LCRYPTO_ALIAS(X509_STORE_CTX_get0_cert)
2596 2639
2597STACK_OF(X509) * 2640STACK_OF(X509) *
2598X509_STORE_CTX_get0_untrusted(X509_STORE_CTX *ctx) 2641X509_STORE_CTX_get0_untrusted(X509_STORE_CTX *ctx)
2599{ 2642{
2600 return ctx->untrusted; 2643 return ctx->untrusted;
2601} 2644}
2645LCRYPTO_ALIAS(X509_STORE_CTX_get0_untrusted)
2602 2646
2603void 2647void
2604X509_STORE_CTX_set0_untrusted(X509_STORE_CTX *ctx, STACK_OF(X509) *sk) 2648X509_STORE_CTX_set0_untrusted(X509_STORE_CTX *ctx, STACK_OF(X509) *sk)
2605{ 2649{
2606 ctx->untrusted = sk; 2650 ctx->untrusted = sk;
2607} 2651}
2652LCRYPTO_ALIAS(X509_STORE_CTX_set0_untrusted)
2608 2653
2609void 2654void
2610X509_STORE_CTX_set0_verified_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk) 2655X509_STORE_CTX_set0_verified_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk)
@@ -2612,24 +2657,28 @@ X509_STORE_CTX_set0_verified_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk)
2612 sk_X509_pop_free(ctx->chain, X509_free); 2657 sk_X509_pop_free(ctx->chain, X509_free);
2613 ctx->chain = sk; 2658 ctx->chain = sk;
2614} 2659}
2660LCRYPTO_ALIAS(X509_STORE_CTX_set0_verified_chain)
2615 2661
2616X509_POLICY_TREE * 2662X509_POLICY_TREE *
2617X509_STORE_CTX_get0_policy_tree(X509_STORE_CTX *ctx) 2663X509_STORE_CTX_get0_policy_tree(X509_STORE_CTX *ctx)
2618{ 2664{
2619 return ctx->tree; 2665 return ctx->tree;
2620} 2666}
2667LCRYPTO_ALIAS(X509_STORE_CTX_get0_policy_tree)
2621 2668
2622int 2669int
2623X509_STORE_CTX_get_explicit_policy(X509_STORE_CTX *ctx) 2670X509_STORE_CTX_get_explicit_policy(X509_STORE_CTX *ctx)
2624{ 2671{
2625 return ctx->explicit_policy; 2672 return ctx->explicit_policy;
2626} 2673}
2674LCRYPTO_ALIAS(X509_STORE_CTX_get_explicit_policy)
2627 2675
2628int 2676int
2629X509_STORE_CTX_get_num_untrusted(X509_STORE_CTX *ctx) 2677X509_STORE_CTX_get_num_untrusted(X509_STORE_CTX *ctx)
2630{ 2678{
2631 return ctx->num_untrusted; 2679 return ctx->num_untrusted;
2632} 2680}
2681LCRYPTO_ALIAS(X509_STORE_CTX_get_num_untrusted)
2633 2682
2634int 2683int
2635X509_STORE_CTX_set_default(X509_STORE_CTX *ctx, const char *name) 2684X509_STORE_CTX_set_default(X509_STORE_CTX *ctx, const char *name)
@@ -2640,12 +2689,14 @@ X509_STORE_CTX_set_default(X509_STORE_CTX *ctx, const char *name)
2640 return 0; 2689 return 0;
2641 return X509_VERIFY_PARAM_inherit(ctx->param, param); 2690 return X509_VERIFY_PARAM_inherit(ctx->param, param);
2642} 2691}
2692LCRYPTO_ALIAS(X509_STORE_CTX_set_default)
2643 2693
2644X509_VERIFY_PARAM * 2694X509_VERIFY_PARAM *
2645X509_STORE_CTX_get0_param(X509_STORE_CTX *ctx) 2695X509_STORE_CTX_get0_param(X509_STORE_CTX *ctx)
2646{ 2696{
2647 return ctx->param; 2697 return ctx->param;
2648} 2698}
2699LCRYPTO_ALIAS(X509_STORE_CTX_get0_param)
2649 2700
2650void 2701void
2651X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param) 2702X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param)
@@ -2654,6 +2705,7 @@ X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param)
2654 X509_VERIFY_PARAM_free(ctx->param); 2705 X509_VERIFY_PARAM_free(ctx->param);
2655 ctx->param = param; 2706 ctx->param = param;
2656} 2707}
2708LCRYPTO_ALIAS(X509_STORE_CTX_set0_param)
2657 2709
2658/* 2710/*
2659 * Check if |bits| are adequate for |security level|. 2711 * Check if |bits| are adequate for |security level|.