#[non_exhaustive]pub enum WireGuardKind {
HandshakeInitiation,
HandshakeResponse,
CookieReply,
TransportData,
}Available on crate feature
wireguard only.Expand description
WireGuard message-type vocabulary per Donenfeld 2017 (the WireGuard whitepaper) §5.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
HandshakeInitiation
Type 1 — initiator’s Noise IK initiation. 148 bytes.
HandshakeResponse
Type 2 — responder’s reply. 92 bytes.
CookieReply
Type 3 — DoS-mitigation cookie reply. 64 bytes.
TransportData
Type 4 — encrypted application data. 16 + N bytes.
Implementations§
Source§impl WireGuardKind
impl WireGuardKind
Trait Implementations§
Source§impl Clone for WireGuardKind
impl Clone for WireGuardKind
impl Copy for WireGuardKind
Source§impl Debug for WireGuardKind
impl Debug for WireGuardKind
Source§impl<'de> Deserialize<'de> for WireGuardKind
Available on crate feature serde only.
impl<'de> Deserialize<'de> for WireGuardKind
Available on crate feature
serde only.Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for WireGuardKind
Source§impl Hash for WireGuardKind
impl Hash for WireGuardKind
Source§impl PartialEq for WireGuardKind
impl PartialEq for WireGuardKind
Source§impl Serialize for WireGuardKind
Available on crate feature serde only.
impl Serialize for WireGuardKind
Available on crate feature
serde only.impl StructuralPartialEq for WireGuardKind
Auto Trait Implementations§
impl Freeze for WireGuardKind
impl RefUnwindSafe for WireGuardKind
impl Send for WireGuardKind
impl Sync for WireGuardKind
impl Unpin for WireGuardKind
impl UnsafeUnpin for WireGuardKind
impl UnwindSafe for WireGuardKind
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§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
Mutably borrows from an owned value. Read more