Boost C++ Libraries of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
ssl::stream::handshake (2 of 2 overloads)

Perform SSL handshaking.

boost::system::error_code handshake(
    handshake_type type,
    boost::system::error_code & ec);

This function is used to perform SSL handshaking on the stream. The function call will block until handshaking is complete or an error occurs.



The type of handshaking to be performed, i.e. as a client or as a server.


Set to indicate what error occurred, if any.