pub struct ScannerConfigBuilder { /* private fields */ }Expand description
Builder for ScannerConfig.
Implementations§
Source§impl ScannerConfigBuilder
impl ScannerConfigBuilder
Sourcepub fn validate_cert_chain<VALUE: Into<bool>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn validate_cert_chain<VALUE: Into<bool>>( &mut self, value: VALUE, ) -> &mut Self
Set whether the certificate chain should be validated by the scanner
This is generally not necessary inside a browser, as the chain has already been validated by the browser, but e.g. it might make sense when fetching the chain from a file system.
Sourcepub fn sth_freshness_threshold<VALUE: Into<Duration>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn sth_freshness_threshold<VALUE: Into<Duration>>( &mut self, value: VALUE, ) -> &mut Self
A STH that is younger than this time is considered fresh an STH that is older mature
The policy evaluation requires a fresh STH to show that the log is still active If the STH against which the inclusion proof has been made is mature, it will not require additional STH validations
Sourcepub fn sth_update_threshold<VALUE: Into<Duration>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn sth_update_threshold<VALUE: Into<Duration>>( &mut self, value: VALUE, ) -> &mut Self
If the logs newest STH is older than this time, it will attempt to fetch a fresher value
This value must not be larger than sth_freshness_theshold
Sourcepub fn build(&self) -> Result<ScannerConfig, ScannerConfigBuilderError>
pub fn build(&self) -> Result<ScannerConfig, ScannerConfigBuilderError>
Trait Implementations§
Source§impl Clone for ScannerConfigBuilder
impl Clone for ScannerConfigBuilder
Source§fn clone(&self) -> ScannerConfigBuilder
fn clone(&self) -> ScannerConfigBuilder
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ScannerConfigBuilder
impl RefUnwindSafe for ScannerConfigBuilder
impl Send for ScannerConfigBuilder
impl Sync for ScannerConfigBuilder
impl Unpin for ScannerConfigBuilder
impl UnsafeUnpin for ScannerConfigBuilder
impl UnwindSafe for ScannerConfigBuilder
Blanket Implementations§
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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