SSL_GET_DEFAULT_TIMEOUT(3ossl)
π SSL_GET_DEFAULT_TIMEOUT(3ossl) β bestie edition
okay so this is the 3ossl manual page, and it's literally about one (1) function that tells you how long a session gets to live before the universe says "nope, expired." it's short, it's sweet, it's giving "small but mighty." let's get into it π
β¨ NAME β¨
SSL_get_default_timeout β get the default session timeout value, no cap π
πΈ SYNOPSIS πΈ
#include <openssl/ssl.h>
long SSL_get_default_timeout(const SSL *ssl);
that's it. that's the whole vibe. one include, one function, zero drama π
π¦ DESCRIPTION π¦
so SSL_get_default_timeout() returns the default timeout value that gets assigned to SSL_SESSION objects β you know, the sessions negotiated for whatever protocol is valid for ssl. it's like the built-in "you have this long before i stop recognizing you" timer β³
literally just hands you back the default number. iconic behavior, honestly.
π NOTES π
okay here's the tea π΅ every time a new session gets negotiated, it gets assigned a timeout value. once that timer runs out, that session will not be accepted for session reuse anymore. bye bestie, it's over π
and if the timeout value wasn't explicitly set using SSL_CTX_set_timeout(3)? then the hardcoded default timeout for the protocol is what you get. no custom settings, no problem β the baked-in number steps in π₯
and what is that hardcoded value, you ask? SSL_get_default_timeout() returns it, and it's 300 seconds for all currently supported protocols. three hundred. five minutes. that's the whole number. periodt β
π«Ά RETURN VALUES π«Ά
see description. yeah, that's the whole section β it said what it said and it's not elaborating π (it returns the default timeout value, bestie.)
π SEE ALSO π
ssl(7)SSL_CTX_set_session_cache_mode(3)SSL_SESSION_get_time(3)SSL_CTX_flush_sessions(3)SSL_get_default_timeout(3)
go read those if you want the full lore iykyk πβ¨
π COPYRIGHT π
Copyright 2001-2016 The OpenSSL Project Authors. All Rights Reserved.
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.
fr fr read the license before you do anything spicy with this, okay? π«Ά
and that's a wrap, bestie π§ this page was brought to you by OpenSSL 3.5.6, dated 2026-04-07, filed under SSL_GET_DEFAULT_TIMEOUT(3ossl) β go forth and set those timeouts responsibly ππ
π¦ where this page comes from
- freebsd 15.1: base 15.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms