1*10e00d17Sschwarze.\" $OpenBSD: SSL_get_default_timeout.3,v 1.4 2018/03/27 17:35:50 schwarze Exp $ 227ad3400Sschwarze.\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100 3f1a3c524Sschwarze.\" 427ad3400Sschwarze.\" This file was written by Lutz Jaenicke <jaenicke@openssl.org>. 527ad3400Sschwarze.\" Copyright (c) 2001, 2005 The OpenSSL Project. All rights reserved. 6f1a3c524Sschwarze.\" 727ad3400Sschwarze.\" Redistribution and use in source and binary forms, with or without 827ad3400Sschwarze.\" modification, are permitted provided that the following conditions 927ad3400Sschwarze.\" are met: 1027ad3400Sschwarze.\" 1127ad3400Sschwarze.\" 1. Redistributions of source code must retain the above copyright 1227ad3400Sschwarze.\" notice, this list of conditions and the following disclaimer. 1327ad3400Sschwarze.\" 1427ad3400Sschwarze.\" 2. Redistributions in binary form must reproduce the above copyright 1527ad3400Sschwarze.\" notice, this list of conditions and the following disclaimer in 1627ad3400Sschwarze.\" the documentation and/or other materials provided with the 1727ad3400Sschwarze.\" distribution. 1827ad3400Sschwarze.\" 1927ad3400Sschwarze.\" 3. All advertising materials mentioning features or use of this 2027ad3400Sschwarze.\" software must display the following acknowledgment: 2127ad3400Sschwarze.\" "This product includes software developed by the OpenSSL Project 2227ad3400Sschwarze.\" for use in the OpenSSL Toolkit. (http://www.openssl.org/)" 2327ad3400Sschwarze.\" 2427ad3400Sschwarze.\" 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 2527ad3400Sschwarze.\" endorse or promote products derived from this software without 2627ad3400Sschwarze.\" prior written permission. For written permission, please contact 2727ad3400Sschwarze.\" openssl-core@openssl.org. 2827ad3400Sschwarze.\" 2927ad3400Sschwarze.\" 5. Products derived from this software may not be called "OpenSSL" 3027ad3400Sschwarze.\" nor may "OpenSSL" appear in their names without prior written 3127ad3400Sschwarze.\" permission of the OpenSSL Project. 3227ad3400Sschwarze.\" 3327ad3400Sschwarze.\" 6. Redistributions of any form whatsoever must retain the following 3427ad3400Sschwarze.\" acknowledgment: 3527ad3400Sschwarze.\" "This product includes software developed by the OpenSSL Project 3627ad3400Sschwarze.\" for use in the OpenSSL Toolkit (http://www.openssl.org/)" 3727ad3400Sschwarze.\" 3827ad3400Sschwarze.\" THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 3927ad3400Sschwarze.\" EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 4027ad3400Sschwarze.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 4127ad3400Sschwarze.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 4227ad3400Sschwarze.\" ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 4327ad3400Sschwarze.\" SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 4427ad3400Sschwarze.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 4527ad3400Sschwarze.\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 4627ad3400Sschwarze.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 4727ad3400Sschwarze.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 4827ad3400Sschwarze.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 4927ad3400Sschwarze.\" OF THE POSSIBILITY OF SUCH DAMAGE. 5027ad3400Sschwarze.\" 51*10e00d17Sschwarze.Dd $Mdocdate: March 27 2018 $ 52f1a3c524Sschwarze.Dt SSL_GET_DEFAULT_TIMEOUT 3 53f1a3c524Sschwarze.Os 54f1a3c524Sschwarze.Sh NAME 55f1a3c524Sschwarze.Nm SSL_get_default_timeout 56f1a3c524Sschwarze.Nd get default session timeout value 57f1a3c524Sschwarze.Sh SYNOPSIS 58f1a3c524Sschwarze.In openssl/ssl.h 59f1a3c524Sschwarze.Ft long 60f1a3c524Sschwarze.Fn SSL_get_default_timeout "const SSL *ssl" 61f1a3c524Sschwarze.Sh DESCRIPTION 62f1a3c524Sschwarze.Fn SSL_get_default_timeout 63f1a3c524Sschwarzereturns the default timeout value assigned to 64f1a3c524Sschwarze.Vt SSL_SESSION 65f1a3c524Sschwarzeobjects negotiated for the protocol valid for 66f1a3c524Sschwarze.Fa ssl . 6727ad3400Sschwarze.Pp 68f1a3c524SschwarzeWhenever a new session is negotiated, it is assigned a timeout value, 69f1a3c524Sschwarzeafter which it will not be accepted for session reuse. 70f1a3c524SschwarzeIf the timeout value was not explicitly set using 71f1a3c524Sschwarze.Xr SSL_CTX_set_timeout 3 , 72f1a3c524Sschwarzethe hardcoded default timeout for the protocol will be used. 73f1a3c524Sschwarze.Pp 74f1a3c524Sschwarze.Fn SSL_get_default_timeout 75f1a3c524Sschwarzereturn this hardcoded value, which is 300 seconds for all currently supported 76f1a3c524Sschwarzeprotocols (SSLv2, SSLv3, and TLSv1). 77f1a3c524Sschwarze.Sh SEE ALSO 78f1a3c524Sschwarze.Xr ssl 3 , 79f1a3c524Sschwarze.Xr SSL_CTX_flush_sessions 3 , 80f1a3c524Sschwarze.Xr SSL_CTX_set_session_cache_mode 3 , 81f1a3c524Sschwarze.Xr SSL_SESSION_get_time 3 828fba1ec8Sschwarze.Sh HISTORY 838fba1ec8Sschwarze.Fn SSL_get_default_timeout 84*10e00d17Sschwarzefirst appeared in SSLeay 0.8.0 and has been available since 858fba1ec8Sschwarze.Ox 2.4 . 86