pub struct Http01Validator { /* private fields */ }Expand description
Fetches the challenge file and compares it to the key authorization.
Implementations§
Source§impl Http01Validator
impl Http01Validator
Sourcepub fn from_config(cfg: &Http01Config, outbound: Outbound) -> Result<Self>
pub fn from_config(cfg: &Http01Config, outbound: Outbound) -> Result<Self>
Builds the validator with a real HTTP client, resolving its connect
target through resolver — the same one challenge::from_config
selected for dns-01 (dns.resolver if set, else the system
configuration), so a deployment overriding it gets one consistent
answer for every challenge type rather than dns-01 alone.
Sourcepub fn with_fetcher(cfg: &Http01Config, fetcher: Arc<dyn HttpFetcher>) -> Self
pub fn with_fetcher(cfg: &Http01Config, fetcher: Arc<dyn HttpFetcher>) -> Self
Same, against a caller-supplied fetcher. Used by tests.
Trait Implementations§
Source§impl ChallengeValidator for Http01Validator
impl ChallengeValidator for Http01Validator
Source§fn validate<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ctx: &'life1 ValidationContext<'life2>,
) -> Pin<Box<dyn Future<Output = Result<(), ChallengeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn validate<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
ctx: &'life1 ValidationContext<'life2>,
) -> Pin<Box<dyn Future<Output = Result<(), ChallengeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Proves the client controls
ctx.identifier. Ok(()) is a pass.Auto Trait Implementations§
impl !RefUnwindSafe for Http01Validator
impl !UnwindSafe for Http01Validator
impl Freeze for Http01Validator
impl Send for Http01Validator
impl Sync for Http01Validator
impl Unpin for Http01Validator
impl UnsafeUnpin for Http01Validator
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
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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> ⓘ
Converts
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> ⓘ
Converts
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