Trait tide_rustls::CustomTlsAcceptor [−][src]
The CustomTlsAcceptor trait provides a custom implementation of accepting
TLS connections from a TcpStream
. tide-rustls will call the
CustomTlsAcceptor::accept
function for each new TcpStream
it
accepts, to obtain a TlsStream
).
Implementing this trait gives you control over the TLS negotiation process, and allows you to process some TLS connections internally without passing them through to tide, such as for multiplexing or custom ALPN negotiation.
Required methods
#[must_use]fn accept<'life0, 'async_trait>(
&'life0 self,
stream: TcpStream
) -> Pin<Box<dyn Future<Output = Result<Option<TlsStream<TcpStream>>>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
stream: TcpStream
) -> Pin<Box<dyn Future<Output = Result<Option<TlsStream<TcpStream>>>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,