#[non_exhaustive]pub enum DnMatchError {
CertDnMismatch {
expected_dn: String,
},
NameMismatch {
expected_name: String,
},
}Expand description
Outcome of a DN / name check, kept distinct so the driver can surface the reference’s two distinct errors (ERR_INVALID_SERVER_CERT_DN vs ERR_INVALID_SERVER_NAME).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
CertDnMismatch
ssl_server_cert_dn was supplied but did not equal the server’s
subject DN (reference ERR_INVALID_SERVER_CERT_DN).
NameMismatch
No ssl_server_cert_dn; the host matched neither a SAN DNS name nor a
common name (reference ERR_INVALID_SERVER_NAME).
Trait Implementations§
Source§impl Clone for DnMatchError
impl Clone for DnMatchError
Source§fn clone(&self) -> DnMatchError
fn clone(&self) -> DnMatchError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 DnMatchError
impl Debug for DnMatchError
Source§impl Display for DnMatchError
impl Display for DnMatchError
impl Eq for DnMatchError
Source§impl Error for DnMatchError
impl Error for DnMatchError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for DnMatchError
impl PartialEq for DnMatchError
Source§fn eq(&self, other: &DnMatchError) -> bool
fn eq(&self, other: &DnMatchError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for DnMatchError
Auto Trait Implementations§
impl Freeze for DnMatchError
impl RefUnwindSafe for DnMatchError
impl Send for DnMatchError
impl Sync for DnMatchError
impl Unpin for DnMatchError
impl UnsafeUnpin for DnMatchError
impl UnwindSafe for DnMatchError
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