Update and remove unused dependencies

This commit is contained in:
Luke Parker 2023-03-07 03:06:46 -05:00
parent d36fc026dd
commit 0e8c55e050
No known key found for this signature in database
15 changed files with 35 additions and 52 deletions

14
Cargo.lock generated
View file

@ -1696,11 +1696,9 @@ dependencies = [
"dleq", "dleq",
"flexible-transcript", "flexible-transcript",
"group", "group",
"hex",
"multiexp", "multiexp",
"rand_core 0.6.4", "rand_core 0.6.4",
"schnorr-signatures", "schnorr-signatures",
"subtle",
"thiserror", "thiserror",
"zeroize", "zeroize",
] ]
@ -3081,15 +3079,6 @@ version = "0.3.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0" checksum = "7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0"
[[package]]
name = "hkdf"
version = "0.12.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437"
dependencies = [
"hmac 0.12.1",
]
[[package]] [[package]]
name = "hmac" name = "hmac"
version = "0.8.1" version = "0.8.1"
@ -4610,7 +4599,6 @@ version = "0.1.2"
dependencies = [ dependencies = [
"crypto-bigint", "crypto-bigint",
"dalek-ff-group", "dalek-ff-group",
"digest 0.10.6",
"ff", "ff",
"ff-group-tests", "ff-group-tests",
"generic-array 0.14.6", "generic-array 0.14.6",
@ -4680,7 +4668,6 @@ dependencies = [
name = "modular-frost" name = "modular-frost"
version = "0.5.0" version = "0.5.0"
dependencies = [ dependencies = [
"chacha20 0.9.0",
"ciphersuite", "ciphersuite",
"dalek-ff-group", "dalek-ff-group",
"digest 0.10.6", "digest 0.10.6",
@ -4689,7 +4676,6 @@ dependencies = [
"flexible-transcript", "flexible-transcript",
"group", "group",
"hex", "hex",
"hkdf",
"minimal-ed448", "minimal-ed448",
"multiexp", "multiexp",
"rand_chacha 0.3.1", "rand_chacha 0.3.1",

View file

@ -12,7 +12,6 @@ all-features = true
rustdoc-args = ["--cfg", "docsrs"] rustdoc-args = ["--cfg", "docsrs"]
[dependencies] [dependencies]
hex-literal = "0.3"
lazy_static = "1" lazy_static = "1"
thiserror = "1" thiserror = "1"
@ -22,12 +21,12 @@ rand = "0.8"
rand_distr = "0.4" rand_distr = "0.4"
zeroize = { version = "^1.5", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
subtle = "2.4" subtle = "^2.4"
sha3 = "0.10" sha3 = "0.10"
blake2 = { version = "0.10", optional = true } blake2 = { version = "0.10", optional = true }
curve25519-dalek = { version = "3", features = ["std"] } curve25519-dalek = { version = "^3.2", features = ["std"] }
group = { version = "0.12" } group = { version = "0.12" }
dalek-ff-group = { path = "../../crypto/dalek-ff-group", version = "0.1" } dalek-ff-group = { path = "../../crypto/dalek-ff-group", version = "0.1" }
@ -54,6 +53,8 @@ dalek-ff-group = { path = "../../crypto/dalek-ff-group", version = "0.1" }
monero-generators = { path = "generators", version = "0.1" } monero-generators = { path = "generators", version = "0.1" }
[dev-dependencies] [dev-dependencies]
hex-literal = "0.3"
tokio = { version = "1", features = ["full"] } tokio = { version = "1", features = ["full"] }
frost = { package = "modular-frost", path = "../../crypto/frost", version = "0.5", features = ["ed25519", "tests"] } frost = { package = "modular-frost", path = "../../crypto/frost", version = "0.5", features = ["ed25519", "tests"] }

View file

@ -14,7 +14,7 @@ rustdoc-args = ["--cfg", "docsrs"]
[dependencies] [dependencies]
lazy_static = "1" lazy_static = "1"
subtle = "2.4" subtle = "^2.4"
sha3 = "0.10" sha3 = "0.10"

View file

@ -16,7 +16,7 @@ rustdoc-args = ["--cfg", "docsrs"]
rand_core = "0.6" rand_core = "0.6"
zeroize = { version = "^1.5", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
subtle = "2" subtle = "^2.4"
digest = "0.10" digest = "0.10"
transcript = { package = "flexible-transcript", path = "../transcript", version = "0.2" } transcript = { package = "flexible-transcript", path = "../transcript", version = "0.2" }

View file

@ -17,15 +17,15 @@ rand_core = "0.6"
digest = "0.10" digest = "0.10"
zeroize = { version = "^1.5", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
subtle = "2.4" subtle = "^2.4"
ff = "0.12" ff = { version = "0.12", features = ["bits"] }
group = "0.12" group = "0.12"
crypto-bigint = "0.4" crypto-bigint = "0.4"
sha2 = "0.9" sha2 = "0.9"
curve25519-dalek = "3.2" curve25519-dalek = "^3.2"
[dev-dependencies] [dev-dependencies]
ff-group-tests = { path = "../ff-group-tests" } ff-group-tests = { path = "../ff-group-tests" }

View file

@ -9,7 +9,7 @@ use subtle::{
use crypto_bigint::{Integer, Encoding, U256, U512}; use crypto_bigint::{Integer, Encoding, U256, U512};
use ff::{Field, PrimeField, FieldBits, PrimeFieldBits}; use group::ff::{Field, PrimeField, FieldBits, PrimeFieldBits};
use crate::{constant_time, math, from_uint}; use crate::{constant_time, math, from_uint};

View file

@ -32,8 +32,11 @@ use dalek::{
}, },
}; };
use ff::{Field, PrimeField, FieldBits, PrimeFieldBits}; use group::{
use group::{Group, GroupEncoding, prime::PrimeGroup}; ff::{Field, PrimeField, FieldBits, PrimeFieldBits},
Group, GroupEncoding,
prime::PrimeGroup,
};
pub mod field; pub mod field;

View file

@ -18,9 +18,6 @@ thiserror = "1"
rand_core = "0.6" rand_core = "0.6"
zeroize = { version = "^1.5", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
subtle = "2"
hex = "0.4"
transcript = { package = "flexible-transcript", path = "../transcript", version = "0.2", features = ["recommended"] } transcript = { package = "flexible-transcript", path = "../transcript", version = "0.2", features = ["recommended"] }
chacha20 = { version = "0.9", features = ["zeroize"] } chacha20 = { version = "0.9", features = ["zeroize"] }

View file

@ -66,7 +66,7 @@ impl<C: Ciphersuite, M: Message> EncryptionKeyMessage<C, M> {
buf buf
} }
// Used by tests #[cfg(any(test, feature = "tests"))]
pub(crate) fn enc_key(&self) -> C::G { pub(crate) fn enc_key(&self) -> C::G {
self.enc_key self.enc_key
} }

View file

@ -12,10 +12,10 @@ all-features = true
rustdoc-args = ["--cfg", "docsrs"] rustdoc-args = ["--cfg", "docsrs"]
[dependencies] [dependencies]
thiserror = "1" thiserror = { version = "1", optional = true }
rand_core = "0.6" rand_core = "0.6"
zeroize = { version = "1.3", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
digest = "0.10" digest = "0.10"
@ -39,7 +39,7 @@ transcript = { package = "flexible-transcript", path = "../transcript", features
[features] [features]
std = [] std = []
serialize = ["std"] serialize = ["std"]
experimental = ["std", "multiexp"] experimental = ["std", "thiserror", "multiexp"]
secure_capacity_difference = [] secure_capacity_difference = []
# Only applies to experimental, yet is default to ensure security # Only applies to experimental, yet is default to ensure security

View file

@ -16,12 +16,11 @@ rustdoc-args = ["--cfg", "docsrs"]
lazy_static = "1" lazy_static = "1"
rand_core = "0.6" rand_core = "0.6"
digest = "0.10"
zeroize = { version = "^1.5", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
subtle = "2.4" subtle = "^2.4"
ff = "0.12" ff = { version = "0.12", features = ["bits"] }
group = "0.12" group = "0.12"
generic-array = "0.14" generic-array = "0.14"

View file

@ -11,7 +11,7 @@ macro_rules! field {
use generic_array::{typenum::U57, GenericArray}; use generic_array::{typenum::U57, GenericArray};
use crypto_bigint::{Integer, Encoding}; use crypto_bigint::{Integer, Encoding};
use ff::{Field, PrimeField, FieldBits, PrimeFieldBits}; use group::ff::{Field, PrimeField, FieldBits, PrimeFieldBits};
// Needed to publish for some reason? Yet not actually needed // Needed to publish for some reason? Yet not actually needed
#[allow(unused_imports)] #[allow(unused_imports)]

View file

@ -12,8 +12,11 @@ use subtle::{Choice, CtOption, ConstantTimeEq, ConditionallySelectable, Conditio
use crypto_bigint::U512; use crypto_bigint::U512;
use ff::{Field, PrimeField, PrimeFieldBits}; use group::{
use group::{Group, GroupEncoding, prime::PrimeGroup}; ff::{Field, PrimeField, PrimeFieldBits},
Group, GroupEncoding,
prime::PrimeGroup,
};
use crate::{ use crate::{
scalar::{Scalar, MODULUS as SCALAR_MODULUS}, scalar::{Scalar, MODULUS as SCALAR_MODULUS},

View file

@ -19,24 +19,19 @@ rand_core = "0.6"
rand_chacha = "0.3" rand_chacha = "0.3"
zeroize = { version = "^1.5", features = ["zeroize_derive"] } zeroize = { version = "^1.5", features = ["zeroize_derive"] }
subtle = "2" subtle = "^2.4"
hex = "0.4" hex = { version = "0.4", optional = true }
digest = "0.10" digest = "0.10"
transcript = { package = "flexible-transcript", path = "../transcript", version = "0.2", features = ["recommended"] }
hkdf = "0.12"
chacha20 = { version = "0.9", features = ["zeroize"] }
group = "0.12" group = "0.12"
ciphersuite = { path = "../ciphersuite", version = "0.1", features = ["std"] }
dalek-ff-group = { path = "../dalek-ff-group", version = "^0.1.2", optional = true } dalek-ff-group = { path = "../dalek-ff-group", version = "^0.1.2", optional = true }
minimal-ed448 = { path = "../ed448", version = "^0.1.2", optional = true } minimal-ed448 = { path = "../ed448", version = "^0.1.2", optional = true }
ciphersuite = { path = "../ciphersuite", version = "0.1", features = ["std"] }
transcript = { package = "flexible-transcript", path = "../transcript", version = "0.2", features = ["recommended"] }
multiexp = { path = "../multiexp", version = "0.2", features = ["batch"] } multiexp = { path = "../multiexp", version = "0.2", features = ["batch"] }
schnorr = { package = "schnorr-signatures", path = "../schnorr", version = "0.2" } schnorr = { package = "schnorr-signatures", path = "../schnorr", version = "0.2" }
@ -58,4 +53,4 @@ p256 = ["ciphersuite/p256"]
ed448 = ["minimal-ed448", "ciphersuite/ed448"] ed448 = ["minimal-ed448", "ciphersuite/ed448"]
tests = ["dkg/tests"] tests = ["hex", "dkg/tests"]

View file

@ -11,10 +11,7 @@ use zeroize::{Zeroize, Zeroizing};
use transcript::Transcript; use transcript::Transcript;
use group::{ use group::{ff::PrimeField, GroupEncoding};
ff::{Field, PrimeField},
GroupEncoding,
};
use multiexp::BatchVerifier; use multiexp::BatchVerifier;
use crate::{ use crate::{
@ -198,6 +195,8 @@ impl<C: Curve> Writable for SignatureShare<C> {
#[cfg(any(test, feature = "tests"))] #[cfg(any(test, feature = "tests"))]
impl<C: Curve> SignatureShare<C> { impl<C: Curve> SignatureShare<C> {
pub(crate) fn invalidate(&mut self) { pub(crate) fn invalidate(&mut self) {
use group::ff::Field;
self.0 += C::F::one(); self.0 += C::F::one();
} }
} }