#include <qsossl.h> int SSL_Destroy(SSLHandle* handle)
The SSL_Destroy() function is used by a program to end SSL support for the specified SSL session. The SSL session to be ended is identified by the handle parameter.
struct SSLHandleStr { /* SSLHandleStr */ int fd; /* Socket descriptor */ int createFlags; /* SSL_Create flags value */ unsigned protocol; /* SSL protocol version */ unsigned timeout; /* Timeout value in seconds */ unsigned char cipherKind[3]; /* Current 2.0 cipher suite*/ unsigned short int cipherSuite; /* Current 3.0 cipher suite */ unsigned short int* cipherSuiteList; /* List of cipher suites */ unsigned int cipherSuiteListLen; /* Number of entries in the cipher suites list */ unsigned char* peerCert; /* Peer certificate */ unsigned peerCertLen; /* Peer certificate length */ int peerCertValidateRc; /* Return code from validation of certficate */ int (*exitPgm)(struct SSLHandleStr* sslh); /* Authentication exit program called when a certificate is received during SSL handshake */ };
No authorization is required.
The SSL_Destroy() API returns an integer. Possible values are:
[0] | Successful return |
[SSL_ERROR_IO] | An error occurred in SSL processing; check the errno value. |
When the SSL_Destroy() API fails with return code [SSL_ERROR_IO], errno can be set to:
Descriptor not valid.
Bad address.
The system detected an address that was not valid while attempting to access the handle parameter or a field within the structure pointed to by the handle parameter.
Input/output error.
Parameter not valid. This error code indicates one of the following:
Requested operation requires a connection.
This error code indicates that the socket_descriptor has not had SSL support enabled. This usually means that an SSL_Create() has not been completed for this socket_descriptor.
The specified descriptor does not reference a socket.
Broken pipe.
A remote host did not respond within the timeout period.
This error code indicates that the SSL_Destroy() was unable to successfully complete the removal of SSL support on this socket_descriptor.
The protocol required to support the specified address family is not available at this time.
Unknown system state.
Message ID | Error Message Text |
---|---|
CPE3418 E | Possible APAR condition or hardware failure. |
CPF9872 E | Program or service program &1 in library &2 ended. Reason code &3. |
CPFA081 E | Unable to set return value or error code. |
Note: A job end might cause a Licensed Internal Code log entry or error log entry if the handle parameter storage is not freed before the job ended.
Top | UNIX-Type APIs | APIs by category |