Struct rsa::pss::Signature

source ·
pub struct Signature { /* private fields */ }
Expand description

RSASSA-PSS signatures as described in RFC8017 § 8.1.

Trait Implementations§

source§

impl Clone for Signature

source§

fn clone(&self) -> Signature

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Signature

source§

fn fmt(&self, fmt: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<D> DigestVerifier<D, Signature> for VerifyingKey<D>where D: Digest + FixedOutputReset,

source§

fn verify_digest(&self, digest: D, signature: &Signature) -> Result<()>

Verify the signature against the given Digest output.
source§

impl Display for Signature

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Signature> for Box<[u8]>

source§

fn from(signature: Signature) -> Box<[u8]>

Converts to this type from the input type.
source§

impl LowerHex for Signature

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter.
source§

impl PartialEq for Signature

source§

fn eq(&self, other: &Signature) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<D> PrehashVerifier<Signature> for VerifyingKey<D>where D: Digest + FixedOutputReset,

source§

fn verify_prehash(&self, prehash: &[u8], signature: &Signature) -> Result<()>

Use Self to verify that the provided signature for a given message prehash is authentic. Read more
source§

impl<D> RandomizedDigestSigner<D, Signature> for BlindedSigningKey<D>where D: Digest + FixedOutputReset,

source§

fn try_sign_digest_with_rng( &self, rng: &mut impl CryptoRngCore, digest: D ) -> Result<Signature>

Attempt to sign the given prehashed message Digest, returning a digital signature on success, or an error if something went wrong.
source§

fn sign_digest_with_rng(&self, rng: &mut impl CryptoRngCore, digest: D) -> S

Sign the given prehashed message Digest, returning a signature. Read more
source§

impl<D> RandomizedDigestSigner<D, Signature> for SigningKey<D>where D: Digest + FixedOutputReset,

source§

fn try_sign_digest_with_rng( &self, rng: &mut impl CryptoRngCore, digest: D ) -> Result<Signature>

Attempt to sign the given prehashed message Digest, returning a digital signature on success, or an error if something went wrong.
source§

fn sign_digest_with_rng(&self, rng: &mut impl CryptoRngCore, digest: D) -> S

Sign the given prehashed message Digest, returning a signature. Read more
source§

impl<D> RandomizedPrehashSigner<Signature> for BlindedSigningKey<D>where D: Digest + FixedOutputReset,

source§

fn sign_prehash_with_rng( &self, rng: &mut impl CryptoRngCore, prehash: &[u8] ) -> Result<Signature>

Attempt to sign the given message digest, returning a digital signature on success, or an error if something went wrong. Read more
source§

impl<D> RandomizedPrehashSigner<Signature> for SigningKey<D>where D: Digest + FixedOutputReset,

source§

fn sign_prehash_with_rng( &self, rng: &mut impl CryptoRngCore, prehash: &[u8] ) -> Result<Signature>

Attempt to sign the given message digest, returning a digital signature on success, or an error if something went wrong. Read more
source§

impl<D> RandomizedSigner<Signature> for BlindedSigningKey<D>where D: Digest + FixedOutputReset,

source§

fn try_sign_with_rng( &self, rng: &mut impl CryptoRngCore, msg: &[u8] ) -> Result<Signature>

Attempt to sign the given message, returning a digital signature on success, or an error if something went wrong. Read more
source§

fn sign_with_rng(&self, rng: &mut impl CryptoRngCore, msg: &[u8]) -> S

Sign the given message and return a digital signature
source§

impl<D> RandomizedSigner<Signature> for SigningKey<D>where D: Digest + FixedOutputReset,

source§

fn try_sign_with_rng( &self, rng: &mut impl CryptoRngCore, msg: &[u8] ) -> Result<Signature>

Attempt to sign the given message, returning a digital signature on success, or an error if something went wrong. Read more
source§

fn sign_with_rng(&self, rng: &mut impl CryptoRngCore, msg: &[u8]) -> S

Sign the given message and return a digital signature
source§

impl SignatureBitStringEncoding for Signature

source§

fn to_bitstring(&self) -> DerResult<BitString>

BitString encoding for this signature.
source§

impl SignatureEncoding for Signature

§

type Repr = Box<[u8]>

Byte representation of a signature.
source§

fn to_bytes(&self) -> Self::Repr

Encode signature as its byte representation.
source§

fn to_vec(&self) -> Vec<u8>

Available on crate feature alloc only.
Encode signature as a byte vector.
source§

fn encoded_len(&self) -> usize

Get the length of this signature when encoded.
source§

impl TryFrom<&[u8]> for Signature

§

type Error = Error

The type returned in the event of a conversion error.
source§

fn try_from(bytes: &[u8]) -> Result<Self>

Performs the conversion.
source§

impl UpperHex for Signature

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter.
source§

impl<D> Verifier<Signature> for VerifyingKey<D>where D: Digest + FixedOutputReset,

source§

fn verify(&self, msg: &[u8], signature: &Signature) -> Result<()>

Use Self to verify that the provided signature for a given message bytestring is authentic. Read more
source§

impl Eq for Signature

source§

impl StructuralEq for Signature

source§

impl StructuralPartialEq for Signature

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToString for Twhere T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V