Struct coset::CoseKey [−][src]
pub struct CoseKey { pub kty: RegisteredLabel<KeyType>, pub key_id: Vec<u8>, pub alg: Option<Algorithm>, pub key_ops: BTreeSet<RegisteredLabel<KeyOperation>>, pub base_iv: Vec<u8>, pub params: BTreeMap<Label, Value>, }
Expand description
Structure representing a cryptographic key.
COSE_Key = {
1 => tstr / int, ; kty
? 2 => bstr, ; kid
? 3 => tstr / int, ; alg
? 4 => [+ (tstr / int) ], ; key_ops
? 5 => bstr, ; Base IV
* label => values
}
Fields
kty: RegisteredLabel<KeyType>
Expand description
Key type identification.
key_id: Vec<u8>
Expand description
Key identification.
alg: Option<Algorithm>
Expand description
Key use restriction to this algorithm.
key_ops: BTreeSet<RegisteredLabel<KeyOperation>>
Expand description
Restrict set of possible operations.
base_iv: Vec<u8>
Expand description
Base IV to be xor-ed with partial IVs.
params: BTreeMap<Label, Value>
Expand description
Any additional parameter values.
Trait Implementations
impl CborSerializable for CoseKey
[src]
impl CborSerializable for CoseKey
[src]fn from_reader<R: Read>(reader: R) -> Result<Self>
[src]
fn from_reader<R: Read>(reader: R) -> Result<Self>
[src]Create an object instance by reading serialized CBOR data from std::io::Read
instance.
impl<'de> Deserialize<'de> for CoseKey
[src]
impl<'de> Deserialize<'de> for CoseKey
[src]fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
[src]
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
[src]Deserialize this value from the given Serde deserializer. Read more
impl Eq for CoseKey
[src]
impl StructuralEq for CoseKey
[src]
impl StructuralPartialEq for CoseKey
[src]
Auto Trait Implementations
impl RefUnwindSafe for CoseKey
impl Send for CoseKey
impl Sync for CoseKey
impl Unpin for CoseKey
impl UnwindSafe for CoseKey
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,