hashcom-rs
Cover by DALL-E.
Introduction
Commitment schemes are very powerful cryptographic primitives used in many existing solutions.
I was inspired by the go-ibft to create a framework to easily integrate and customize a hash commitment scheme in a rust application.
This package exposes both a trait for you to build your scheme given a specific hash function, or use an existing one.
Architecture
The hashcom-rs
library exposes a HashCommitmentScheme
trait that can be
implemented with you own hash function.
You'll just have to implement the commit
and verify
methods.
A SHA256
implementation is already provided. Below is an example of how it can be used
(here, there's only one party who acts as both the prover and the verifier):
/// Here, one party acts as both the prover and the verifier,
/// assuming that the verifier is not malicious.
Authors
Made with ❤️ by 🤖 0xpanoramix 🤖