Ice 3.8
C++ API Reference
Loading...
Searching...
No Matches

◆ sslNewSessionCallback

std::function<void(SSLContextRef context, const std::string& host)> Ice::SSL::SecureTransportClientAuthenticationOptions::sslNewSessionCallback

A callback invoked before initiating a new SSL handshake, providing an opportunity to customize the SSL parameters for the session based on specific client settings or requirements.

Parameters
contextAn opaque type that represents an SSL session context object.
hostThe target host name.

Example of setting sslNewSessionCallback:

auto initData = Ice::InitializationData{
.clientAuthenticationOptions = Ice::SSL::ClientAuthenticationOptions{
.sslNewSessionCallback = [](SSLContextRef context, const std::string&)
{
OSStatus status = SSLSetProtocolVersionMin(context, kTLSProtocol13);
if (status != noErr)
{
// Handle error
}
}}};

Definition at line 132 of file ClientAuthenticationOptions.h.