Skip to main content

starttls

Function starttls 

Source
async fn starttls(tcp: TcpStream) -> Result<TcpStream, SyncError>
Expand description

Upgrades a plain connection before anything else is said (RFC 9051 §6.2.1): the greeting, STARTTLS, its OK. Read a byte at a time, so nothing meant for TLS is swallowed.