libressl-SSL_SESSION_get_protocol_version(3)

libressl-SSL_SESSION_get_protocol_version3

Get the session protocol version

Usage

SSL Library (libssl, -lssl) libcrypto

#include <openssl/ssl.h>

int

SSL_SESSION_get_protocol_version(const SSL_SESSION *s);

Overview

SSL_SESSION_get_protocol_version() returns the protocol version number used by the session s.

Return values

SSL_SESSION_get_protocol_version() returns a constant like TLS1_VERSION or TLS1_2_VERSION.

History

SSL_SESSION_get_protocol_version() first appeared in OpenSSL 1.1.0 and has been available since OpenBSD 6.3.

From libressl 4.4.0-1 in Arch Linux 2026-11-01. Parsed by carta from the page's mdoc source.