This is a first version of a vector commitment library built on the dalek-ng implementation of the Ristretto Group. This crate hasn't been audited and should NOT be used for anything other than PoCs. There should be no expectations of consistent or stable APIs at this point. If you don't need to do vector commitments, then you should use bulletproofs::PedersenGens.
use pedersen_vectors::VectorCommiter;
let mut trapdoor = VectorCommitter::new(1_000_000);
let blinding_factor = Scalar::random(&mut rng);
let empty_vector: Vec<Scalar> = Vec::new();
// We commit to the zero vector here
let commitment_zero_vector = trapdoor.commit(empty_vector, blinding_factor);
The recipe to generate the commitment's bases will change before this crate hits v1.0.0. As of v0.1.2, for a VectorCommitter
of size N
where
Using bulletproofs::PedersenGens instead
Unless you need to do vector commitments, you should be able to use the Pedersen commitment implementation that lives in the bulletproof crate. It offers a similar API, and swappable bases as well.