lllv_core/errors.rs
1//! Error type for LLLV capsule parsing, crypto, and serialization helpers.
2use thiserror::Error;
3
4#[derive(Error, Debug)]
5pub enum LllvError {
6 #[error("invalid header length")]
7 InvalidHeaderLen,
8 #[error("invalid magic")]
9 InvalidMagic,
10 #[error("invalid version")]
11 InvalidVersion,
12 #[error("mismatched_lengths")]
13 MismatchedLengths,
14 #[error("signature verification failed")]
15 BadSignature,
16 #[error("crypto error")]
17 Crypto,
18 #[error("timestamp overflow")]
19 TimestampOverflow,
20 #[error("serde error: {0}")]
21 Serde(String),
22}