-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Generic cryptography cipher tests -- -- Generic cryptography cipher tests @package crypto-cipher-tests @version 0.0.1 module Crypto.Cipher.Tests -- | Return tests for a specific blockcipher and a list of KATs testBlockCipher :: BlockCipher a => KATs -> a -> Test defaultKATs :: KATs data KATs KATs :: [KAT_ECB] -> [KAT_CBC] -> [KAT_CTR] -> [KAT_XTS] -> [KAT_AEAD] -> KATs kat_ECB :: KATs -> [KAT_ECB] kat_CBC :: KATs -> [KAT_CBC] kat_CTR :: KATs -> [KAT_CTR] kat_XTS :: KATs -> [KAT_XTS] kat_AEAD :: KATs -> [KAT_AEAD] -- | ECB KAT data KAT_ECB KAT_ECB :: ByteString -> ByteString -> ByteString -> KAT_ECB ecbKey :: KAT_ECB -> ByteString ecbPlaintext :: KAT_ECB -> ByteString ecbCiphertext :: KAT_ECB -> ByteString -- | CBC KAT data KAT_CBC KAT_CBC :: ByteString -> ByteString -> ByteString -> ByteString -> KAT_CBC cbcKey :: KAT_CBC -> ByteString cbcIV :: KAT_CBC -> ByteString cbcPlaintext :: KAT_CBC -> ByteString cbcCiphertext :: KAT_CBC -> ByteString -- | CTR KAT data KAT_CTR KAT_CTR :: ByteString -> ByteString -> ByteString -> ByteString -> KAT_CTR ctrKey :: KAT_CTR -> ByteString ctrIV :: KAT_CTR -> ByteString ctrPlaintext :: KAT_CTR -> ByteString ctrCiphertext :: KAT_CTR -> ByteString -- | XTS KAT data KAT_XTS KAT_XTS :: ByteString -> ByteString -> ByteString -> ByteString -> ByteString -> KAT_XTS xtsKey1 :: KAT_XTS -> ByteString xtsKey2 :: KAT_XTS -> ByteString xtsIV :: KAT_XTS -> ByteString xtsPlaintext :: KAT_XTS -> ByteString xtsCiphertext :: KAT_XTS -> ByteString -- | AEAD KAT data KAT_AEAD KAT_AEAD :: AEADMode -> ByteString -> ByteString -> ByteString -> ByteString -> ByteString -> Int -> AuthTag -> KAT_AEAD -- | AEAD mode to use aeadMode :: KAT_AEAD -> AEADMode -- | Key aeadKey :: KAT_AEAD -> ByteString -- | IV for initialization aeadIV :: KAT_AEAD -> ByteString -- | Authentificated Header aeadHeader :: KAT_AEAD -> ByteString -- | Plaintext aeadPlaintext :: KAT_AEAD -> ByteString -- | Ciphertext aeadCiphertext :: KAT_AEAD -> ByteString -- | aead tag len aeadTaglen :: KAT_AEAD -> Int -- | expected tag aeadTag :: KAT_AEAD -> AuthTag