-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathCargo.toml
More file actions
110 lines (94 loc) · 3.51 KB
/
Copy pathCargo.toml
File metadata and controls
110 lines (94 loc) · 3.51 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
[workspace]
members = ["benchmarks", "fuzz"]
resolver = "3"
[workspace.package]
edition = "2024"
rust-version = "1.85.0"
license = "Apache-2.0"
homepage = "https://github.com/koushiro/rust-bips"
repository = "https://github.com/koushiro/rust-bips"
[package]
name = "bip0032"
version = "0.0.2"
authors = ["koushiro <koushiro.cqx@gmail.com>"]
edition.workspace = true
rust-version.workspace = true
license.workspace = true
homepage.workspace = true
repository.workspace = true
description = "Another Rust implementation of BIP-0032 standard"
readme = "README.md"
documentation = "https://docs.rs/bip0032"
keywords = ["bip32", "slip10", "bitcoin", "crypto"]
categories = ["cryptography", "no-std"]
[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]
[features]
default = ["std", "k256"]
std = [
"anyhow/std",
"bs58/std",
"hmac/std",
"ripemd/std",
"sha2/std",
"zeroize/std",
"k256?/std",
"secp256k1?/std",
"libsecp256k1?/std",
"p256?/std",
"ed25519-dalek?/std",
]
# BIP-0032 (secp256k1)
k256 = ["k256/arithmetic"]
secp256k1 = ["dep:secp256k1"]
libsecp256k1 = ["dep:libsecp256k1"]
# Optional SLIP-0010 extension (support secp256k1/nist256p1/ed25519 curve)
slip10 = []
p256 = ["slip10", "p256/arithmetic"]
ed25519-dalek = ["slip10", "dep:ed25519-dalek"]
[dependencies]
anyhow = { version = "1.0", default-features = false }
bs58 = { version = "0.5", default-features = false, features = ["alloc", "check"] }
hmac = { version = "0.12", default-features = false }
ripemd = { version = "0.1", default-features = false }
sha2 = { version = "0.10", default-features = false }
zeroize = { version = "1.8", default-features = false }
###############################################################################
# secp256k1 libraries
###############################################################################
# https://github.com/RustCrypto/elliptic-curves/tree/master/k256
k256 = { version = "0.13", default-features = false, features = ["alloc"], optional = true }
# https://github.com/bitcoin-core/secp256k1
secp256k1 = { version = "0.31", default-features = false, features = ["alloc"], optional = true }
# https://github.com/paritytech/libsecp256k1
# NOTE: libsecp256k1 crate is no longer maintained
libsecp256k1 = { version = "0.7", default-features = false, features = ["static-context"], optional = true }
###############################################################################
# nist256p1 libraries (SLIP-0010 extension)
###############################################################################
# https://github.com/RustCrypto/elliptic-curves/tree/master/p256
p256 = { version = "0.13", default-features = false, features = ["alloc"], optional = true }
###############################################################################
# ed25519 libraries (SLIP-0010 extension)
###############################################################################
# https://github.com/dalek-cryptography/curve25519-dalek/tree/main/ed25519-dalek
ed25519-dalek = { version = "2.2.0", default-features = false, features = ["alloc"], optional = true }
[dev-dependencies]
const-hex = "1.12.0"
[[test]]
name = "bip32"
path = "tests/bip32.rs"
required-features = ["k256"]
[[test]]
name = "slip10-secp256k1"
path = "tests/slip10/secp256k1.rs"
required-features = ["slip10", "k256"]
[[test]]
name = "slip10-nist256p1"
path = "tests/slip10/nist256p1.rs"
required-features = ["slip10", "p256"]
[[test]]
name = "slip10-ed25519"
path = "tests/slip10/ed25519.rs"
required-features = ["slip10", "ed25519-dalek"]