1 2 #ifndef EL__NETWORK_SSL_SSL_H 3 #define EL__NETWORK_SSL_SSL_H 4 5 #ifdef CONFIG_SSL 6 7 #include "main/module.h" 8 9 struct socket; 10 11 extern struct module ssl_module; 12 13 /* Initializes the SSL connection data. Returns S_OK on success and S_SSL_ERROR 14 * on failure. */ 15 int init_ssl_connection(struct socket *socket); 16 17 /* Releases the SSL connection data */ 18 void done_ssl_connection(struct socket *socket); 19 20 unsigned char *get_ssl_connection_cipher(struct socket *socket); 21 22 23 /* Internal type used in ssl module. */ 24 25 #ifdef CONFIG_OPENSSL 26 #define ssl_t SSL 27 #elif defined(CONFIG_GNUTLS) 28 #define ssl_t gnutls_session_t 29 #endif 30 31 #endif /* CONFIG_SSL */ 32 #endif 33