Sortix
Sortix Download Manual Development Source Code News Blog More
current nightly

Sortix cross-nightly manual

This manual documents Sortix cross-nightly. You can instead view this document in the latest official manual.

NAME

SSL_SESSION_get0_cipher — retrieve the SSL cipher associated with a session

SYNOPSIS

#include <openssl/ssl.h>
const SSL_CIPHER *
SSL_SESSION_get0_cipher(const SSL_SESSION *session);

DESCRIPTION

SSL_SESSION_get0_cipher() retrieves the cipher that was used by the connection when the session was created, or NULL if it cannot be determined.
The value returned is a pointer to an object maintained within session and should not be released.

RETURN VALUES

SSL_SESSION_get0_cipher() returns the SSL_CIPHER associated with session or NULL if it cannot be determined.

SEE ALSO

ssl(3), SSL_CIPHER_get_name(3), SSL_get_current_cipher(3), SSL_get_session(3), SSL_SESSION_new(3)

HISTORY

The SSL_SESSION_get0_cipher() function first appeared in OpenSSL 1.1.0 and has been available since OpenBSD 7.0.
Copyright 2011-2025 Jonas 'Sortie' Termansen and contributors.
Sortix's source code is free software under the ISC license.
#sortix on irc.sortix.org
@sortix_org