pub enum PreflightError {
Unreachable(Error),
Rejected(TransportError),
}Expand description
Why a preflight authorization check failed (see
verify_daemon_authorization). The two cases need DIFFERENT
remediation — “start the daemon / check the network” vs “get your key
enrolled” — so they are distinguished at the type level instead of by
string-matching an io::ErrorKind (a dial refusal and a handshake
rejection both involve connection-level I/O and must not be conflated).
Variants§
Unreachable(Error)
The daemon could not be reached at all (dial failure).
Rejected(TransportError)
The daemon was reached but the Noise IK handshake failed: the daemon either does not hold the expected server key, or its ACL did not admit this client’s transport key. (An IK handshake is the ONLY probe that can detect the ACL rejection — the daemon aborts the handshake before message 2 — which is why this preflight runs IK even on a first-contact flow that already probed with XX.)
Trait Implementations§
Source§impl Debug for PreflightError
impl Debug for PreflightError
Source§impl Display for PreflightError
impl Display for PreflightError
Source§impl Error for PreflightError
impl Error for PreflightError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for PreflightError
impl !UnwindSafe for PreflightError
impl Freeze for PreflightError
impl Send for PreflightError
impl Sync for PreflightError
impl Unpin for PreflightError
impl UnsafeUnpin for PreflightError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> ⓘ
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> ⓘ
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 moreimpl<T> JsonSchemaMaybe for T
impl<T> MaybeDebug for Twhere
T: Debug,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
Source§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
unchecked_from.