1*2175Sjp161948=pod 2*2175Sjp161948 3*2175Sjp161948=head1 NAME 4*2175Sjp161948 5*2175Sjp161948SSL_CTX_free - free an allocated SSL_CTX object 6*2175Sjp161948 7*2175Sjp161948=head1 SYNOPSIS 8*2175Sjp161948 9*2175Sjp161948 #include <openssl/ssl.h> 10*2175Sjp161948 11*2175Sjp161948 void SSL_CTX_free(SSL_CTX *ctx); 12*2175Sjp161948 13*2175Sjp161948=head1 DESCRIPTION 14*2175Sjp161948 15*2175Sjp161948SSL_CTX_free() decrements the reference count of B<ctx>, and removes the 16*2175Sjp161948SSL_CTX object pointed to by B<ctx> and frees up the allocated memory if the 17*2175Sjp161948the reference count has reached 0. 18*2175Sjp161948 19*2175Sjp161948It also calls the free()ing procedures for indirectly affected items, if 20*2175Sjp161948applicable: the session cache, the list of ciphers, the list of Client CAs, 21*2175Sjp161948the certificates and keys. 22*2175Sjp161948 23*2175Sjp161948=head1 WARNINGS 24*2175Sjp161948 25*2175Sjp161948If a session-remove callback is set (SSL_CTX_sess_set_remove_cb()), this 26*2175Sjp161948callback will be called for each session being freed from B<ctx>'s 27*2175Sjp161948session cache. This implies, that all corresponding sessions from an 28*2175Sjp161948external session cache are removed as well. If this is not desired, the user 29*2175Sjp161948should explicitly unset the callback by calling 30*2175Sjp161948SSL_CTX_sess_set_remove_cb(B<ctx>, NULL) prior to calling SSL_CTX_free(). 31*2175Sjp161948 32*2175Sjp161948=head1 RETURN VALUES 33*2175Sjp161948 34*2175Sjp161948SSL_CTX_free() does not provide diagnostic information. 35*2175Sjp161948 36*2175Sjp161948=head1 SEE ALSO 37*2175Sjp161948 38*2175Sjp161948L<SSL_CTX_new(3)|SSL_CTX_new(3)>, L<ssl(3)|ssl(3)>, 39*2175Sjp161948L<SSL_CTX_sess_set_get_cb(3)|SSL_CTX_sess_set_get_cb(3)> 40*2175Sjp161948 41*2175Sjp161948=cut 42