module Block: sig endBlock module provides classes that implements
popular block ciphers, chaining modes, and wrapping of a block cipher
as a general transform or as a hash function.
The classes can be composed in a Lego-like fashion, facilitating
the integration of new block ciphers, modes, etc.class type block_cipher = object end
Deriving transforms and hashes from block ciphers
|
class cipher : block_cipher -> Cryptokit.transformclass cipher_padded_encrypt : Cryptokit.Padding.scheme ->
block_cipher -> Cryptokit.transformCryptokit.Block.cipher, but performs padding on the input data
as specified by the first argument.
class cipher_padded_decrypt : Cryptokit.Padding.scheme ->
block_cipher -> Cryptokit.transformCryptokit.Block.cipher, but removes padding on the output data
as specified by the first argument.
class mac : ?iv:string ->
?pad:Cryptokit.Padding.scheme ->
block_cipher -> Cryptokit.hashclass mac_final_triple : ?iv:string ->
?pad:Cryptokit.Padding.scheme ->
block_cipher ->
block_cipher ->
block_cipher -> Cryptokit.hashc1, c2 and c3.
Some block ciphers: AES, DES, triple DES
|
class aes_encrypt : string -> block_cipherclass aes_decrypt : string -> block_cipherclass des_encrypt : string -> block_cipherclass des_decrypt : string -> block_cipherclass triple_des_encrypt : string -> block_cipherclass triple_des_decrypt : string -> block_cipher
Chaining modes
|
class cbc_encrypt : ?iv:string -> block_cipher -> block_cipherclass cbc_decrypt : ?iv:string -> block_cipher -> block_cipherclass cfb_encrypt : ?iv:string ->
int -> block_cipher -> block_cipherclass cfb_decrypt : ?iv:string ->
int -> block_cipher -> block_cipherclass ofb : ?iv:string ->
int -> block_cipher -> block_cipher