Loading openssl-sys/src/handwritten/ssl.rs +4 −0 Original line number Diff line number Diff line Loading @@ -701,6 +701,10 @@ cfg_if! { pub fn TLS_server_method() -> *const SSL_METHOD; pub fn TLS_client_method() -> *const SSL_METHOD; pub fn DTLS_server_method() -> *const SSL_METHOD; pub fn DTLS_client_method() -> *const SSL_METHOD; } } else { extern "C" { Loading openssl/src/ssl/mod.rs +15 −1 Original line number Diff line number Diff line Loading @@ -364,6 +364,20 @@ impl SslMethod { unsafe { SslMethod(TLS_server_method()) } } /// Support all versions of the DTLS protocol, explicitly as a client. #[corresponds(DTLS_client_method)] #[cfg(any(boringssl, ossl110, libressl291))] pub fn dtls_client() -> SslMethod { unsafe { SslMethod(DTLS_client_method()) } } /// Support all versions of the DTLS protocol, explicitly as a server. #[corresponds(DTLS_server_method)] #[cfg(any(boringssl, ossl110, libressl291))] pub fn dtls_server() -> SslMethod { unsafe { SslMethod(DTLS_server_method()) } } /// Constructs an `SslMethod` from a pointer to the underlying OpenSSL value. /// /// # Safety Loading Loading @@ -4288,7 +4302,7 @@ cfg_if! { } cfg_if! { if #[cfg(any(boringssl, ossl110, libressl291))] { use ffi::{TLS_method, DTLS_method, TLS_client_method, TLS_server_method}; use ffi::{TLS_method, DTLS_method, TLS_client_method, TLS_server_method, DTLS_server_method, DTLS_client_method}; } else { use ffi::{ SSLv23_method as TLS_method, DTLSv1_method as DTLS_method, SSLv23_client_method as TLS_client_method, Loading Loading
openssl-sys/src/handwritten/ssl.rs +4 −0 Original line number Diff line number Diff line Loading @@ -701,6 +701,10 @@ cfg_if! { pub fn TLS_server_method() -> *const SSL_METHOD; pub fn TLS_client_method() -> *const SSL_METHOD; pub fn DTLS_server_method() -> *const SSL_METHOD; pub fn DTLS_client_method() -> *const SSL_METHOD; } } else { extern "C" { Loading
openssl/src/ssl/mod.rs +15 −1 Original line number Diff line number Diff line Loading @@ -364,6 +364,20 @@ impl SslMethod { unsafe { SslMethod(TLS_server_method()) } } /// Support all versions of the DTLS protocol, explicitly as a client. #[corresponds(DTLS_client_method)] #[cfg(any(boringssl, ossl110, libressl291))] pub fn dtls_client() -> SslMethod { unsafe { SslMethod(DTLS_client_method()) } } /// Support all versions of the DTLS protocol, explicitly as a server. #[corresponds(DTLS_server_method)] #[cfg(any(boringssl, ossl110, libressl291))] pub fn dtls_server() -> SslMethod { unsafe { SslMethod(DTLS_server_method()) } } /// Constructs an `SslMethod` from a pointer to the underlying OpenSSL value. /// /// # Safety Loading Loading @@ -4288,7 +4302,7 @@ cfg_if! { } cfg_if! { if #[cfg(any(boringssl, ossl110, libressl291))] { use ffi::{TLS_method, DTLS_method, TLS_client_method, TLS_server_method}; use ffi::{TLS_method, DTLS_method, TLS_client_method, TLS_server_method, DTLS_server_method, DTLS_client_method}; } else { use ffi::{ SSLv23_method as TLS_method, DTLSv1_method as DTLS_method, SSLv23_client_method as TLS_client_method, Loading