SSL_SESSION_get_time 3 2007-03-06 0.9.9-dev OpenSSL

NAME

SSL_SESSION_get_time, SSL_SESSION_set_time, SSL_SESSION_get_timeout, SSL_SESSION_set_timeout - retrieve and manipulate session time and timeout settings

LIBRARY

libcrypto, -lcrypto

SYNOPSIS


 #include 


 long SSL_SESSION_get_time(const SSL_SESSION *s);
 long SSL_SESSION_set_time(SSL_SESSION *s, long tm);
 long SSL_SESSION_get_timeout(const SSL_SESSION *s);
 long SSL_SESSION_set_timeout(SSL_SESSION *s, long tm);





 long SSL_get_time(const SSL_SESSION *s);
 long SSL_set_time(SSL_SESSION *s, long tm);
 long SSL_get_timeout(const SSL_SESSION *s);
 long SSL_set_timeout(SSL_SESSION *s, long tm);

DESCRIPTION

_S_S_L___S_E_S_S_I_O_N___g_e_t___t_i_m_e_(_) returns the time at which the session ss was established. The time is given in seconds since the Epoch and therefore compatible to the time delivered by the _t_i_m_e_(_) call.

_S_S_L___S_E_S_S_I_O_N___s_e_t___t_i_m_e_(_) replaces the creation time of the session ss with the chosen value ttmm.

_S_S_L___S_E_S_S_I_O_N___g_e_t___t_i_m_e_o_u_t_(_) returns the timeout value set for session ss in seconds.

_S_S_L___S_E_S_S_I_O_N___s_e_t___t_i_m_e_o_u_t_(_) sets the timeout value for session ss in seconds to ttmm.

The _S_S_L___g_e_t___t_i_m_e_(_), _S_S_L___s_e_t___t_i_m_e_(_), _S_S_L___g_e_t___t_i_m_e_o_u_t_(_), and _S_S_L___s_e_t___t_i_m_e_o_u_t_(_) functions are synonyms for the SSL_SESSION_*() counterparts.

NOTES

Sessions are expired by examining the creation time and the timeout value. Both are set at creation time of the session to the actual time and the default timeout value at creation, respectively, as set by _S_S_L___C_T_X___s_e_t___t_i_m_e_o_u_t(3). Using these functions it is possible to extend or shorten the lifetime of the session.

RETURN VALUES

_S_S_L___S_E_S_S_I_O_N___g_e_t___t_i_m_e_(_) and _S_S_L___S_E_S_S_I_O_N___g_e_t___t_i_m_e_o_u_t_(_) return the currently valid values.

_S_S_L___S_E_S_S_I_O_N___s_e_t___t_i_m_e_(_) and _S_S_L___S_E_S_S_I_O_N___s_e_t___t_i_m_e_o_u_t_(_) return 1 on success.

If any of the function is passed the NULL pointer for the session ss, 0 is returned.

SEE ALSO

_s_s_l(3), _S_S_L___C_T_X___s_e_t___t_i_m_e_o_u_t(3), _S_S_L___g_e_t___d_e_f_a_u_l_t___t_i_m_e_o_u_t(3)