Expand description
Streaming SM4-CTR cipher (v0.7 W3).
Stateful counterpart to super::mode_ctr’s single-shot
encrypt / decrypt: usable when the plaintext isn’t
available all at once (network framing, file streaming, etc).
See super::mode_ctr’s module docstring for the counter
contract, the no-authenticity caveat, and the BE counter-encoding
semantics — the same rules apply here. CTR is its own inverse, so
Sm4CtrCipher serves both directions; there’s no separate
Sm4CtrEncryptor / Sm4CtrDecryptor split (compare with CBC’s
super::cbc_streaming which needs separate types for the
padding-bookkeeping asymmetry).
Structs§
- Sm4Ctr
Cipher - Streaming SM4-CTR cipher.