forked from cryspen/libcrux
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCargo.toml
87 lines (72 loc) · 2.12 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
75
76
77
78
79
80
81
82
83
84
85
86
87
[package]
name = "libcrux-ml-kem"
version.workspace = true
authors.workspace = true
license.workspace = true
homepage.workspace = true
edition.workspace = true
repository.workspace = true
readme = "README.md"
description = "Libcrux ML-KEM & Kyber implementations"
exclude = [
"/tests",
"/implementation_notes.pdf",
"/c",
"/proofs",
"/c.sh",
"/c.yaml",
"/hax.py",
]
[dependencies]
rand_core = { version = "0.6" }
libcrux-platform = { version = "0.0.2-alpha.3", path = "../sys/platform" }
libcrux-sha3 = { version = "0.0.2-alpha.3", path = "../libcrux-sha3" }
libcrux-intrinsics = { version = "0.0.2-alpha.3", path = "../libcrux-intrinsics" }
# This is only required for verification.
# The hax config is set by the hax toolchain.
[target.'cfg(hax)'.dependencies]
hax-lib = { version = "0.1.0-alpha.1", git = "https://github.com/hacspec/hax/" }
[features]
# By default all variants and std are enabled.
default = ["std", "mlkem512", "mlkem768", "mlkem1024"]
# Hardware features can be force enabled.
# It is not recommended to use these. This crate performs CPU feature detection
# and enables the features when they are available.
simd128 = ["libcrux-sha3/simd128","libcrux-intrinsics/simd128"]
simd256 = ["libcrux-sha3/simd256","libcrux-intrinsics/simd256"]
# Features for the different key sizes of ML-KEM
mlkem512 = []
mlkem768 = []
mlkem1024 = []
# Enable Round 3 Kyber in addition to ML-KEM
kyber = []
# Code that is not yet verified
pre-verification = []
std = []
[dev-dependencies]
rand = { version = "0.8" }
serde_json = { version = "1.0" }
serde = { version = "1.0", features = ["derive"] }
hex = { version = "0.4.3", features = ["serde"] }
criterion = "0.5"
[[bench]]
name = "ml-kem"
harness = false
[[example]]
name = "encapsulate"
required-features = ["mlkem768"]
[[example]]
name = "decapsulate"
required-features = ["mlkem768"]
[[example]]
name = "keygen"
required-features = ["mlkem768"]
[package.metadata."docs.rs"]
features = ["pre-verification", "kyber"]
rustdoc-args = ["--cfg", "doc_cfg"]
[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = [
'cfg(hax)',
'cfg(eurydice)',
'cfg(doc_cfg)',
] }