-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
157 lines (135 loc) · 3.63 KB
/
Cargo.toml
File metadata and controls
157 lines (135 loc) · 3.63 KB
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
[package]
name = "tsn"
version = "1.3.0"
edition = "2021"
description = "TSN (Trust Stack Network) - A privacy-preserving post-quantum cryptocurrency"
license = "MIT"
[dependencies]
# Post-quantum cryptography (NIST FIPS 204 ML-DSA-65)
fips204 = "0.4"
# Hashing
sha2 = { version = "0.10", features = ["compress"] }
blake2 = "0.10"
light-poseidon = "0.2"
pbkdf2 = "0.12"
# zk-SNARKs (Groth16 on BN254 for compatibility with circomlibjs/snarkjs) - V1 LEGACY
ark-groth16 = "0.4"
ark-bls12-381 = "0.4"
ark-bn254 = "0.4"
ark-ff = "0.4"
ark-ec = "0.4"
ark-std = "0.4"
ark-serialize = { version = "0.4", features = ["derive"] }
ark-relations = "0.4"
ark-r1cs-std = "0.4"
ark-snark = "0.4"
ark-crypto-primitives = { version = "0.4", features = ["commitment", "merkle_tree", "prf", "sponge", "r1cs"] }
# Post-quantum ZK proofs (Plonky2 STARKs) - V2 QUANTUM-SAFE
# Plonky2 provides FRI-based proofs using only hash assumptions (quantum-resistant)
# Supports browser WASM compilation for client-side proving
plonky2 = "1.0"
plonky2_field = "1.0"
# Plonky3 (p3-*) — V3 AIR-based ZK proofs + Poseidon2 PoW hash
p3-poseidon2 = "0.4"
p3-goldilocks = "0.4"
p3-field = "0.4"
p3-symmetric = "0.4"
p3-uni-stark = "0.4"
p3-air = "0.4"
p3-challenger = "0.4"
p3-commit = "0.4"
p3-fri = "0.4"
p3-merkle-tree = "0.4"
p3-matrix = "0.4"
# Encryption (for note encryption)
chacha20poly1305 = "0.10"
aes = "0.8"
aes-gcm = "0.10"
# Serialization
serde = { version = "1", features = ["derive"] }
serde_json = "1"
bincode = "1"
toml = "0.8"
# Networking (HTTP API — kept for wallet, explorer, external tools)
axum = "0.7"
tokio = { version = "1", features = ["full"] }
tokio-util = "0.7"
tower-http = { version = "0.5", features = ["cors", "fs", "limit"] }
tower_governor = "0.4"
tower = "0.5"
reqwest = { version = "0.12", features = ["json"] }
# P2P Networking (libp2p — block propagation, peer discovery, NAT traversal)
libp2p = { version = "0.54", features = [
"tokio",
"tcp",
"quic",
"noise",
"yamux",
"gossipsub",
"kad",
"identify",
"autonat",
"relay",
"dcutr",
"dns",
"macros",
"serde",
] }
# Database
sled = "0.34"
# Compression (for snapshot download + auto-update extraction)
flate2 = "1"
tar = "0.4"
# Monitoring
prometheus = "0.13"
# Utilities
hex = "0.4"
lru = "0.12"
thiserror = "1"
clap = { version = "4", features = ["derive"] }
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
chrono = { version = "0.4", features = ["serde"] }
rand = "0.8"
anyhow = "1"
lazy_static = "1.4"
once_cell = "1"
bytes = "1"
async-trait = "0.1"
arbitrary = { version = "1.3", features = ["derive"] }
libc = "0.2"
# Memory and security utilities
crossbeam-queue = "0.3"
zeroize = { version = "1.8", features = ["derive"] }
# TUI
ratatui = "0.27"
crossterm = "0.28"
[[bin]]
name = "tsn-miner-monitor"
path = "src/bin/miner_monitor.rs"
[[bin]]
name = "fuzz_runner"
path = "fuzz/fuzz_targets/runner.rs"
[[bench]]
name = "timing_bench"
harness = false
[profile.release]
debug = true
lto = true
codegen-units = 1
[profile.fuzz]
inherits = "dev"
opt-level = 3
[dev-dependencies]
tempfile = "3"
criterion = { version = "0.5", features = ["html_reports"] }
[features]
# Feature pour activer les modules de démonstration vulnérables (TESTS UNIQUEMENT)
# ⚠️ Ces modules ne doivent JAMAIS être utilisés en production
# Utilisation : cargo build --features vulnerable-demo
vulnerable-demo = []
# Feature pour utiliser pqcrypto-sphincsplus (implémentation C optimisée)
pqcrypto-sphincsplus = []
# Feature pour désactiver certains tests (timing, sécurité, etc.)
# Utilisation : cargo test --features disabled_test
disabled_test = []