packages feed

signable 0.3 → 0.4

raw patch · 3 files changed

+21/−11 lines, 3 files

Files

ChangeLog.md view
@@ -1,3 +1,7 @@+# Version 0.4++- Deriving `Eq`, `Ord` and `Show` for the most of types+ # Version 0.3  - Support of `secp256k1-haskell-0.5`
signable.cabal view
@@ -4,10 +4,10 @@ -- -- see: https://github.com/sol/hpack ----- hash: d2dec01d6000877a395f9d10ab73143cd8321afc169632f2e8756c037b851444+-- hash: 1b1f1fca72125a793348ae6d27414f7669c96f68321927e0ea6ac69784bbce6e  name:           signable-version:        0.3+version:        0.4 synopsis:       Deterministic serialisation and signatures with proto-lens support description:    You can find documentation at <https://hackage.haskell.org/package/signable/docs/Data-Signable.html hackage> category:       Data, Cryptography
src/Data/Signable/Class.hs view
@@ -54,7 +54,7 @@ import Prelude (show)  data Alg = AlgSecp256k1-  deriving (Show)+  deriving (Eq, Ord, Show)  data SignableError   = InvalidPem@@ -65,25 +65,31 @@   | TooManyAsn1Chunks   | InvalidPubKeyDer   | InvalidPrvKeyRaw-  deriving (Show)+  deriving (Eq, Ord, Show)  data ECPointFormat   = ECPointCompressed   | ECPointUncompressed+  deriving (Eq, Ord, Show)++newtype PubKey+  = PubKeySecp256k1 C.PubKey   deriving (Eq, Show) -newtype PubKey = PubKeySecp256k1 C.PubKey+newtype PrvKey+  = PrvKeySecp256k1 C.SecKey+  deriving (Eq) -newtype PrvKey = PrvKeySecp256k1 C.SecKey+instance Show PrvKey where+  show = const "SECRET" -newtype Sha256 = Sha256 ByteString+newtype Sha256+  = Sha256 ByteString+  deriving (Eq, Ord, Show)  newtype Sig   = SigSecp256k1 C.Sig-  deriving newtype (Eq)--instance Show Sig where-  show = const "SECRET"+  deriving (Eq, Show)  pubKey2Alg :: PubKey -> Alg pubKey2Alg (PubKeySecp256k1 _) = AlgSecp256k1