SSL_CTX_add_extra_chain_cert.pod revision 269682
1138132Ssimon=pod 2138132Ssimon 3138132Ssimon=head1 NAME 4138132Ssimon 5138132SsimonSSL_CTX_add_extra_chain_cert - add certificate to chain 6138132Ssimon 7138132Ssimon=head1 SYNOPSIS 8138132Ssimon 9138132Ssimon #include <openssl/ssl.h> 10138132Ssimon 11138132Ssimon long SSL_CTX_add_extra_chain_cert(SSL_CTX ctx, X509 *x509) 12138132Ssimon 13138132Ssimon=head1 DESCRIPTION 14138132Ssimon 15138132SsimonSSL_CTX_add_extra_chain_cert() adds the certificate B<x509> to the certificate 16138132Ssimonchain presented together with the certificate. Several certificates 17138132Ssimoncan be added one after the other. 18138132Ssimon 19138132Ssimon=head1 NOTES 20138132Ssimon 21138132SsimonWhen constructing the certificate chain, the chain will be formed from 22138132Ssimonthese certificates explicitly specified. If no chain is specified, 23138132Ssimonthe library will try to complete the chain from the available CA 24138132Ssimoncertificates in the trusted CA storage, see 25138132SsimonL<SSL_CTX_load_verify_locations(3)|SSL_CTX_load_verify_locations(3)>. 26138132Ssimon 27186810SmavThe B<x509> certificate provided to SSL_CTX_add_extra_chain_cert() will be freed by the library when the B<SSL_CTX> is destroyed. An application B<should not> free the B<x509> object. 28138132Ssimon 29138132Ssimon=head1 RESTRICTIONS 30138132Ssimon 31138132SsimonOnly one set of extra chain certificates can be specified per SSL_CTX 32186810Smavstructure. Different chains for different certificates (for example if both 33138132SsimonRSA and DSA certificates are specified by the same server) or different SSL 34153459Sjoelstructures with the same parent SSL_CTX cannot be specified using this 35153459Sjoelfunction. 36153459Sjoel 37138132Ssimon=head1 RETURN VALUES 38138132Ssimon 39153459SjoelSSL_CTX_add_extra_chain_cert() returns 1 on success. Check out the 40153459Sjoelerror stack to find out the reason for failure otherwise. 41153459Sjoel 42153459Sjoel=head1 SEE ALSO 43153459Sjoel 44153459SjoelL<ssl(3)|ssl(3)>, 45153459SjoelL<SSL_CTX_use_certificate(3)|SSL_CTX_use_certificate(3)>, 46153459SjoelL<SSL_CTX_set_client_cert_cb(3)|SSL_CTX_set_client_cert_cb(3)>, 47138132SsimonL<SSL_CTX_load_verify_locations(3)|SSL_CTX_load_verify_locations(3)> 48138132Ssimon 49138132Ssimon=cut 50159748Sbrueffer