pub struct WriteEarlyData<'a> { /* private fields */ }std only.Expand description
Allows writing of early data in resumed TLS 1.3 connections.
“Early data” is also known as “0-RTT data”.
This type implements io::Write.
Implementations§
Source§impl<'a> WriteEarlyData<'a>
impl<'a> WriteEarlyData<'a>
Sourcepub fn bytes_left(&self) -> usize
pub fn bytes_left(&self) -> usize
How many bytes you may send. Writes will become short once this reaches zero.
Sourcepub fn exporter(&mut self) -> Result<KeyingMaterialExporter, Error>
pub fn exporter(&mut self) -> Result<KeyingMaterialExporter, Error>
Returns the “early” exporter that can derive key material for use in early data
See RFC5705 for general details on what exporters are, and RFC8446 S7.5 for specific details on the “early” exporter.
Beware that the early exporter requires care, as it is subject to the same potential for replay as early data itself. See RFC8446 appendix E.5.1 for more detail.
This function can be called at most once per connection. This function will error: if called more than once per connection.
If you are looking for the normal exporter, this is available from
ConnectionCommon::exporter().
Trait Implementations§
Source§impl Write for WriteEarlyData<'_>
impl Write for WriteEarlyData<'_>
Source§fn write(&mut self, buf: &[u8]) -> Result<usize>
fn write(&mut self, buf: &[u8]) -> Result<usize>
Source§fn flush(&mut self) -> Result<()>
fn flush(&mut self) -> Result<()>
Source§fn is_write_vectored(&self) -> bool
fn is_write_vectored(&self) -> bool
can_vector)1.0.0 · Source§fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
Source§fn write_all_vectored(&mut self, bufs: &mut [IoSlice<'_>]) -> Result<(), Error>
fn write_all_vectored(&mut self, bufs: &mut [IoSlice<'_>]) -> Result<(), Error>
write_all_vectored)