packages feed

secret-sharing 1.0.1.1 → 1.0.1.2

raw patch · 5 files changed

+14/−12 lines, 5 files

Files

ChangeLog.md view
@@ -4,6 +4,11 @@  * None +## 1.0.1.2++* Updated README.+* Minor cleanups.+ ## 1.0.1.1  * Make it build with `stack`.
README.md view
@@ -8,7 +8,7 @@ Suppose that you want to split the string "my secret data" into n=5 shares such that at least m=3 shares are necessary to reconstruct the secret. -~~~+~~~ {.haskell} ❯ :m + Data.ByteString.Lazy.Char8 Crypto.SecretSharing ❯ let secret = pack "my secret message!" ❯ shares <- encode 3 5 secret
secret-sharing.cabal view
@@ -4,17 +4,17 @@ -- -- see: https://github.com/sol/hpack ----- hash: c1b1eeaf605102f858663726f0899511ab89b9122b1205e48ea433922ddfbd3f+-- hash: c21dac92ca7fbfcbf556d7a2483bfb7a84eaaae8527274e6796ab95b958a0492  name:           secret-sharing-version:        1.0.1.1+version:        1.0.1.2 synopsis:       Information-theoretic secure secret sharing description:    Please see the README on GitHub at <https://github.com/pwrobinson/secret-sharing#readme> category:       Data, Cryptography homepage:       https://github.com/pwrobinson/secret-sharing#readme bug-reports:    https://github.com/pwrobinson/secret-sharing/issues author:         Peter Robinson-maintainer:     pwr@lowerbound.io+maintainer:     peter@lowerbound.io copyright:      2014-2020 Peter Robinson license:        LGPL-2.1 license-file:   LICENSE
src/Crypto/SecretSharing.hs view
@@ -3,19 +3,18 @@ -- Module      :  Crypto.SecretSharing -- Copyright   :  Peter Robinson 2014 -- License     :  LGPL--- --- Maintainer  :  Peter Robinson <peter.robinson@monoid.at>+-- -- Stability   :  experimental -- Portability :  portable--- +-- -- Implementation of an (@m@,@n@)-threshold secret sharing scheme.--- A given ByteString @b@ (the secret) is split into @n@ shares, +-- A given ByteString @b@ (the secret) is split into @n@ shares, -- and any @m@ shares are sufficient to reconstruct @b@. -- The scheme preserves perfect secrecy in the sense that the knowledge of up -- to @m-1@ shares does not reveal any information about the secret @b@. -- -- Typically, there are @n@ parties and we would like to give the @i@-th party--- the @i@-share of each byte. +-- the @i@-share of each byte. -- For example, to encode a bytestring @secret@ as @10@ shares, any @5@ of which -- are sufficient for reconstruction we could write: --@@ -27,7 +26,7 @@ -- The mathematics behind the secret sharing scheme is described in: -- \"How to share a secret.\" by Shamir, Adi. -- In Communications of the ACM 22 (11): 612–613, 1979.--- +-- -- ----------------------------------------------------------------------------- 
src/Crypto/SecretSharing/Internal.hs view
@@ -5,7 +5,6 @@ -- Copyright   :  Peter Robinson 2014 -- License     :  LGPL ----- Maintainer  :  Peter Robinson <peter.robinson@monoid.at> -- Stability   :  experimental -- Portability :  portable --@@ -158,4 +157,3 @@   foldr (\c res -> c + (x * res)) 0 coeffs --  let clist = zipWith (\pow c -> (\x -> c * (x^pow))) [0..] coeffs --  in L.foldl' (+) 0 [ c x | c <- clist ]-