SSL_get_ex_data_X509_STORE_CTX_idx 3 2001-04-11 0.9.9-dev OpenSSL
NAME
SSL_get_ex_data_X509_STORE_CTX_idx - get ex_data index to access SSL structure
from X509_STORE_CTX
LIBRARY
libcrypto, -lcrypto
SYNOPSIS
#include
int SSL_get_ex_data_X509_STORE_CTX_idx(void);
DESCRIPTION
_S_S_L___g_e_t___e_x___d_a_t_a___X_5_0_9___S_T_O_R_E___C_T_X___i_d_x_(_) returns the index number under which
the pointer to the SSL object is stored into the X509_STORE_CTX object.
NOTES
Whenever a X509_STORE_CTX object is created for the verification of the
peers certificate during a handshake, a pointer to the SSL object is
stored into the X509_STORE_CTX object to identify the connection affected.
To retrieve this pointer the _X_5_0_9___S_T_O_R_E___C_T_X___g_e_t___e_x___d_a_t_a_(_) function can
be used with the correct index. This index is globally the same for all
X509_STORE_CTX objects and can be retrieved using
_S_S_L___g_e_t___e_x___d_a_t_a___X_5_0_9___S_T_O_R_E___C_T_X___i_d_x_(_). The index value is set when
_S_S_L___g_e_t___e_x___d_a_t_a___X_5_0_9___S_T_O_R_E___C_T_X___i_d_x_(_) is first called either by the application
program directly or indirectly during other SSL setup functions or during
the handshake.
The value depends on other index values defined for X509_STORE_CTX objects
before the SSL index is created.
RETURN VALUES
-
>=0
The index value to access the pointer.
-
-
<0
An error occurred, check the error stack for a detailed error message.
-
EXAMPLES
The index returned from _S_S_L___g_e_t___e_x___d_a_t_a___X_5_0_9___S_T_O_R_E___C_T_X___i_d_x_(_) allows to
access the SSL object for the connection to be accessed during the
_v_e_r_i_f_y___c_a_l_l_b_a_c_k_(_) when checking the peers certificate. Please check
the example in _S_S_L___C_T_X___s_e_t___v_e_r_i_f_y(3),
SEE ALSO
_s_s_l(3), _S_S_L___C_T_X___s_e_t___v_e_r_i_f_y(3),
_C_R_Y_P_T_O___s_e_t___e_x___d_a_t_a(3)