forked from Colfenor/classic-mceliece-rust
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Cargo.toml
74 lines (66 loc) · 2.41 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
[package]
name = "classic-mceliece-rust"
description = "Pure rust implementation of the PQC scheme Classic McEliece"
repository = "https://github.com/Colfenor/classic-mceliece-rust"
readme = "README.md"
license = "MIT"
version = "3.0.0"
authors = [
"Bernhard Berg <[email protected]>",
"Lukas Prokop <[email protected]>",
"Daniel Kales <[email protected]>",
"Linus Färnstrand",
]
edition = "2021"
keywords = ["pqc", "post-quantum", "cryptography", "decoding"]
categories = ["cryptography"]
exclude = ["/data"]
[dependencies]
rand = { version = "0.8", default-features = false }
sha3 = { version = "0.10", default-features = false }
kem = { version = "0.2", optional = true }
zeroize = { version = "1.5.7", default-features = false, optional = true }
[features]
## When adding features or changing the default features, remember to update
## the `[package.metadata.docs.rs]` section further down as well as the docs
## generation CI job
# alloc := enable, if the platform supports dynamic memory allocation
# zeroize := enable to nullify sensitive memory sections after they go out of scope
default = ["alloc", "zeroize"]
alloc = []
# The kem feature is currently depending on alloc due to how `Encapsulator::try_encap`
# can only take 'static public keys. So it's unergonomic to use without the heap for now.
kem = ["dep:kem", "alloc"]
# Select which variant of Classic McEliece to compile for.
# Only one of these features can be enabled.
mceliece348864 = []
mceliece348864f = []
mceliece460896 = []
mceliece460896f = []
mceliece6688128 = []
mceliece6688128f = []
mceliece6960119 = []
mceliece6960119f = []
mceliece8192128 = []
mceliece8192128f = []
[[example]]
name = "client-server"
required-features = ["alloc"]
[[bench]]
name = "kem_api"
harness = false
[dev-dependencies]
rand = { version = "0.8", features = ["default"] }
criterion = { version = "0.3", features = ["html_reports"] }
criterion-cycles-per-byte = "0.1.2"
aes = "0.8"
hex = "0.4.3"
[profile.dev]
opt-level = 1 # reduces runtime for KATNUM=2 from 281s to 11s
[package.metadata.docs.rs]
## Uses the #[doc(feature(...))] functionality to clearly show in the generated documentation
## which feature of this crate is needed for each type and function to be available.
## This increases discoverability of features massively.
## To use this locally, run: `RUSTDOCFLAGS="--cfg docsrs" cargo doc --features kem`.
features = ["kem"]
rustdoc-args = ["--cfg", "docsrs"]