[package] name = "elastic-elgamal" version = "0.3.1" authors = [ "Alex Ostrovski ", "Jiří Gavenda ", "Antonín Dufka ", "Tiago Cerqueira ", ] edition = "2021" rust-version = "1.65" readme = "README.md" license = "MIT OR Apache-2.0" repository = "https://github.com/slowli/elastic-elgamal" keywords = ["elgamal", "encryption", "zero-knowledge"] categories = ["cryptography", "no-std"] description = """\ Implementation of ElGamal encryption and related zero-knowledge proofs with pluggable crypto backend """ [package.metadata.docs.rs] features = ["serde"] # Set `docsrs` to enable unstable `doc(cfg(...))` attributes. rustdoc-args = ["--cfg", "docsrs"] [dependencies] # Public dependencies (present in public API of the crate). elliptic-curve = { version = "0.13.8", features = ["sec1"] } rand_core = { version = "0.6.2", default-features = false } zeroize = { version = "1.8.1", default-features = false, features = ["alloc"] } sha2 = { version = "0.10.8", default-features = false } # Enables `Serialize` / `Deserialize` implementation for most types in the crate. serde = { version = "1.0", default-features = false, features = ["derive", "alloc"], optional = true } # Private dependencies (not exposed via public APIs). base64ct = { version = "1.0", default-features = false, features = ["alloc"] } hashbrown = { version = "0.15.1", optional = true } merlin = { version = "3.0.0", default-features = false } rand_chacha = { version = "0.3.1", default-features = false } subtle = { version = "2.6.1", default-features = false } # Crypto backend to support Curve25519 prime subgroup and Ristretto255 group; # a public dependency. [dependencies.curve25519-dalek] version = "4.1.3" optional = true # Crypto backend to support Curve25519 prime subgroup and Ristretto255 group; # a public dependency. Alternative and mutually exclusive with `curve25519-dalek`. [dependencies.curve25519-dalek-ng] version = "4.1.1" default-features = false features = ["alloc"] optional = true [dev-dependencies] bulletproofs = "5.0.0" criterion = "0.5.0" doc-comment = "0.3.3" insta = { version = "1.41.1", features = ["yaml"] } k256 = { version = "0.13", default-features = false, features = ["arithmetic"] } rand = "0.8.3" serde_json = "1.0" clap = { version = "4.5.20", features = ["derive"] } test-casing = "0.1.3" version-sync = "0.9.2" [features] default = ["std", "curve25519-dalek"] # Enables support of types from `std`, such as the `Error` trait. std = [] [[bench]] name = "basics" path = "benches/basics.rs" harness = false required-features = ["default"] [[bench]] name = "sharing" path = "benches/sharing.rs" harness = false required-features = ["default"] [[example]] name = "voting" path = "examples/voting.rs" required-features = ["default", "serde"] [[example]] name = "range" path = "examples/range.rs" required-features = ["default", "serde"] [[example]] name = "equivalence" path = "examples/equivalence.rs" required-features = ["default", "serde"] [[test]] name = "integration" path = "tests/integration/main.rs" required-features = ["default"] [[test]] name = "snapshots" path = "tests/snapshots.rs" required-features = ["default", "serde"] # Speed up `k256` and `curve25519-dalek` arithmetic. [profile.dev.package.k256] opt-level = 2 [profile.dev.package.curve25519-dalek] opt-level = 2