pub struct TlsClientAuthenticationService<T> { /* private fields */ }Expand description
A service adapter which validates a client’s certificate against a collection of allowed subject names.
Requests will be rejected if the client did not provide a certificate or if the certificate does not have an allowed subject name.
Implementations§
Source§impl<T> TlsClientAuthenticationService<T>
impl<T> TlsClientAuthenticationService<T>
Sourcepub fn new(
inner: T,
trusted_subject_names: Arc<Refreshable<HashSet<String>, Error>>,
) -> Self
pub fn new( inner: T, trusted_subject_names: Arc<Refreshable<HashSet<String>, Error>>, ) -> Self
Creates a new service which will validate the subject name of a client’s certificate for each request.
The inner service can implement either the Service or AsyncService trait.
Trait Implementations§
Source§impl<T, I, O> AsyncService<I, O> for TlsClientAuthenticationService<T>where
T: AsyncService<I, O>,
I: 'static + Send,
O: 'static,
impl<T, I, O> AsyncService<I, O> for TlsClientAuthenticationService<T>where
T: AsyncService<I, O>,
I: 'static + Send,
O: 'static,
Source§fn endpoints(
&self,
runtime: &Arc<ConjureRuntime>,
) -> Vec<BoxAsyncEndpoint<'static, I, O>>
fn endpoints( &self, runtime: &Arc<ConjureRuntime>, ) -> Vec<BoxAsyncEndpoint<'static, I, O>>
Returns the endpoints in the service.
Auto Trait Implementations§
impl<T> Freeze for TlsClientAuthenticationService<T>where
T: Freeze,
impl<T> !RefUnwindSafe for TlsClientAuthenticationService<T>
impl<T> Send for TlsClientAuthenticationService<T>where
T: Send,
impl<T> Sync for TlsClientAuthenticationService<T>where
T: Sync,
impl<T> Unpin for TlsClientAuthenticationService<T>where
T: Unpin,
impl<T> !UnwindSafe for TlsClientAuthenticationService<T>
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
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