packages feed

crypto-cipher-benchmarks 0.0.1 → 0.0.2

raw patch · 2 files changed

+9/−7 lines, 2 filesdep ~crypto-cipher-typesPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: crypto-cipher-types

API changes (from Hackage documentation)

Files

Crypto/Cipher/Benchmarks.hs view
@@ -25,7 +25,6 @@ import Text.Printf import Text.PrettyPrint hiding (Mode, mode) -import Data.Maybe import Control.Monad.Trans  import qualified Data.ByteString as B@@ -68,7 +67,9 @@ modeToBench cipher ECB = Just $ ecbEncrypt cipher modeToBench cipher CBC = Just $ cbcEncrypt cipher nullIV modeToBench cipher CTR = Just $ ctrCombine cipher nullIV-modeToBench cipher XTS = Just $ xtsEncrypt (cipher, cipher) nullIV 0+modeToBench cipher XTS+    | blockSize cipher == 16 = Just $ xtsEncrypt (cipher, cipher) nullIV 0+    | otherwise              = Nothing modeToBench cipher OCB = benchAEAD cipher AEAD_OCB modeToBench cipher GCM = benchAEAD cipher AEAD_GCM modeToBench cipher CCM = benchAEAD cipher AEAD_CCM@@ -160,9 +161,10 @@         instanciate :: BlockCipher a => a -> a         instanciate c =             let bs = case cipherKeySize c of-                            Nothing -> B.replicate 1 0-                            Just sz -> B.replicate sz 1-             in cipherInit (fromJust $ makeKey bs)+                            KeySizeRange low _ -> B.replicate low 0+                            KeySizeFixed sz    -> B.replicate sz 1+                            KeySizeEnum l      -> B.replicate (head l) 2+             in cipherInit (either (error . show) id $ makeKey bs)  -- | DefaultMain: parse command line arguments, run benchmarks -- and report
crypto-cipher-benchmarks.cabal view
@@ -1,5 +1,5 @@ Name:                crypto-cipher-benchmarks-Version:             0.0.1+Version:             0.0.2 Synopsis:            Generic cryptography cipher benchmarks Description:         Generic cryptography cipher benchmarks License:             BSD3@@ -20,7 +20,7 @@                    , byteable >= 0.1.1                    , securemem >= 0.1.1                    , criterion-                   , crypto-cipher-types+                   , crypto-cipher-types >= 0.0.3                    , mtl                    , pretty   ghc-options:       -Wall -fwarn-tabs