#[non_exhaustive]pub enum SdJwtCredentialV2Error {
SdJwt(SdJwtError),
UnexpectedTyp(String),
DisclosedRegisteredClaim(String),
Payload(String),
InvalidClaim {
claim: &'static str,
reason: String,
},
Credential(CredentialError),
}Available on crate feature
sd-jwt only.Expand description
Why an SD-JWT is not a VCDM 2.0 credential secured with SD-JWT.
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.
SdJwt(SdJwtError)
The SD-JWT itself is invalid.
UnexpectedTyp(String)
The typ is present and is not vc+sd-jwt (nor one the caller accepts).
DisclosedRegisteredClaim(String)
A claim that must not be selectively disclosed came from a disclosure.
Payload(String)
The processed payload is not a JWT claims set.
InvalidClaim
cnf or status is not what the claim must hold.
Credential(CredentialError)
The processed payload is not a VCDM 2.0 credential, or its registered claims disagree with it.
Trait Implementations§
Source§impl Debug for SdJwtCredentialV2Error
impl Debug for SdJwtCredentialV2Error
Source§impl Display for SdJwtCredentialV2Error
impl Display for SdJwtCredentialV2Error
Source§impl Error for SdJwtCredentialV2Error
impl Error for SdJwtCredentialV2Error
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 From<CredentialError> for SdJwtCredentialV2Error
impl From<CredentialError> for SdJwtCredentialV2Error
Source§fn from(source: CredentialError) -> Self
fn from(source: CredentialError) -> Self
Converts to this type from the input type.
Source§impl From<SdJwtCredentialV2Error> for SdJwtValidationError
impl From<SdJwtCredentialV2Error> for SdJwtValidationError
Source§fn from(source: SdJwtCredentialV2Error) -> Self
fn from(source: SdJwtCredentialV2Error) -> Self
Converts to this type from the input type.
Source§impl From<SdJwtError> for SdJwtCredentialV2Error
impl From<SdJwtError> for SdJwtCredentialV2Error
Source§fn from(source: SdJwtError) -> Self
fn from(source: SdJwtError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for SdJwtCredentialV2Error
impl !UnwindSafe for SdJwtCredentialV2Error
impl Freeze for SdJwtCredentialV2Error
impl Send for SdJwtCredentialV2Error
impl Sync for SdJwtCredentialV2Error
impl Unpin for SdJwtCredentialV2Error
impl UnsafeUnpin for SdJwtCredentialV2Error
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