light_openid/
errors.rs

1#[derive(thiserror::Error, Debug)]
2pub enum OpenIdError {
3    #[error("Reqwest error: {0}")]
4    Reqwest(#[from] reqwest::Error),
5    #[error("Serde json error: {0}")]
6    SerdeJson(#[from] serde_json::Error),
7    #[error("Base64 decoding error: {0}")]
8    Base64Decode(#[from] base64::DecodeError),
9    #[cfg(feature = "crypto-wrapper")]
10    #[error("State error: invalid IP")]
11    StateErrorInvalidIP,
12    #[cfg(feature = "crypto-wrapper")]
13    #[error("State error: expired")]
14    StateErrorExpired,
15    #[cfg(feature = "crypto-wrapper")]
16    #[error("Rkyv error: {0}")]
17    RkyvError(#[from] rkyv::rancor::Error),
18    #[cfg(feature = "crypto-wrapper")]
19    #[error("Input string is smaller than nonce!")]
20    DecInputStringSmallerThanNonce,
21    #[cfg(feature = "crypto-wrapper")]
22    #[error("Failed to decrypt wrapped data!")]
23    DecryptWrappedData,
24}