Enum trust_dns_proto::rr::rdata::svcb::SvcParamKey
source · [−]pub enum SvcParamKey {
Mandatory,
Alpn,
NoDefaultAlpn,
Port,
Ipv4Hint,
EchConfig,
Ipv6Hint,
Key(u16),
Key65535,
Unknown(u16),
}
Expand description
14.3.2. Initial contents
The "Service Binding (SVCB) Parameter Registry" shall initially be
populated with the registrations below:
+=============+=================+======================+===========+
| Number | Name | Meaning | Reference |
+=============+=================+======================+===========+
| 0 | mandatory | Mandatory keys in | (This |
| | | this RR | document) |
+-------------+-----------------+----------------------+-----------+
| 1 | alpn | Additional supported | (This |
| | | protocols | document) |
+-------------+-----------------+----------------------+-----------+
| 2 | no-default-alpn | No support for | (This |
| | | default protocol | document) |
+-------------+-----------------+----------------------+-----------+
| 3 | port | Port for alternative | (This |
| | | endpoint | document) |
+-------------+-----------------+----------------------+-----------+
| 4 | ipv4hint | IPv4 address hints | (This |
| | | | document) |
+-------------+-----------------+----------------------+-----------+
| 5 | echconfig | Encrypted | (This |
| | | ClientHello info | document) |
+-------------+-----------------+----------------------+-----------+
| 6 | ipv6hint | IPv6 address hints | (This |
| | | | document) |
+-------------+-----------------+----------------------+-----------+
| 65280-65534 | keyNNNNN | Private Use | (This |
| | | | document) |
+-------------+-----------------+----------------------+-----------+
| 65535 | key65535 | Reserved ("Invalid | (This |
| | | key") | document) |
+-------------+-----------------+----------------------+-----------+
parsing done via:
* a 2 octet field containing the SvcParamKey as an integer in
network byte order. (See Section 14.3.2 for the defined values.)
Variants
Mandatory
Mandatory keys in this RR
Alpn
Additional supported protocols
NoDefaultAlpn
No support for default protocol
Port
Port for alternative endpoint
Ipv4Hint
IPv4 address hints
EchConfig
Encrypted ClientHello info
Ipv6Hint
IPv6 address hints
Key(u16)
Private Use
Key65535
Reserved (“Invalid key”)
Unknown(u16)
Unknown
Trait Implementations
sourceimpl<'r> BinDecodable<'r> for SvcParamKey
impl<'r> BinDecodable<'r> for SvcParamKey
sourcefn read(decoder: &mut BinDecoder<'r>) -> ProtoResult<Self>
fn read(decoder: &mut BinDecoder<'r>) -> ProtoResult<Self>
Read the type from the stream
sourcefn from_bytes(bytes: &'r [u8]) -> ProtoResult<Self>
fn from_bytes(bytes: &'r [u8]) -> ProtoResult<Self>
Returns the object in binary form
sourceimpl BinEncodable for SvcParamKey
impl BinEncodable for SvcParamKey
sourcefn emit(&self, encoder: &mut BinEncoder<'_>) -> ProtoResult<()>
fn emit(&self, encoder: &mut BinEncoder<'_>) -> ProtoResult<()>
Write the type to the stream
sourcefn to_bytes(&self) -> ProtoResult<Vec<u8>>
fn to_bytes(&self) -> ProtoResult<Vec<u8>>
Returns the object in binary form
sourceimpl Clone for SvcParamKey
impl Clone for SvcParamKey
sourcefn clone(&self) -> SvcParamKey
fn clone(&self) -> SvcParamKey
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for SvcParamKey
impl Debug for SvcParamKey
sourceimpl Display for SvcParamKey
impl Display for SvcParamKey
sourceimpl From<SvcParamKey> for u16
impl From<SvcParamKey> for u16
sourcefn from(val: SvcParamKey) -> Self
fn from(val: SvcParamKey) -> Self
Performs the conversion.
sourceimpl FromStr for SvcParamKey
impl FromStr for SvcParamKey
sourceimpl Hash for SvcParamKey
impl Hash for SvcParamKey
sourceimpl Ord for SvcParamKey
impl Ord for SvcParamKey
sourceimpl PartialEq<SvcParamKey> for SvcParamKey
impl PartialEq<SvcParamKey> for SvcParamKey
sourcefn eq(&self, other: &SvcParamKey) -> bool
fn eq(&self, other: &SvcParamKey) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &SvcParamKey) -> bool
fn ne(&self, other: &SvcParamKey) -> bool
This method tests for !=
.
sourceimpl PartialOrd<SvcParamKey> for SvcParamKey
impl PartialOrd<SvcParamKey> for SvcParamKey
sourcefn partial_cmp(&self, other: &Self) -> Option<Ordering>
fn partial_cmp(&self, other: &Self) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Copy for SvcParamKey
impl Eq for SvcParamKey
impl StructuralEq for SvcParamKey
impl StructuralPartialEq for SvcParamKey
Auto Trait Implementations
impl RefUnwindSafe for SvcParamKey
impl Send for SvcParamKey
impl Sync for SvcParamKey
impl Unpin for SvcParamKey
impl UnwindSafe for SvcParamKey
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more