pub struct ServerVerifierBuilder { /* private fields */ }Expand description
A server-certificate verifier builder preserving baseline revocation configuration.
Implementations§
Source§impl ServerVerifierBuilder
impl ServerVerifierBuilder
Sourcepub fn with_crls(
self,
crls: impl IntoIterator<Item = CertificateRevocationListDer<'static>>,
) -> Self
pub fn with_crls( self, crls: impl IntoIterator<Item = CertificateRevocationListDer<'static>>, ) -> Self
Appends certificate revocation lists.
Sourcepub fn only_check_end_entity_revocation(self) -> Self
pub fn only_check_end_entity_revocation(self) -> Self
Checks only the leaf’s revocation status.
Sourcepub fn allow_unknown_revocation_status(self) -> Self
pub fn allow_unknown_revocation_status(self) -> Self
Allows unknown revocation status.
Sourcepub fn enforce_revocation_expiration(self) -> Self
pub fn enforce_revocation_expiration(self) -> Self
Enforces CRL expiration.
Sourcepub fn with_peer_identity(self, identity: Arc<dyn PeerIdentity>) -> Self
pub fn with_peer_identity(self, identity: Arc<dyn PeerIdentity>) -> Self
Replaces the server-name check with identity.
identity runs after the path, EKU, revocation and the policy’s peer-certificate rule
pass; the name the client connects with is then not checked. A second call replaces the
first.
The check does not see the server name the client connected with, so a verifier handle, and the client configuration built on it, expect one identity; use one per expected peer.
Sourcepub fn build(self) -> Result<Arc<ServerVerifierHandle>, VerifierBuilderError>
pub fn build(self) -> Result<Arc<ServerVerifierHandle>, VerifierBuilderError>
Builds an owned verifier, refusing empty roots or invalid CRLs.
Trait Implementations§
Source§impl Clone for ServerVerifierBuilder
impl Clone for ServerVerifierBuilder
Auto Trait Implementations§
impl !RefUnwindSafe for ServerVerifierBuilder
impl !UnwindSafe for ServerVerifierBuilder
impl Forget for ServerVerifierBuilder
impl Freeze for ServerVerifierBuilder
impl Move for ServerVerifierBuilder
impl Send for ServerVerifierBuilder
impl Sync for ServerVerifierBuilder
impl Unpin for ServerVerifierBuilder
impl UnsafeUnpin for ServerVerifierBuilder
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