pub struct Config { /* private fields */ }Available on crate feature
rustls and (crate features native-tls or rustls) only.Expand description
rustls’s config.
Implementations§
Source§impl Config
impl Config
Sourcepub fn client_auth_optional(self, trust_anchor: impl Into<Vec<u8>>) -> Self
pub fn client_auth_optional(self, trust_anchor: impl Into<Vec<u8>>) -> Self
Sets the trust anchor for optional Tls client authentication
Sourcepub fn client_auth_required(self, trust_anchor: impl Into<Vec<u8>>) -> Self
pub fn client_auth_required(self, trust_anchor: impl Into<Vec<u8>>) -> Self
Sets the trust anchor for required Tls client authentication
Sourcepub fn ocsp_resp(self, ocsp_resp: impl Into<Vec<u8>>) -> Self
pub fn ocsp_resp(self, ocsp_resp: impl Into<Vec<u8>>) -> Self
sets the DER-encoded OCSP response
Sourcepub fn build(self) -> Result<ServerConfig>
pub fn build(self) -> Result<ServerConfig>
builds the Tls ServerConfig
§Errors
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnsafeUnpin for Config
impl UnwindSafe for Config
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