Struct tonic::transport::server::ServerTlsConfig
source · pub struct ServerTlsConfig { /* private fields */ }
Available on crate features
tls
and transport
only.Expand description
Configures TLS settings for servers.
Implementations§
source§impl ServerTlsConfig
impl ServerTlsConfig
sourcepub fn client_ca_root(self, cert: Certificate) -> Self
pub fn client_ca_root(self, cert: Certificate) -> Self
Sets a certificate against which to validate client TLS certificates.
sourcepub fn client_auth_optional(self, optional: bool) -> Self
pub fn client_auth_optional(self, optional: bool) -> Self
Sets whether client certificate verification is optional.
This option has effect only if CA certificate is set.
§Default
By default, this option is set to false
.
Trait Implementations§
source§impl Clone for ServerTlsConfig
impl Clone for ServerTlsConfig
source§fn clone(&self) -> ServerTlsConfig
fn clone(&self) -> ServerTlsConfig
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ServerTlsConfig
impl Debug for ServerTlsConfig
source§impl Default for ServerTlsConfig
impl Default for ServerTlsConfig
source§fn default() -> ServerTlsConfig
fn default() -> ServerTlsConfig
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for ServerTlsConfig
impl Send for ServerTlsConfig
impl Sync for ServerTlsConfig
impl Unpin for ServerTlsConfig
impl UnwindSafe for ServerTlsConfig
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request