Skip to main content

Crate iso_cenc

Crate iso_cenc 

Source
Expand description

Sans-IO ClearKey ISO Common Encryption (sample keystream).

Callers own keys and container parsing. This crate only applies AES under ISO/IEC 23001-7 schemes to byte slices. Policy: workspace ADR-0011.

Stage 1: Scheme::Cenc (AES-128-CTR) with optional subsample ranges.

Structs§

Pattern
Crypt/skip block pattern (tenc / pattern encryption).
Subsample
One subsample: clear bytes then protected bytes (ISO CENC subsample).

Enums§

Error
ClearKey / CENC sample crypto error.
Scheme
Protection scheme (schm.scheme_type).

Functions§

decrypt_cenc
Decrypt a sample in place under Scheme::Cenc.
encrypt_cenc
Encrypt a sample in place under Scheme::Cenc (same CTR keystream as decrypt).
iv_from_8
Build a 16-byte CTR IV from an 8-byte per-sample IV (high 8 = IV, low 8 = 0).
iv_from_constant
Build a 16-byte CTR IV from a constant IV of size 8 or 16.