pub enum HandshakeErrorKind {
BadVersionId,
NonZeroedTimeInPacket1,
IncorrectPeerTime,
IncorrectRandomData,
HandshakeAlreadyCompleted,
UnknownPacket1Format,
InvalidP2Packet,
Io(Error),
}
Enumeration that represents the various errors that can occur during the handshaking process
The RTMP specification requires the first byte in the handshake process to start with a
3, so this error is encountered if any other value is in the first byte.
The RTMP specification requires the 2nd set of 4 bytes to all be zeroes, so this error
is encountered if any of those values are not zeros.
This is encountered when the peer did not send the same timestamp in packet #2 that we
sent them in our packet #1.
IncorrectRandomData
This is encountered when the peer did not send back the same random data in their packet
number 2 that we sent them in our packet number 1.
HandshakeAlreadyCompleted
This is encountered if we try to keep progressing on a handshake handler that has already
completed a successful handshake.
The packet 1 we receive may be one of two formats (digest at position 8 or 772). There
is no known way to know which one to expect, so both are tested for. This error is returned
when packet 1 does not match either of the messages (and most likely is a bad handshake).
This occurs when the incoming p2 did not either contain an exact copy of the p1 we sent
(old handshake) or the hmac signature did not match (digest handshake).
This occurs when an IO error is encountered while reading the input.
Formats the value using the given formatter. Read more
Formats the value using the given formatter. Read more
Returns a reference to the underlying cause of this failure, if it is an error that wraps other errors. Read more
Returns a reference to the Backtrace
carried by this failure, if it carries one. Read more
fn context<D>(self, context: D) -> Context<D> where D: Display + Send + Sync + 'static, | [src] |
Wraps this failure in a compatibility wrapper that implements std::error::Error
. Read more
Converts the given value to a String
. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Converts a reference to Self
into a dynamic trait object of Fail
.
Returns a reference to the underlying cause of this failure, if it is an error that wraps other errors. Read more
Returns a reference to the Backtrace
carried by this failure, if it carries one. Read more
fn context<D>(self, context: D) -> Context<D> where D: Display + Send + Sync + 'static, | [src] |
Wraps this failure in a compatibility wrapper that implements std::error::Error
. Read more