Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- class Commit ck a f where
- commit :: ck -> a -> f
- class HomomorphicCommit ck a c where
- hcommit :: ck -> a -> c
- class PedersonSetup a where
- pedersonGH :: (a, a)
Documentation
class Commit ck a f where Source #
Commit to the object a
with commitment key ck
and results of type f
Instances
(RandomOracle ck x, RandomOracle a x, Ring x) => Commit ck a x Source # | |
Defined in ZkFold.Base.Protocol.Protostar.Commit |
class HomomorphicCommit ck a c where Source #
Homomorphic commitment scheme, i.e. (hcommit ck1 a1) * (hcommit ck2 a2) == hcommit (ck1 + ck2) (a1 + a2)
Instances
(EllipticCurve c, HomomorphicCommit a b (Point c), Foldable t) => HomomorphicCommit a (t b) (Point c) Source # | |
Defined in ZkFold.Base.Protocol.Protostar.Commit | |
(Symbolic ctx, EllipticCurve c, SymbolicData (Point c), Context (Point c) ~ ctx, PedersonSetup (Point c), Layout (Point c) ~ l, Representable l, Traversable l) => HomomorphicCommit (FieldElement ctx) (FieldElement ctx) (Point c) Source # | Pedersen commitment scheme Commitment key consists of field elements g and h, and randomness r |
Defined in ZkFold.Base.Protocol.Protostar.Commit hcommit :: FieldElement ctx -> FieldElement ctx -> Point c Source # |
class PedersonSetup a where Source #
pedersonGH :: (a, a) Source #
Instances
PedersonSetup (Point BLS12_381_G1) Source # | |
Defined in ZkFold.Base.Protocol.Protostar.Commit | |
(Symbolic c, FromConstant Natural (BaseField (Ed25519 c))) => PedersonSetup (Point (Ed25519 c)) Source # | |
Defined in ZkFold.Base.Protocol.Protostar.Commit |