NAME
SSL_CTX_set_client_CA_list, SSL_set_client_CA_list, SSL_CTX_add_client_CA, SSL_add_client_CA — set list of CAs sent to the client when requesting a client certificateSYNOPSIS
#include <openssl/ssl.h>SSL_CTX_set_client_CA_list(SSL_CTX *ctx, STACK_OF(X509_NAME) *list);
SSL_set_client_CA_list(SSL *s, STACK_OF(X509_NAME) *list);
SSL_CTX_add_client_CA(SSL_CTX *ctx, X509 *cacert);
SSL_add_client_CA(SSL *ssl, X509 *cacert);
DESCRIPTION
SSL_CTX_set_client_CA_list() sets the list of CAs sent to the client when requesting a client certificate for ctx.NOTES
When a TLS/SSL server requests a client certificate (see SSL_CTX_set_verify()), it sends a list of CAs for which it will accept certificates to the client.RETURN VALUES
SSL_CTX_set_client_CA_list() and SSL_set_client_CA_list() do not return diagnostic information.- 0
- A failure while manipulating the STACK_OF(X509_NAME) object occurred or the X509_NAME could not be extracted from cacert. Check the error stack to find out the reason.
- 1
- The operation succeeded.
EXAMPLES
Scan all certificates in CAfile and list them as acceptable CAs:SSL_CTX_set_client_CA_list(ctx, SSL_load_client_CA_file(CAfile));