#[non_exhaustive]pub enum Extension<'a> {
BasicConstraints(BasicConstraints),
KeyUsage(KeyUsage),
ExtendedKeyUsage(Vec<KeyPurposeId, MAX_KEY_PURPOSES>),
SubjectKeyId([u8; 20]),
AuthorityKeyId([u8; 20]),
Future(&'a [u8]),
}Available on crate feature
rustcrypto only.Expand description
One entry of a certificate’s extensions list (§6.5.11).
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.
BasicConstraints(BasicConstraints)
basic-cnstr [1].
KeyUsage(KeyUsage)
key-usage [2].
ExtendedKeyUsage(Vec<KeyPurposeId, MAX_KEY_PURPOSES>)
extended-key-usage [3], in the order it appeared.
SubjectKeyId([u8; 20])
subject-key-id [4] — the SHA-1 of the subject public key (§6.5.11.4).
AuthorityKeyId([u8; 20])
authority-key-id [5] — the SHA-1 of the key that signed this certificate.
Future(&'a [u8])
future-extension [6], kept verbatim.
An implementation that does not understand one still needs its bytes: they are part of the DER the signature was computed over. “If ignored extension is marked as critical then validation of the corresponding Matter certificate SHALL fail” — which is a decision for the DER layer, since criticality is not encoded here.
Implementations§
Trait Implementations§
impl<'a> Eq for Extension<'a>
impl<'a> StructuralPartialEq for Extension<'a>
Auto Trait Implementations§
impl<'a> Forget for Extension<'a>
impl<'a> Freeze for Extension<'a>
impl<'a> Move for Extension<'a>
impl<'a> RefUnwindSafe for Extension<'a>
impl<'a> Send for Extension<'a>
impl<'a> Sync for Extension<'a>
impl<'a> Unpin for Extension<'a>
impl<'a> UnsafeUnpin for Extension<'a>
impl<'a> UnwindSafe for Extension<'a>
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