]> git.ipfire.org Git - thirdparty/openssl.git/blame - doc/ssl/SSL_CTX_set_cert_store.pod
Fix nits in pod files.
[thirdparty/openssl.git] / doc / ssl / SSL_CTX_set_cert_store.pod
CommitLineData
141e5849
LJ
1=pod
2
3=head1 NAME
4
5SSL_CTX_set_cert_store, SSL_CTX_get_cert_store - manipulate X509 certificate verification storage
6
7=head1 SYNOPSIS
8
9 #include <openssl/ssl.h>
10
11 void SSL_CTX_set_cert_store(SSL_CTX *ctx, X509_STORE *store);
c3e64028 12 X509_STORE *SSL_CTX_get_cert_store(const SSL_CTX *ctx);
141e5849
LJ
13
14=head1 DESCRIPTION
15
16SSL_CTX_set_cert_store() sets/replaces the certificate verification storage
a5200a1b 17of B<ctx> to/with B<store>. If another X509_STORE object is currently
141e5849
LJ
18set in B<ctx>, it will be X509_STORE_free()ed.
19
20SSL_CTX_get_cert_store() returns a pointer to the current certificate
21verification storage.
22
23=head1 NOTES
24
25In order to verify the certificates presented by the peer, trusted CA
26certificates must be accessed. These CA certificates are made available
27via lookup methods, handled inside the X509_STORE. From the X509_STORE
28the X509_STORE_CTX used when verifying certificates is created.
29
30Typically the trusted certificate store is handled indirectly via using
9b86974e 31L<SSL_CTX_load_verify_locations(3)>.
141e5849
LJ
32Using the SSL_CTX_set_cert_store() and SSL_CTX_get_cert_store() functions
33it is possible to manipulate the X509_STORE object beyond the
9b86974e 34L<SSL_CTX_load_verify_locations(3)>
141e5849
LJ
35call.
36
37Currently no detailed documentation on how to use the X509_STORE
38object is available. Not all members of the X509_STORE are used when
39the verification takes place. So will e.g. the verify_callback() be
40overridden with the verify_callback() set via the
9b86974e 41L<SSL_CTX_set_verify(3)> family of functions.
141e5849
LJ
42This document must therefore be updated when documentation about the
43X509_STORE object and its handling becomes available.
44
eeb15452
DSH
45=head1 RESTRICTIONS
46
47The X509_STORE structure used by an SSL_CTX is used for verifying peer
48certificates and building certificate chains, it is also shared by
1bc74519 49every child SSL structure. Applications wanting finer control can use
eeb15452
DSH
50functions such as SSL_CTX_set1_verify_cert_store() instead.
51
141e5849
LJ
52=head1 RETURN VALUES
53
54SSL_CTX_set_cert_store() does not return diagnostic output.
55
56SSL_CTX_get_cert_store() returns the current setting.
57
58=head1 SEE ALSO
59
9b86974e
RS
60L<ssl(3)>,
61L<SSL_CTX_load_verify_locations(3)>,
62L<SSL_CTX_set_verify(3)>
141e5849
LJ
63
64=cut
e2f92610
RS
65
66=head1 COPYRIGHT
67
68Copyright 2001-2016 The OpenSSL Project Authors. All Rights Reserved.
69
70Licensed under the OpenSSL license (the "License"). You may not use
71this file except in compliance with the License. You can obtain a copy
72in the file LICENSE in the source distribution or at
73L<https://www.openssl.org/source/license.html>.
74
75=cut