Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module exposes combinators to compute the SHA512 hash and the associated HMAC for some common types.
Synopsis
- data SHA512
- sha512 :: PureByteSource src => src -> SHA512
- sha512File :: FilePath -> IO SHA512
- sha512Source :: ByteSource src => src -> IO SHA512
- hmacSha512 :: PureByteSource src => Key (HMAC SHA512) -> src -> HMAC SHA512
- hmacSha512File :: Key (HMAC SHA512) -> FilePath -> IO (HMAC SHA512)
- hmacSha512Source :: ByteSource src => Key (HMAC SHA512) -> src -> IO (HMAC SHA512)
The SHA512 cryptographic hash
The Sha512 hash value. Used in implementation of Sha384 as well.
Instances
Eq SHA512 Source # | |
Show SHA512 Source # | |
IsString SHA512 Source # | |
Defined in Raaz.Hash.Sha512.Internal fromString :: String -> SHA512 # | |
Storable SHA512 Source # | |
Equality SHA512 Source # | |
EndianStore SHA512 Source # | |
Encodable SHA512 Source # | |
Defined in Raaz.Hash.Sha512.Internal toByteString :: SHA512 -> ByteString Source # fromByteString :: ByteString -> Maybe SHA512 Source # | |
Recommendation SHA512 Source # | Recommend implementation for SHA512. |
Defined in Raaz.Hash.Sha512.Recommendation recommended :: SHA512 -> Implementation SHA512 Source # | |
Primitive SHA512 Source # | |
Hash SHA512 Source # | |
Defined in Raaz.Hash.Sha512.Internal | |
Initialisable (HashMemory SHA512) () Source # | |
Defined in Raaz.Hash.Sha512.Internal initialise :: () -> MT (HashMemory SHA512) () Source # | |
type Implementation SHA512 Source # | |
Defined in Raaz.Hash.Sha512.Internal |
sha512 :: PureByteSource src => src -> SHA512 Source #
Compute the sha512 hash of an instance of PureByteSource
. Use
this for computing the sha512 hash of a strict or lazy byte string.
sha512Source :: ByteSource src => src -> IO SHA512 Source #
Compute the sha512 hash of a general byte source.
HMAC computation using SHA512
:: PureByteSource src | |
=> Key (HMAC SHA512) | Key to use |
-> src | pure source whose hmac is to be computed |
-> HMAC SHA512 |
Compute the message authentication code using hmac-sha512.
Compute the message authentication code for a file.
hmacSha512Source :: ByteSource src => Key (HMAC SHA512) -> src -> IO (HMAC SHA512) Source #
Compute the message authetication code for a generic byte source.