[][src]Struct trust_dns_proto::rr::rdata::tlsa::TLSA

pub struct TLSA { /* fields omitted */ }

RFC 6698, DNS-Based Authentication for TLS

2.1.  TLSA RDATA Wire Format

   The RDATA for a TLSA RR consists of a one-octet certificate usage
   field, a one-octet selector field, a one-octet matching type field,
   and the certificate association data field.

                        1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |  Cert. Usage  |   Selector    | Matching Type |               /
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+               /
   /                                                               /
   /                 Certificate Association Data                  /
   /                                                               /
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Methods

impl TLSA[src]

pub fn new(
    cert_usage: CertUsage,
    selector: Selector,
    matching: Matching,
    cert_data: Vec<u8>
) -> Self
[src]

Constructs a new TLSA

RFC 6698, DNS-Based Authentication for TLS

2.  The TLSA Resource Record

   The TLSA DNS resource record (RR) is used to associate a TLS server
   certificate or public key with the domain name where the record is
   found, thus forming a "TLSA certificate association".  The semantics
   of how the TLSA RR is interpreted are given later in this document.

   The type value for the TLSA RR type is defined in Section 7.1.

   The TLSA RR is class independent.

   The TLSA RR has no special Time to Live (TTL) requirements.

pub fn cert_usage(&self) -> &CertUsage[src]

Specifies the provided association that will be used to match the certificate presented in the TLS handshake

pub fn selector(&self) -> &Selector[src]

Specifies which part of the TLS certificate presented by the server will be matched against the association data

pub fn matching(&self) -> &Matching[src]

Specifies how the certificate association is presented

pub fn cert_data(&self) -> &[u8][src]

Binary data for validating the cert, see other members to understand format

Trait Implementations

impl PartialEq<TLSA> for TLSA[src]

impl Clone for TLSA[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Eq for TLSA[src]

impl Debug for TLSA[src]

impl Hash for TLSA[src]

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0[src]

Feeds a slice of this type into the given [Hasher]. Read more

Auto Trait Implementations

impl Send for TLSA

impl Sync for TLSA

Blanket Implementations

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<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> Erased for T