OpenDOF Project
void(* const DOFCipher::Decrypt)(const void *keyState, void *text)

Decrypt a block of data.

This call is used to decrypt a single block of ciphertext (of size blockSize). All required information for the decryption (e.g., key) is contained within the key state.

This call must be thread safe, and should not depend on any non-const global data.

This call must not be NULL. With some security modes of operation, the block cipher is only used for encryption, and the decryption code is never used. If it is known that decryption will never be necessary from this implementation, this function may be left unimplemented. However, it is recommended to always implement decryption. Depending on how the block cipher implementation is used, it may be difficult to determine that it is the lack of decryption that is leading to failure.

Parameters
keyStateThe key state buffer. This must have been initialized by GenerateKeyState. This must not be NULL.
textThe buffer containing the ciphertext block to be decrypted. This buffer will contain the decrypted plaintext after the function returnes (decryption is performed in-place in the buffer). This buffer must be at least blockSize bytes in size. This must not be NULL.
core-c-dof-oal Version 7.1.5 Build 0
2017-01-25