Enum RsaPssSaltLength
#[non_exhaustive]pub enum RsaPssSaltLength {
Digest,
Max,
Custom(u16),
}aws-lc and crypto and std only.Expand description
An RSA-PSS padding salt length.
If a non-default value is used for a signature, then a matching verification should also use the same value, otherwise it will fail.
Using this type with PSS is FIPS-approved only when the salt length equals
the digest length, i.e. either when Self::Digest or Self::Custom is
used, and the latter with that digest length given. Self::Max or any
other value passed into Self::Custom will not be FIPS-approved.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Digest
The salt length is set to the length of the used digest algorithm.
Corresponds to [RSA_PSS_SALTLEN_DIGEST]. This is the default.
Max
The salt length is set to the maximum possible length with respect to the used digest algorithm and public key.
This corresponds to emLen - hLen - 2, where
emLenis(pub_key_size_bits + 6) / 8, so depends on the mod size;hLenis the digest algorithm’s output length;
A verification of a signature produced using this salt length may only work when also using this maximum length, not any length up to it.
Custom(u16)
The salt length is set to the given custom value.
The passed value is not particularly checked here, so may ultimately result in failures.
Trait Implementations§
§impl Clone for RsaPssSaltLength
impl Clone for RsaPssSaltLength
§fn clone(&self) -> RsaPssSaltLength
fn clone(&self) -> RsaPssSaltLength
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for RsaPssSaltLength
§impl Debug for RsaPssSaltLength
impl Debug for RsaPssSaltLength
§impl Default for RsaPssSaltLength
impl Default for RsaPssSaltLength
§fn default() -> RsaPssSaltLength
fn default() -> RsaPssSaltLength
impl Eq for RsaPssSaltLength
§impl PartialEq for RsaPssSaltLength
impl PartialEq for RsaPssSaltLength
impl StructuralPartialEq for RsaPssSaltLength
Auto Trait Implementations§
impl Forget for RsaPssSaltLength
impl Freeze for RsaPssSaltLength
impl RefUnwindSafe for RsaPssSaltLength
impl Send for RsaPssSaltLength
impl Sync for RsaPssSaltLength
impl Unpin for RsaPssSaltLength
impl UnsafeUnpin for RsaPssSaltLength
impl UnwindSafe for RsaPssSaltLength
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a rama_grpc::Request§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§fn and<P, B, E>(self, other: P) -> And<T, P>
fn and<P, B, E>(self, other: P) -> And<T, P>
Policy that returns Action::Follow only if self and other return
Action::Follow. Read more