Crypto.Hash.MD2

cryptohash-0.7.10: collection of crypto hashes, fast, pure and practical

License | BSD-style
Maintainer | Vincent Hanquez <vincent@snarc.org>
Stability | experimental
Portability | unknown
Safe Haskell | Trustworthy
Language | Haskell98

Crypto.Hash.MD2

Contents

- Incremental hashing Functions
- Single Pass hashing

Description

A module containing MD2 bindings

Synopsis

- data Ctx = Ctx !ByteString
- data MD2
- init :: Ctx
- update :: Ctx -> ByteString -> Ctx
- finalize :: Ctx -> ByteString
- hash :: ByteString -> ByteString
- hashlazy :: ByteString -> ByteString

# Documentation

data Ctx #

Constructors

Ctx !ByteString |

Instances

Hash Ctx MD2 # |
Methods outputLength :: Tagged * MD2 BitLength # blockLength :: Tagged * MD2 BitLength # initialCtx :: Ctx # updateCtx :: Ctx -> ByteString -> Ctx # finalize :: Ctx -> ByteString -> MD2 # hash :: ByteString -> MD2 # hash' :: ByteString -> MD2 #

data MD2 #

Instances

Eq MD2 # |
Methods (==) :: MD2 -> MD2 -> Bool # (/=) :: MD2 -> MD2 -> Bool #
Ord MD2 # |
Methods compare :: MD2 -> MD2 -> Ordering # (<) :: MD2 -> MD2 -> Bool # (<=) :: MD2 -> MD2 -> Bool # (>) :: MD2 -> MD2 -> Bool # (>=) :: MD2 -> MD2 -> Bool # max :: MD2 -> MD2 -> MD2 # min :: MD2 -> MD2 -> MD2 #
Show MD2 # |
Methods showsPrec :: Int -> MD2 -> ShowS # show :: MD2 -> String # showList :: [MD2] -> ShowS #
Serialize MD2 # |
Methods put :: Putter MD2 # get :: Get MD2 #
Hash Ctx MD2 # |
Methods outputLength :: Tagged * MD2 BitLength # blockLength :: Tagged * MD2 BitLength # initialCtx :: Ctx # updateCtx :: Ctx -> ByteString -> Ctx # finalize :: Ctx -> ByteString -> MD2 # hash :: ByteString -> MD2 # hash' :: ByteString -> MD2 #

# Incremental hashing Functions

init :: Ctx #

init a context

update :: Ctx -> ByteString -> Ctx #

update a context with a bytestring

finalize :: Ctx -> ByteString #

finalize the context into a digest bytestring

# Single Pass hashing

hash :: ByteString -> ByteString #

hash a strict bytestring into a digest bytestring

hashlazy :: ByteString -> ByteString #

hash a lazy bytestring into a digest bytestring