SSL_psk_use_session_cb_func

TLSv1.3 client callback that selects a PSK session to offer.

Synopsis

Declared in <openssl/ssl.h>

typedef int(* SSL_psk_use_session_cb_func)(SSL*, EVP_MD const*, unsigned char const**, size_t*, SSL_SESSION**);

Return Value

1 on success, or 0 to abort the handshake.

Parameters

NameDescription
sslClient SSL connection establishing a PSK.
mdHandshake digest required by the server on a second call, or NULL on the first call.
idOn success, set to the application-owned PSK identity bytes.
idlenReceives the length of id in bytes.
sessOn success, set to an SSL_SESSION transferring ownership to OpenSSL.