|
Packit |
c4476c |
=pod
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 NAME
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
SSL_CTX_add_extra_chain_cert, SSL_CTX_clear_extra_chain_certs - add or clear
|
|
Packit |
c4476c |
extra chain certificates
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 SYNOPSIS
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
#include <openssl/ssl.h>
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
long SSL_CTX_add_extra_chain_cert(SSL_CTX *ctx, X509 *x509);
|
|
Packit |
c4476c |
long SSL_CTX_clear_extra_chain_certs(SSL_CTX *ctx);
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 DESCRIPTION
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
SSL_CTX_add_extra_chain_cert() adds the certificate B<x509> to the extra chain
|
|
Packit |
c4476c |
certificates associated with B<ctx>. Several certificates can be added one
|
|
Packit |
c4476c |
after another.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
SSL_CTX_clear_extra_chain_certs() clears all extra chain certificates
|
|
Packit |
c4476c |
associated with B<ctx>.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
These functions are implemented as macros.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 NOTES
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
When sending a certificate chain, extra chain certificates are sent in order
|
|
Packit |
c4476c |
following the end entity certificate.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
If no chain is specified, the library will try to complete the chain from the
|
|
Packit |
c4476c |
available CA certificates in the trusted CA storage, see
|
|
Packit |
c4476c |
L<SSL_CTX_load_verify_locations(3)>.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
The B<x509> certificate provided to SSL_CTX_add_extra_chain_cert() will be
|
|
Packit |
c4476c |
freed by the library when the B<SSL_CTX> is destroyed. An application
|
|
Packit |
c4476c |
B<should not> free the B<x509> object.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 RESTRICTIONS
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
Only one set of extra chain certificates can be specified per SSL_CTX
|
|
Packit |
c4476c |
structure. Different chains for different certificates (for example if both
|
|
Packit |
c4476c |
RSA and DSA certificates are specified by the same server) or different SSL
|
|
Packit |
c4476c |
structures with the same parent SSL_CTX cannot be specified using this
|
|
Packit |
c4476c |
function. For more flexibility functions such as SSL_add1_chain_cert() should
|
|
Packit |
c4476c |
be used instead.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 RETURN VALUES
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
SSL_CTX_add_extra_chain_cert() and SSL_CTX_clear_extra_chain_certs() return
|
|
Packit |
c4476c |
1 on success and 0 for failure. Check out the error stack to find out the
|
|
Packit |
c4476c |
reason for failure.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 SEE ALSO
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
L<ssl(7)>,
|
|
Packit |
c4476c |
L<SSL_CTX_use_certificate(3)>,
|
|
Packit |
c4476c |
L<SSL_CTX_set_client_cert_cb(3)>,
|
|
Packit |
c4476c |
L<SSL_CTX_load_verify_locations(3)>
|
|
Packit |
c4476c |
L<SSL_CTX_set0_chain(3)>
|
|
Packit |
c4476c |
L<SSL_CTX_set1_chain(3)>
|
|
Packit |
c4476c |
L<SSL_CTX_add0_chain_cert(3)>
|
|
Packit |
c4476c |
L<SSL_CTX_add1_chain_cert(3)>
|
|
Packit |
c4476c |
L<SSL_set0_chain(3)>
|
|
Packit |
c4476c |
L<SSL_set1_chain(3)>
|
|
Packit |
c4476c |
L<SSL_add0_chain_cert(3)>
|
|
Packit |
c4476c |
L<SSL_add1_chain_cert(3)>
|
|
Packit |
c4476c |
L<SSL_CTX_build_cert_chain(3)>
|
|
Packit |
c4476c |
L<SSL_build_cert_chain(3)>
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=head1 COPYRIGHT
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
Licensed under the OpenSSL license (the "License"). You may not use
|
|
Packit |
c4476c |
this file except in compliance with the License. You can obtain a copy
|
|
Packit |
c4476c |
in the file LICENSE in the source distribution or at
|
|
Packit |
c4476c |
L<https://www.openssl.org/source/license.html>.
|
|
Packit |
c4476c |
|
|
Packit |
c4476c |
=cut
|