Enum mas_oidc_client::jose::jwa::AsymmetricVerifyingKey
#[non_exhaustive]pub enum AsymmetricVerifyingKey {
Rs256(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha256VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, OidSha256>>>),
Rs384(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B0>, B0>, B0>, B0>, OidSha384>>>),
Rs512(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>, OidSha512>>>),
Ps256(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha256VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, OidSha256>>>),
Ps384(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B0>, B0>, B0>, B0>, OidSha384>>>),
Ps512(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>, OidSha512>>>),
Es256(VerifyingKey<NistP256>),
Es384(VerifyingKey<NistP384>),
Es256K(VerifyingKey<Secp256k1>),
}
Expand description
An enum of all supported asymmetric signature algorithms signing keys
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Rs256(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha256VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, OidSha256>>>)
Rs384(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B0>, B0>, B0>, B0>, OidSha384>>>)
Rs512(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>, OidSha512>>>)
Ps256(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha256VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, OidSha256>>>)
Ps384(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B1>, B0>, B0>, B0>, B0>, OidSha384>>>)
Ps512(VerifyingKey<CoreWrapper<CtVariableCoreWrapper<Sha512VarCore, UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>, OidSha512>>>)
Es256(VerifyingKey<NistP256>)
Es384(VerifyingKey<NistP384>)
Es256K(VerifyingKey<Secp256k1>)
Implementations§
§impl AsymmetricVerifyingKey
impl AsymmetricVerifyingKey
pub fn rs256(key: RsaPublicKey) -> AsymmetricVerifyingKey
pub fn rs256(key: RsaPublicKey) -> AsymmetricVerifyingKey
Create a new verifying key with the RS256 algorithm from the given RSA public key.
pub fn rs384(key: RsaPublicKey) -> AsymmetricVerifyingKey
pub fn rs384(key: RsaPublicKey) -> AsymmetricVerifyingKey
Create a new verifying key with the RS384 algorithm from the given RSA public key.
pub fn rs512(key: RsaPublicKey) -> AsymmetricVerifyingKey
pub fn rs512(key: RsaPublicKey) -> AsymmetricVerifyingKey
Create a new verifying key with the RS512 algorithm from the given RSA public key.
pub fn ps256(key: RsaPublicKey) -> AsymmetricVerifyingKey
pub fn ps256(key: RsaPublicKey) -> AsymmetricVerifyingKey
Create a new verifying key with the PS256 algorithm from the given RSA public key.
pub fn ps384(key: RsaPublicKey) -> AsymmetricVerifyingKey
pub fn ps384(key: RsaPublicKey) -> AsymmetricVerifyingKey
Create a new verifying key with the PS384 algorithm from the given RSA public key.
pub fn ps512(key: RsaPublicKey) -> AsymmetricVerifyingKey
pub fn ps512(key: RsaPublicKey) -> AsymmetricVerifyingKey
Create a new verifying key with the PS512 algorithm from the given RSA public key.
pub fn es256(key: PublicKey<NistP256>) -> AsymmetricVerifyingKey
pub fn es256(key: PublicKey<NistP256>) -> AsymmetricVerifyingKey
Create a new verifying key with the ES256 algorithm from the given ECDSA public key.
pub fn es384(key: PublicKey<NistP384>) -> AsymmetricVerifyingKey
pub fn es384(key: PublicKey<NistP384>) -> AsymmetricVerifyingKey
Create a new verifying key with the ES384 algorithm from the given ECDSA public key.
pub fn es256k(key: PublicKey<Secp256k1>) -> AsymmetricVerifyingKey
pub fn es256k(key: PublicKey<Secp256k1>) -> AsymmetricVerifyingKey
Create a new verifying key with the ES256K algorithm from the given ECDSA public key.
pub fn from_jwk_and_alg(
params: &JsonWebKeyPublicParameters,
alg: &JsonWebSignatureAlg,
) -> Result<AsymmetricVerifyingKey, AsymmetricKeyFromJwkError>
pub fn from_jwk_and_alg( params: &JsonWebKeyPublicParameters, alg: &JsonWebSignatureAlg, ) -> Result<AsymmetricVerifyingKey, AsymmetricKeyFromJwkError>
Create a new verifying key for the given algorithm from the given public JWK parameters.
§Errors
Returns an error if the key parameters are not suitable for the given algorithm.
Trait Implementations§
§impl From<VerifyingKey<NistP256>> for AsymmetricVerifyingKey
impl From<VerifyingKey<NistP256>> for AsymmetricVerifyingKey
§fn from(key: VerifyingKey<NistP256>) -> AsymmetricVerifyingKey
fn from(key: VerifyingKey<NistP256>) -> AsymmetricVerifyingKey
§impl From<VerifyingKey<NistP384>> for AsymmetricVerifyingKey
impl From<VerifyingKey<NistP384>> for AsymmetricVerifyingKey
§fn from(key: VerifyingKey<NistP384>) -> AsymmetricVerifyingKey
fn from(key: VerifyingKey<NistP384>) -> AsymmetricVerifyingKey
§impl From<VerifyingKey<Secp256k1>> for AsymmetricVerifyingKey
impl From<VerifyingKey<Secp256k1>> for AsymmetricVerifyingKey
§fn from(key: VerifyingKey<Secp256k1>) -> AsymmetricVerifyingKey
fn from(key: VerifyingKey<Secp256k1>) -> AsymmetricVerifyingKey
Auto Trait Implementations§
impl Freeze for AsymmetricVerifyingKey
impl RefUnwindSafe for AsymmetricVerifyingKey
impl Send for AsymmetricVerifyingKey
impl Sync for AsymmetricVerifyingKey
impl Unpin for AsymmetricVerifyingKey
impl UnwindSafe for AsymmetricVerifyingKey
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> FutureExt for T
impl<T> FutureExt for T
source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§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