packages feed

ppad-hkdf 0.2.0 → 0.2.1

raw patch · 4 files changed

+15/−5 lines, 4 filesdep +ppad-base16dep −base16-bytestringPVP ok

version bump matches the API change (PVP)

Dependencies added: ppad-base16

Dependencies removed: base16-bytestring

API changes (from Hackage documentation)

Files

CHANGELOG view
@@ -1,5 +1,9 @@ # Changelog +- 0.2.1 (2025-02-24)+  * Merely swaps out the base16 library used for the Wycheproof tests+    (in favour of ppad-base16).+ - 0.2.0 (2025-01-10)   * API change, opting for "derive" in place of "hkdf" to work more     smoothly with a import qualifier like "KDF".
lib/Crypto/KDF/HMAC.hs view
@@ -12,9 +12,11 @@ -- [RFC5869](https://datatracker.ietf.org/doc/html/rfc5869).  module Crypto.KDF.HMAC (+    -- * HMAC synonym+    HMAC+     -- * HMAC-based KDF-    derive-  , HMAC+  , derive      -- internals   , extract@@ -40,6 +42,8 @@ --   >>> import qualified Crypto.Hash.SHA256 as SHA256 --   >>> :t SHA256.hmac --   SHA256.hmac :: BS.ByteString -> BS.ByteString -> BS.ByteString+--   >>> SHA256.hmac "my HMAC key" "my HMAC input"+--   <256-bit MAC> type HMAC = BS.ByteString -> BS.ByteString -> BS.ByteString  -- HMAC function and its associated outlength
ppad-hkdf.cabal view
@@ -1,6 +1,6 @@ cabal-version:      3.0 name:               ppad-hkdf-version:            0.2.0+version:            0.2.1 synopsis:           A HMAC-based key derivation function license:            MIT license-file:       LICENSE@@ -43,8 +43,8 @@   build-depends:       aeson     , base-    , base16-bytestring     , bytestring+    , ppad-base16     , ppad-hkdf     , ppad-sha256     , ppad-sha512
test/Wycheproof.hs view
@@ -48,7 +48,9 @@   } deriving Show  decodehex :: T.Text -> BS.ByteString-decodehex = B16.decodeLenient . TE.encodeUtf8+decodehex t = case B16.decode (TE.encodeUtf8 t) of+  Nothing -> error "bang"+  Just bs -> bs  instance A.FromJSON HkdfTest where   parseJSON = A.withObject "HkdfTest" $ \m -> HkdfTest