1SSL_free(3) OpenSSL SSL_free(3)
2
3
4
6 SSL_free - free an allocated SSL structure
7
9 #include <openssl/ssl.h>
10
11 void SSL_free(SSL *ssl);
12
14 SSL_free() decrements the reference count of ssl, and removes the SSL
15 structure pointed to by ssl and frees up the allocated memory if the
16 reference count has reached 0.
17
19 SSL_free() also calls the free()ing procedures for indirectly affected
20 items, if applicable: the buffering BIO, the read and write BIOs,
21 cipher lists specially created for this ssl, the SSL_SESSION. Do not
22 explicitly free these indirectly freed up items before or after calling
23 SSL_free(), as trying to free things twice may lead to program failure.
24
25 The ssl session has reference counts from two users: the SSL object,
26 for which the reference count is removed by SSL_free() and the internal
27 session cache. If the session is considered bad, because
28 SSL_shutdown(3) was not called for the connection and
29 SSL_set_shutdown(3) was not used to set the SSL_SENT_SHUTDOWN state,
30 the session will also be removed from the session cache as required by
31 RFC2246.
32
34 SSL_free() does not provide diagnostic information.
35
36 SSL_new(3), SSL_clear(3), SSL_shutdown(3), SSL_set_shutdown(3), ssl(3)
37
38
39
401.0.2o 2018-03-27 SSL_free(3)