#[non_exhaustive]pub struct LinkedVpValidationOptions {
pub time: TimeOptions,
pub credentials: CredentialValidationOptions,
pub subject_holder: SubjectHolderRelationship,
pub fail_fast: FailFast,
}linked-vp only.Expand description
Options of LinkedVpValidator. The audience and nonce are fixed: a linked presentation
has neither.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.time: TimeOptionsThe validation time and leeway of the presentation JWT; exp is honoured when present
and not required.
credentials: CredentialValidationOptionsThe options every credential is validated with. CREDENTIAL_TYP is accepted on top
of their additional_typ.
subject_holder: SubjectHolderRelationshipHow credential subjects must relate to the holder;
SubjectHolderRelationship::AlwaysSubject by default, as the specification
recommends.
fail_fast: FailFastWhether to stop at the first failing credential.
Implementations§
Source§impl LinkedVpValidationOptions
impl LinkedVpValidationOptions
Sourcepub fn new() -> Self
pub fn new() -> Self
Default options: validate now without leeway, default credential options,
SubjectHolderRelationship::AlwaysSubject, FailFast::FirstError.
Sourcepub fn with_time(self, time: TimeOptions) -> Self
pub fn with_time(self, time: TimeOptions) -> Self
These options with time, for the presentation JWT only.
Sourcepub fn with_credentials(self, credentials: CredentialValidationOptions) -> Self
pub fn with_credentials(self, credentials: CredentialValidationOptions) -> Self
These options validating credentials with credentials.
Sourcepub fn with_subject_holder(
self,
relationship: SubjectHolderRelationship,
) -> Self
pub fn with_subject_holder( self, relationship: SubjectHolderRelationship, ) -> Self
These options with relationship.
Sourcepub fn with_fail_fast(self, fail_fast: FailFast) -> Self
pub fn with_fail_fast(self, fail_fast: FailFast) -> Self
These options with fail_fast.
Sourcepub fn presentation_options(&self) -> PresentationValidationOptions
pub fn presentation_options(&self) -> PresentationValidationOptions
The options of the underlying JwtPresentationValidator: no audience, no nonce, and
PRESENTATION_TYP and CREDENTIAL_TYP accepted.
Trait Implementations§
Source§impl Clone for LinkedVpValidationOptions
impl Clone for LinkedVpValidationOptions
Source§impl Debug for LinkedVpValidationOptions
impl Debug for LinkedVpValidationOptions
Source§impl Default for LinkedVpValidationOptions
impl Default for LinkedVpValidationOptions
impl Eq for LinkedVpValidationOptions
impl StructuralPartialEq for LinkedVpValidationOptions
Auto Trait Implementations§
impl Freeze for LinkedVpValidationOptions
impl RefUnwindSafe for LinkedVpValidationOptions
impl Send for LinkedVpValidationOptions
impl Sync for LinkedVpValidationOptions
impl Unpin for LinkedVpValidationOptions
impl UnsafeUnpin for LinkedVpValidationOptions
impl UnwindSafe for LinkedVpValidationOptions
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.