forked from Argyle-Software/kyber
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Cargo.toml
78 lines (63 loc) · 2.25 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
[package]
name = "pqc_kyber_edit"
version = "0.7.2"
authors = ["Mitchell Berry <[email protected]>"]
edition = "2018"
license = "MIT/Apache-2.0"
repository = "https://github.com/sentclose/kyber"
documentation = "https://docs.rs/crate/pqc_kyber/"
categories = ["algorithms", "cryptography", "wasm", "no-std"]
description = "A rust implementation of the post-quantum Kyber KEM algorithm, with a fix for pqc_kyber KyberSlash"
keywords = ["kyber", "kem", "key-exchange", "kex", "post-quantum"]
readme = "readme.md"
[dependencies]
rand_core = { version = "0.6.4", default-features = false }
sha2 = { version = "0.10.7", optional = true , default-features = false }
zeroize = { version = "1.6.0", features = ["derive"], optional = true }
aes = { version = "0.8.3", optional = true }
ctr = { version = "0.9.2", optional = true }
# Optional dev-deps, see https://github.com/rust-lang/cargo/issues/1596
criterion = { version = "0.4.0", features = ["html_reports"], optional = true }
[dev-dependencies]
rand = "0.8.5"
[build-dependencies]
cc = {version = "1.0.73", optional = true }
nasm-rs = {version = "0.2.4", optional = true }
[[bench]]
name = "api"
harness = false
[features]
### Security Levels ###
# Defaults to "kyber768" if none selected
# Will throw a compile-time error if more than one level is chosen
kyber512 = []
kyber768 = []
kyber1024 = []
### Export IND-CPA primitives
# **WARNING** use with caution
hazmat = []
### Additional features ###
# 90s mode uses AES256-CTR and SHA2 as primitives instead
# Uses a bitslice implementation
90s = ["sha2"]
# Fixslice RustCrypto AES implementation offers some additional sidechannel
# attack resistance. Suggest benchmarking for comparison.
90s-fixslice = ["90s", "aes", "ctr"]
# Use avx2 intrinsics on x86 architectures
# Wont compile if the platform doesn't support it
avx2 = ["cc"]
# Uses Netwide Assembler avx2 code instead of GAS, this offers increased
# portability, you will need a nasm compiler installed.
# Can be downloaded from https://www.nasm.us/
nasm = ["nasm-rs", "avx2"]
# Enable std library support
std = []
# For benchmarking
benchmarking = ["criterion"]
# Prevents leak sanitiser failing in tests
[profile.test]
opt-level = 2
[profile.test.package."*"]
opt-level = 0
[profile.test.build-override]
opt-level = 0