Function SocketNegotiateSSL() Professional

Upgrade a socket connection to an SSL connection.

Syntax
SocketNegotiateSSL( <nSocket> ) --> lSuccess
Parameters
<nSocket>
A numeric socket descriptor identifying a connected socket.
Return

The logical value true (.T.) when the SSL negotiation is successful, otherwise false (.F.) is returned.

Description

The function SocketNegotiateSSL() is used for negotiating the Secure Socket Layer (SSL) protocol for the connection represented by a specified socket descriptor. SocketNegotiateSSL() needs to be called right after the TCP/IP connection is established as follows:

- Server: Right after accepting a client connection via SocketAccept()

- Client: Right after connecting to the server via SocketConnect()

Note that <nSocket> needs to be a TCP stream socket. SSL connections for UDP datagram sockets are not supported.

Prior to calling SocketNegotiateSSL(), a SSL certificate must be selected for the current thread via CertificateSelect().

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.