#[non_exhaustive]#[repr(u32)]pub enum FrameType {
Show 14 variants
ServerChallenge = 0,
ClientAuth = 1,
ServerConfirmsAuth = 2,
ServerDeniesAuth = 3,
ClientToRelayDatagram = 4,
ClientToRelayDatagramBatch = 5,
RelayToClientDatagram = 6,
RelayToClientDatagramBatch = 7,
EndpointGone = 8,
Ping = 9,
Pong = 10,
Health = 11,
Restarting = 12,
Status = 13,
}Expand description
Possible frame types during handshaking
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
ServerChallenge = 0
The server frame type for the challenge response
ClientAuth = 1
The client frame type for the authentication frame
ServerConfirmsAuth = 2
The server frame type for authentication confirmation
ServerDeniesAuth = 3
The server frame type for authentication denial
ClientToRelayDatagram = 4
32B dest pub key + ECN bytes + one datagram’s content
ClientToRelayDatagramBatch = 5
32B dest pub key + ECN byte + segment size u16 + datagrams contents
RelayToClientDatagram = 6
32B src pub key + ECN bytes + one datagram’s content
RelayToClientDatagramBatch = 7
32B src pub key + ECN byte + segment size u16 + datagrams contents
EndpointGone = 8
Sent from server to client to signal that a previous sender is no longer connected.
That is, if A sent to B, and then if A disconnects, the server sends FrameType::PeerGone
to B so B can forget that a reverse path exists on that connection to get back to A
32B pub key of peer that’s gone
Ping = 9
8 byte ping payload, to be echoed back in a FrameType::Pong.
Pong = 10
8 byte payload, the contents of ping being replied to
Health = 11
REMOVED since relay-protocol-v2, use Self::Status instead.
Sent from server to client to tell the client if their connection is unhealthy somehow. Contains only UTF-8 bytes.
Restarting = 12
Sent from server to client for the server to declare that it’s restarting. Payload is two big endian u32 durations in milliseconds: when to reconnect, and how long to try total.
Status = 13
Sent from server to client to declare the connection health state.
Added in iroh-relay-v2 protocol. May not be sent to iroh-relay-v1 clients.
Uses a binary-encoded Status payload.
Implementations§
Trait Implementations§
impl Copy for FrameType
impl Eq for FrameType
impl StructuralPartialEq for FrameType
Auto Trait Implementations§
impl Freeze for FrameType
impl RefUnwindSafe for FrameType
impl Send for FrameType
impl Sync for FrameType
impl Unpin for FrameType
impl UnwindSafe for FrameType
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more