cryptocipher-0.2: Symmetrical Block and Stream CiphersContentsIndex
Crypto.Cipher.RC4
PortabilityGood
Stabilityexperimental
MaintainerVincent Hanquez <vincent@snarc.org>
Description
Synopsis
type Ctx = (Vector Word8, Word8, Word8)
initCtx :: [Word8] -> Ctx
encrypt :: Ctx -> ByteString -> (Ctx, ByteString)
decrypt :: Ctx -> ByteString -> (Ctx, ByteString)
encryptlazy :: Ctx -> ByteString -> (Ctx, ByteString)
decryptlazy :: Ctx -> ByteString -> (Ctx, ByteString)
Documentation
type Ctx = (Vector Word8, Word8, Word8)
initCtx :: [Word8] -> Ctx
initCtx initialize the Ctx with the key as parameter. the key can be of any size but not empty
encrypt :: Ctx -> ByteString -> (Ctx, ByteString)
encrypt with the current context a bytestring and returns a new context and the resulted encrypted bytestring
decrypt :: Ctx -> ByteString -> (Ctx, ByteString)
decrypt with the current context a bytestring and returns a new context and the resulted decrypted bytestring
encryptlazy :: Ctx -> ByteString -> (Ctx, ByteString)
encrypt with the current context a lazy bytestring and returns a new context and the resulted lencrypted lazy bytestring
decryptlazy :: Ctx -> ByteString -> (Ctx, ByteString)
decrypt with the current context a lazy bytestring and returns a new context and the resulted decrypted lazy bytestring
Produced by Haddock version 2.7.2