pub fn des3_cbc_encrypt<'py>(
py: Python<'py>,
key: &[u8],
iv: &[u8],
plaintext: &[u8],
pad: bool,
) -> PyResult<Bound<'py, PyBytes>>Expand description
Encrypt data using 3DES-EDE-CBC.
key must be 16 bytes (two-key 3DES) or 24 bytes (three-key 3DES).
iv must be 8 bytes.
When pad=True (default) PKCS#7 padding is applied automatically.
When pad=False the caller is responsible for correct block alignment.
import synta
ct = synta.des3_cbc_encrypt(key_24, iv_8, plaintext)