pub struct Request { /* private fields */ }
Expand description

An incoming request to the DNS catalog

Implementations

Build a new requests with the inbound message, source address, and protocol.

This will return an error on bad verification.

Return just the header and request information from the Request Message

The IP address from which the request originated.

The protocol that was used for the request

Methods from Deref<Target = MessageRequest>

Return the request header

see Header::id()

see Header::message_type()

see Header::op_code()

see Header::authoritative()

see Header::truncated()

see Header::recursion_desired()

see Header::recursion_available()

see Header::authentic_data()

see Header::checking_disabled()

Return value

The ResponseCode, if this is an EDNS message then this will join the section from the OPT record to create the EDNS ResponseCode

Question        Carries the query name and other query parameters.
Answer          Carries RRs which directly answer the query.
Authority       Carries RRs which describe other authoritative servers.
                May optionally carry the SOA RR for the authoritative
                data in the answer section.
Additional      Carries RRs which may be helpful in using the RRs in the
                other sections.

RFC 6891, EDNS(0) Extensions, April 2013

6.1.1.  Basic Elements

 An OPT pseudo-RR (sometimes called a meta-RR) MAY be added to the
 additional data section of a request.

 The OPT RR has RR type 41.

 If an OPT record is present in a received request, compliant
 responders MUST include an OPT record in their respective responses.

 An OPT record does not carry any DNS data.  It is used only to
 contain control information pertaining to the question-and-answer
 sequence of a specific transaction.  OPT RRs MUST NOT be cached,
 forwarded, or stored in or loaded from zone files.

 The OPT RR MAY be placed anywhere within the additional data section.
 When an OPT RR is included within any DNS message, it MUST be the
 only OPT RR in that message.  If a query message with more than one
 OPT RR is received, a FORMERR (RCODE=1) MUST be returned.  The
 placement flexibility for the OPT RR does not override the need for
 the TSIG or SIG(0) RRs to be the last in the additional section
 whenever they are present.
Return value

Returns the EDNS record if it was found in the additional section.

Any SIG0 records for signed messages

Return value

the max payload value as it’s defined in the EDNS section.

Return value

the version as defined in the EDNS record

Trait Implementations

Formats the value using the given formatter. Read more

The resulting type after dereferencing.

Dereferences the value.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more