pub unsafe extern "C" fn ocrypto_aes_cbc_pkcs_update(
    ctx: *mut ocrypto_aes_cbc_pkcs_ctx,
    out: *mut u8,
    in_: *const u8,
    in_len: usize
)
Expand description

AES-CBC incremental encryption/decryption.

The input * in - is encrypted or decrypted to the output * out - using the context * ctx - .

This function can be called repeatedly until the whole message is processed.

  • ctx - Context.
  • out - Output, ciphertext for encryption, plaintext for decryption.
  • in - Input, plaintext for encryption, ciphertext for decryption.
  • in_len - Length of * in - .

@remark * in - may be same as * out - . @remark A single common buffer may be used for the whole plaintext and ciphertext if * in - and * out - of the first call are equal and incremented individually by the input and output size for each further call (meaning the plaintext and ciphertext are stored contiguously in the common buffer). @remark Initialization of the context * ctx - through * ocrypto_aes_ctr_init - is required before this function can be called. @remark The maximum length of * out - is * in_len - + 15. @remark The exact length of * out - is returned by * ocrypto_aes_cbc_pkcs_output_size - .