SSL_CTX_set_keylog_callback

Configure a callback that logs TLS key material for debugging (e.g. Wireshark).

Synopsis

Declared in <openssl/ssl.h>

void
SSL_CTX_set_keylog_callback(
    SSL_CTX* ctx,
    SSL_CTX_keylog_cb_func cb);

Parameters

NameDescription
ctxSSL context whose connections invoke cb when keys are generated or received.
cbCallback that should write line followed by a newline, or NULL to disable logging.