[][src]Struct quinn::Connecting

pub struct Connecting(_);

In-progress connection attempt future

Be sure to spawn the ConnectionDriver when complete.

Methods

impl Connecting[src]

pub fn into_0rtt(self) -> Result<NewConnection, Self>[src]

Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security. Be sure to spawn the ConnectionDriver.

Opens up the connection for use before the handshake finishes, allowing the API user to send data with 0-RTT encryption if the necessary key material is available. This is useful for reducing start-up latency by beginning transmission of application data without waiting for the handshake's cryptographic security guarantees to be established.

Security

On outgoing connections, this enables transmission of 0-RTT data, which might be vulnerable to replay attacks, and should therefore never invoke non-idempotent operations.

On incoming connections, this enables transmission of 0.5-RTT data, which might be intercepted by a man-in-the-middle. If this occurs, the handshake will not complete successfully.

Once [Connection::is_handshaking] returns false, further transmissions are unaffected by these weaknesses.

Errors

Outgoing connections are only 0-RTT-capable when a cryptographic session ticket cached from a previous connection to the same server is available, and includes a 0-RTT key. If no such ticket is found, self is returned unmodified.

For incoming connections, a 0.5-RTT connection will always be successfully constructed.

Trait Implementations

impl Future for Connecting[src]

type Item = NewConnection

The type of value that this future will resolved with if it is successful. Read more

type Error = ConnectionError

The type of error that this future will resolve with if it fails in a normal fashion. Read more

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized
[src]

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

impl<F> IntoFuture for F where
    F: Future
[src]

type Future = F

The future that this type can be converted into.

type Item = <F as Future>::Item

The item that the future may resolve with.

type Error = <F as Future>::Error

The error that the future may resolve with.

impl<T> Erased for T