#[non_exhaustive]pub enum Error {
NoPathFound,
DepthExceeded,
BudgetExceeded,
MalformedIntermediate,
}Expand description
Errors returned by path building.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NoPathFound
No valid path from the target certificate to any trust anchor was found.
DepthExceeded
A topologically valid path exists but requires more intermediates than
the configured maximum (see PathBuilderConfig::max_depth, default
DEFAULT_MAX_DEPTH).
BudgetExceeded
The internal DFS node-visit budget was exhausted in a single round.
This guards against adversarial certificate pools that would otherwise
cause exponential search time. Each iterative-deepening round and the
depth probe start with a fresh budget of DFS_BUDGET node visits.
MalformedIntermediate
A candidate intermediate’s BasicConstraints extension was present but
could not be DER-decoded.
Returning this rather than silently rejecting the candidate avoids the
situation where a malformed-but-topologically-correct intermediate
causes a misleading Error::NoPathFound.
Trait Implementations§
Source§impl Error for Error
Available on crate feature std only.
impl Error for Error
std only.1.30.0 · 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()