pub struct SslOption(/* private fields */);
Expand description
A flag that can be used to alter the behavior of SSL/TLS connections.
Most options are for disabling security checks that introduce security risks, but may be required as a last resort.
Implementations§
Source§impl SslOption
impl SslOption
Sourcepub const DANGER_ACCEPT_INVALID_CERTS: Self
pub const DANGER_ACCEPT_INVALID_CERTS: Self
Disables certificate validation.
§Warning
You should think very carefully before using this method. If invalid certificates are trusted, any certificate for any site will be trusted for use. This includes expired certificates. This introduces significant vulnerabilities, and should only be used as a last resort.
Sourcepub const DANGER_ACCEPT_INVALID_HOSTS: Self
pub const DANGER_ACCEPT_INVALID_HOSTS: Self
Disables hostname verification on certificates.
§Warning
You should think very carefully before you use this method. If hostname verification is not used, any valid certificate for any site will be trusted for use from any other. This introduces a significant vulnerability to man-in-the-middle attacks.
Sourcepub const DANGER_ACCEPT_REVOKED_CERTS: Self
pub const DANGER_ACCEPT_REVOKED_CERTS: Self
Disables certificate revocation checks for backends where such behavior is present.
This option is only supported for Schannel (the native Windows SSL library).
Trait Implementations§
Source§impl BitOrAssign for SslOption
impl BitOrAssign for SslOption
Source§fn bitor_assign(&mut self, rhs: Self)
fn bitor_assign(&mut self, rhs: Self)
|=
operation. Read more