pub struct TlsManager { /* private fields */ }
Expand description
TLS configuration and certificate management
Implementations§
Source§impl TlsManager
impl TlsManager
pub fn new(config: TlsConfig) -> Result<Self>
Sourcepub async fn create_rustls_config(&self) -> Result<RustlsConfig>
pub async fn create_rustls_config(&self) -> Result<RustlsConfig>
Create Rustls config for Axum server
Sourcepub fn is_enabled(&self) -> bool
pub fn is_enabled(&self) -> bool
Check if TLS is enabled
Sourcepub fn requires_client_cert(&self) -> bool
pub fn requires_client_cert(&self) -> bool
Check if mTLS (mutual TLS) is required
Sourcepub fn supports_mtls(&self) -> bool
pub fn supports_mtls(&self) -> bool
Check if this configuration supports mTLS
Sourcepub fn get_cert_info(&self) -> TlsCertInfo
pub fn get_cert_info(&self) -> TlsCertInfo
Get certificate information (for monitoring/diagnostics)
Sourcepub fn validate_certificates(&self) -> Result<()>
pub fn validate_certificates(&self) -> Result<()>
Validate that certificates exist and are readable
Auto Trait Implementations§
impl Freeze for TlsManager
impl RefUnwindSafe for TlsManager
impl Send for TlsManager
impl Sync for TlsManager
impl Unpin for TlsManager
impl UnwindSafe for TlsManager
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