dalek-cryptography / bulletproofs

A pure-Rust implementation of Bulletproofs using Ristretto.
MIT License
1.02k stars 216 forks source link

Example on Readme is outdated | should use curve25519_dalek_ng #373

Open tapiocaboy opened 9 months ago

tapiocaboy commented 9 months ago

Seems the example on README uses use curve25519_dalek::scalar::Scalar; but it expects use curve25519_dalek_ng::scalar::Scalar;

The function

    #[cfg(feature = "std")]
    pub fn prove_single(
        bp_gens: &BulletproofGens,
        pc_gens: &PedersenGens,
        transcript: &mut Transcript,
        v: u64,
        v_blinding: &Scalar,

accepts v_blinding accepts type

curve25519_dalek_ng::scalar
pub struct Scalar
tapiocaboy commented 9 months ago

I can make a PR for this

potuz commented 7 months ago

The last two issues on the repo are about this. In addition the ng package is outdated with respect to the original curve25519-dalek package and so it's missing some methods like the basic from() to construct scalars.

Stentonian commented 7 months ago

I've made a PR on zkcrypto/bulletproofs (which is bulletproofs version 4 on crates.io, where as this repo is version 2) to sort out the dependency issues.

See here for more details: https://github.com/zkcrypto/bulletproofs/issues/15

I'm not sure what the best way forward is: