Enum drawbridge::jose::jwk::Key
source · #[non_exhaustive]pub enum Key {
EllipticCurve {
crv: EllipticCurveType,
d: Option<Bytes<Zeroizing<Vec<u8>>, UrlSafeNoPad>>,
x: Bytes<Vec<u8>, UrlSafeNoPad>,
y: Bytes<Vec<u8>, UrlSafeNoPad>,
},
Rsa {
n: Bytes<Vec<u8>, UrlSafeNoPad>,
e: Bytes<Vec<u8>, UrlSafeNoPad>,
prv: Option<RsaPrivate>,
},
Octets {
k: Bytes<Zeroizing<Vec<u8>>, UrlSafeNoPad>,
},
OctetKeyPair {
crv: OctetKeyPairType,
d: Option<Bytes<Zeroizing<Vec<u8>>, UrlSafeNoPad>>,
x: Bytes<Vec<u8>, UrlSafeNoPad>,
},
}
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.
EllipticCurve
Rsa
Octets
OctetKeyPair
Trait Implementations§
source§impl<'de> Deserialize<'de> for Key
impl<'de> Deserialize<'de> for Key
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<Key, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<Key, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Serialize for Key
impl Serialize for Key
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Eq for Key
impl StructuralPartialEq for Key
Auto Trait Implementations§
impl Freeze for Key
impl RefUnwindSafe for Key
impl Send for Key
impl Sync for Key
impl Unpin for Key
impl UnwindSafe for Key
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