#[non_exhaustive]pub enum ProtectionMessageBody<'a> {
AuthenticationMessage {
section_hash_algorithm_identifier: u8,
section_hash_length: u8,
signature_algorithm_identifier: u8,
hashes: Vec<SectionHashEntry<'a>>,
extension_bytes: &'a [u8],
signature_key_identifier: &'a [u8],
signature: &'a [u8],
reserved_section_hashes_loop_length: u8,
},
CertificateCollection {
certificates: Vec<&'a [u8]>,
reserved_certificate_count: u8,
reserved_certificate_lengths: Vec<u8>,
},
Raw(&'a [u8]),
}Expand description
Discriminated protection-message body, selected by table_id_extension.
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.
AuthenticationMessage
Authentication message (extension 0x0000..=0x00FF; §9.4.3 Table 42).
Fields
§
section_hash_algorithm_identifier: u8section_hash_algorithm_identifier (§9.4.3 Table 43): 0 = SHA-256, 1 = SHA-512.
§
hashes: Vec<SectionHashEntry<'a>>Section-hash loop entries in wire order.
CertificateCollection
Certificate collection message (extension 0x0100; §9.5.4.9 Table 51).
Fields
§
certificates: Vec<&'a [u8]>DER-encoded DVBCertificate byte runs, one slice per certificate_length loop entry.
Raw(&'a [u8])
Reserved extension (0x0101..=0xFFFF) — body preserved verbatim.
Implementations§
Source§impl<'a> ProtectionMessageBody<'a>
impl<'a> ProtectionMessageBody<'a>
Sourcepub fn certificate_collection(certificates: Vec<&'a [u8]>) -> Self
pub fn certificate_collection(certificates: Vec<&'a [u8]>) -> Self
A certificate-collection body with the spec reserved fill.
Trait Implementations§
Source§impl<'a> Clone for ProtectionMessageBody<'a>
impl<'a> Clone for ProtectionMessageBody<'a>
Source§impl<'a> Debug for ProtectionMessageBody<'a>
impl<'a> Debug for ProtectionMessageBody<'a>
impl<'a> Eq for ProtectionMessageBody<'a>
Source§impl<'a> PartialEq for ProtectionMessageBody<'a>
impl<'a> PartialEq for ProtectionMessageBody<'a>
Source§impl<'a> Serialize for ProtectionMessageBody<'a>
Available on crate feature serde only.
impl<'a> Serialize for ProtectionMessageBody<'a>
Available on crate feature
serde only.impl<'a> StructuralPartialEq for ProtectionMessageBody<'a>
Auto Trait Implementations§
impl<'a> Freeze for ProtectionMessageBody<'a>
impl<'a> RefUnwindSafe for ProtectionMessageBody<'a>
impl<'a> Send for ProtectionMessageBody<'a>
impl<'a> Sync for ProtectionMessageBody<'a>
impl<'a> Unpin for ProtectionMessageBody<'a>
impl<'a> UnsafeUnpin for ProtectionMessageBody<'a>
impl<'a> UnwindSafe for ProtectionMessageBody<'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