-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathCargo.toml
142 lines (121 loc) · 5.93 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
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
[package]
name = "sunset"
version = "0.2.0-alpha"
edition = "2021"
description = "A SSH library suitable for embedded and larger programs"
repository = "https://github.com/mkj/sunset"
categories = ["network-programming", "embedded", "no-std"]
license = "0BSD"
keywords = ["ssh"]
[workspace]
members = [
"sshwire-derive",
"async",
"embassy",
"embassy/demos/common",
"embassy/demos/picow",
"embassy/demos/std",
]
[dependencies]
sunset-sshwire-derive = { version = "0.1", path = "sshwire-derive" }
snafu = { version = "0.7", default-features = false, features = ["rust_1_61"] }
# TODO: check that log macro calls disappear in no_std builds
log = { version = "0.4" }
heapless = "0.8"
# allows avoiding utf8 for SSH identifier names
ascii = { version = "1.0", default-features = false }
getrandom = "0.2"
rand_core = { version = "0.6", default-features = false, features = ["getrandom"]}
ctr = { version = "0.9", features = ["zeroize"] }
aes = { version = "0.8", features = ["zeroize"] }
chacha20 = { version = "0.9", features = ["zeroize"] }
sha2 = { version = "0.10", default-features = false }
hmac = "0.12"
poly1305 = "0.8"
digest = "0.10"
signature = { version = "2.0", default-features = false }
zeroize = { version = "1", default-features = false, features = ["derive"] }
cipher = { version = "0.4", features = ["zeroize"] }
subtle = { version = "2.4", default-features = false }
# ed25519/x25519
# fork allows hashing by parts (sign/verify from sshwire), and zeroize
ed25519-dalek = { version = "2.0.0-rc.3", default-features = false, features = ["zeroize", "rand_core", "hazmat"] }
x25519-dalek = { version = "2.0.0-rc.3", default-features = false, features = ["zeroize"] }
curve25519-dalek = { version = "4.0.0", default-features = false, features = ["zeroize"] }
# p521 = { version = "0.13.2", default-features = false, features = ["ecdh", "ecdsa"] }
rsa = { version = "0.8", default-features = false, optional = true, features = ["sha2"] }
# TODO: getrandom feature is a workaround for missing ssh-key dependency with rsa. fixed in pending 0.6
ssh-key = { version = "0.5", default-features = false, optional = true, features = ["getrandom"] }
embedded-io = { version = "0.6", optional = true }
# for debug printing
pretty-hex = { version = "0.3", default-features = false }
# for non_async
futures = { version = "0.3", default-features = false }
defmt = { version = "0.3", optional = true }
[features]
std = ["snafu/std", "snafu/backtraces", "ssh-key/alloc"]
rsa = ["dep:rsa", "ssh-key/rsa"]
# allows conversion to/from OpenSSH key formats
openssh-key = ["ssh-key"]
# implements embedded_io::Error for sunset::Error
embedded-io = ["dep:embedded-io"]
defmt = ["dep:defmt"]
[dev-dependencies]
# examples want std::error
snafu = { version = "0.7", default-features = true }
anyhow = { version = "1.0" }
pretty-hex = "0.3"
simplelog = { version = "0.12", features = ["test"] }
[patch.crates-io]
curve25519-dalek = { git = "https://github.com/mkj/curve25519-dalek", branch = "sunset" }
ed25519-dalek = { git = "https://github.com/mkj/curve25519-dalek", branch = "sunset" }
x25519-dalek = { git = "https://github.com/mkj/curve25519-dalek", branch = "sunset" }
# curve25519-dalek = { path = "/home/matt/3rd/rs/crypto/curve25519-dalek/curve25519-dalek" }
# ed25519-dalek = { path = "/home/matt/3rd/rs/crypto/curve25519-dalek/ed25519-dalek" }
# x25519-dalek = { path = "/home/matt/3rd/rs/crypto/curve25519-dalek/x25519-dalek" }
embassy-executor = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-time = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
# embassy-futures = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-rp = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-usb = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
# embassy-sync = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-usb-driver = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
# for cyw43
embassy-net = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-net-driver-channel = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-net-driver = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-net-tuntap = { git = "https://github.com/embassy-rs/embassy", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
cyw43 = { git = "https://github.com/embassy-rs/embassy/", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
cyw43-pio = { git = "https://github.com/embassy-rs/embassy/", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
embassy-net-wiznet = { git = "https://github.com/embassy-rs/embassy/", rev = "90e96d281f87efdbea3a1418f5354f14386a42e8" }
# embassy-net = { path = "/home/matt/3rd/rs/embassy/embassy-net" }
# embassy-net-driver = { path = "/home/matt/3rd/rs/embassy/embassy-net-driver" }
# embassy-net-driver-channel = { path = "/home/matt/3rd/rs/embassy/embassy-net-driver-channel" }
# embassy-net-tuntap = { path = "/home/matt/3rd/rs/embassy/embassy-net-tuntap" }
# these are mostly applicable to picow, but can't hurt generally
[profile.dev]
debug = 2
debug-assertions = true
opt-level = 1
overflow-checks = true
[profile.release]
codegen-units = 1
debug = 2
debug-assertions = false
incremental = false
lto = 'fat'
opt-level = 'z'
overflow-checks = false
# do not optimize proc-macro crates = faster builds from scratch
[profile.dev.build-override]
codegen-units = 8
debug = false
debug-assertions = false
opt-level = 0
overflow-checks = false
[profile.release.build-override]
codegen-units = 8
debug = false
debug-assertions = false
opt-level = 0
overflow-checks = false