diff --git a/crypto/dkg/Cargo.toml b/crypto/dkg/Cargo.toml index 2d8066a6..cde0d153 100644 --- a/crypto/dkg/Cargo.toml +++ b/crypto/dkg/Cargo.toml @@ -95,5 +95,6 @@ evrf = [ ] evrf-secp256k1 = ["evrf", "ciphersuite/secp256k1", "secq256k1"] evrf-ed25519 = ["evrf", "ciphersuite/ed25519", "embedwards25519"] +evrf-ristretto = ["evrf", "ciphersuite/ristretto", "embedwards25519"] tests = ["rand_core/getrandom"] default = ["std"] diff --git a/crypto/dkg/src/evrf/proof.rs b/crypto/dkg/src/evrf/proof.rs index ed9f29d1..16eae424 100644 --- a/crypto/dkg/src/evrf/proof.rs +++ b/crypto/dkg/src/evrf/proof.rs @@ -45,6 +45,12 @@ impl EvrfCurve for ciphersuite::Ed25519 { type EmbeddedCurveParameters = embedwards25519::Embedwards25519; } +#[cfg(feature = "evrf-ristretto")] +impl EvrfCurve for ciphersuite::Ristretto { + type EmbeddedCurve = embedwards25519::Embedwards25519; + type EmbeddedCurveParameters = embedwards25519::Embedwards25519; +} + fn sample_point(rng: &mut (impl RngCore + CryptoRng)) -> C::G { let mut repr = ::Repr::default(); loop { diff --git a/processor/Cargo.toml b/processor/Cargo.toml index 7b086636..24719bfd 100644 --- a/processor/Cargo.toml +++ b/processor/Cargo.toml @@ -37,7 +37,7 @@ serde_json = { version = "1", default-features = false, features = ["std"] } ciphersuite = { path = "../crypto/ciphersuite", default-features = false, features = ["std", "ristretto"] } transcript = { package = "flexible-transcript", path = "../crypto/transcript", default-features = false, features = ["std"] } -dkg = { package = "dkg", path = "../crypto/dkg", default-features = false, features = ["std"] } +dkg = { package = "dkg", path = "../crypto/dkg", default-features = false, features = ["std", "evrf-ristretto"] } frost = { package = "modular-frost", path = "../crypto/frost", default-features = false, features = ["ristretto"] } frost-schnorrkel = { path = "../crypto/schnorrkel", default-features = false }