forked from smoltcp-rs/smoltcp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Cargo.toml
320 lines (277 loc) · 10.6 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
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
[package]
name = "smoltcp"
version = "0.11.0"
edition = "2021"
rust-version = "1.65"
authors = ["whitequark <[email protected]>"]
description = "A TCP/IP stack designed for bare-metal, real-time systems without a heap."
documentation = "https://docs.rs/smoltcp/"
homepage = "https://github.com/smoltcp-rs/smoltcp"
repository = "https://github.com/smoltcp-rs/smoltcp.git"
readme = "README.md"
keywords = ["ip", "tcp", "udp", "ethernet", "network"]
categories = ["embedded", "network-programming"]
license = "0BSD"
# Each example should have an explicit `[[example]]` section here to
# ensure that the correct features are enabled.
autoexamples = false
[dependencies]
managed = { version = "0.8", default-features = false, features = ["map"] }
byteorder = { version = "1.0", default-features = false }
log = { version = "0.4.4", default-features = false, optional = true }
libc = { version = "0.2.18", optional = true }
bitflags = { version = "1.0", default-features = false }
defmt = { version = "0.3", optional = true }
cfg-if = "1.0.0"
heapless = "0.8"
[dev-dependencies]
env_logger = "0.10"
getopts = "0.2"
rand = "0.8"
url = "2.0"
rstest = "0.17"
[features]
std = ["managed/std", "alloc"]
alloc = ["managed/alloc", "defmt?/alloc"]
verbose = []
defmt = ["dep:defmt", "heapless/defmt-03"]
"medium-ethernet" = ["socket"]
"medium-ip" = ["socket"]
"medium-ieee802154" = ["socket", "proto-sixlowpan"]
"phy-raw_socket" = ["std", "libc"]
"phy-tuntap_interface" = ["std", "libc", "medium-ethernet"]
"proto-ipv4" = []
"proto-ipv4-fragmentation" = ["proto-ipv4", "_proto-fragmentation"]
"proto-igmp" = ["proto-ipv4"]
"proto-dhcpv4" = ["proto-ipv4"]
"proto-ipv6" = []
"proto-ipv6-hbh" = ["proto-ipv6"]
"proto-ipv6-fragmentation" = ["proto-ipv6", "_proto-fragmentation"]
"proto-ipv6-routing" = ["proto-ipv6"]
"proto-rpl" = ["proto-ipv6-hbh", "proto-ipv6-routing"]
"proto-sixlowpan" = ["proto-ipv6"]
"proto-sixlowpan-fragmentation" = ["proto-sixlowpan", "_proto-fragmentation"]
"proto-dns" = []
"proto-ipsec" = ["proto-ipsec-ah", "proto-ipsec-esp"]
"proto-ipsec-ah" = []
"proto-ipsec-esp" = []
"socket" = []
"socket-raw" = ["socket"]
"socket-udp" = ["socket"]
"socket-tcp" = ["socket"]
"socket-icmp" = ["socket"]
"socket-dhcpv4" = ["socket", "medium-ethernet", "proto-dhcpv4"]
"socket-dns" = ["socket", "proto-dns"]
"socket-mdns" = ["socket-dns"]
# Enable Cubic TCP congestion control algorithm, and it is used as a default congestion controller.
#
# Cubic relies on double precision (`f64`) floating point operations, which may cause issues in some contexts:
#
# * Small embedded processors (such as Cortex-M0, Cortex-M1, and Cortex-M3) do not have an FPU,
# and floating point operations consume significant amounts of CPU time and Flash space.
# * Interrupt handlers should almost always avoid floating-point operations.
# * Kernel-mode code on desktop processors usually avoids FPU operations to reduce the penalty of saving and restoring FPU registers.
#
# In all these cases, `CongestionControl::Reno` is a better choice of congestion control algorithm.
"socket-tcp-cubic" = []
# Enable Reno TCP congestion control algorithm, and it is used as a default congestion controller.
"socket-tcp-reno" = []
"packetmeta-id" = []
"async" = []
default = [
"std", "log", # needed for `cargo test --no-default-features --features default` :/
"medium-ethernet", "medium-ip", "medium-ieee802154",
"phy-raw_socket", "phy-tuntap_interface",
"proto-ipv4", "proto-igmp", "proto-dhcpv4", "proto-ipv6", "proto-dns",
"proto-ipv4-fragmentation", "proto-sixlowpan-fragmentation",
"socket-raw", "socket-icmp", "socket-udp", "socket-tcp", "socket-dhcpv4", "socket-dns", "socket-mdns",
"packetmeta-id", "async"
]
# Private features
# Features starting with "_" are considered private. They should not be enabled by
# other crates, and they are not considered semver-stable.
"_proto-fragmentation" = []
# BEGIN AUTOGENERATED CONFIG FEATURES
# Generated by gen_config.py. DO NOT EDIT.
iface-max-addr-count-1 = []
iface-max-addr-count-2 = [] # Default
iface-max-addr-count-3 = []
iface-max-addr-count-4 = []
iface-max-addr-count-5 = []
iface-max-addr-count-6 = []
iface-max-addr-count-7 = []
iface-max-addr-count-8 = []
iface-max-multicast-group-count-1 = []
iface-max-multicast-group-count-2 = []
iface-max-multicast-group-count-3 = []
iface-max-multicast-group-count-4 = [] # Default
iface-max-multicast-group-count-5 = []
iface-max-multicast-group-count-6 = []
iface-max-multicast-group-count-7 = []
iface-max-multicast-group-count-8 = []
iface-max-multicast-group-count-16 = []
iface-max-multicast-group-count-32 = []
iface-max-multicast-group-count-64 = []
iface-max-multicast-group-count-128 = []
iface-max-multicast-group-count-256 = []
iface-max-multicast-group-count-512 = []
iface-max-multicast-group-count-1024 = []
iface-max-sixlowpan-address-context-count-1 = []
iface-max-sixlowpan-address-context-count-2 = []
iface-max-sixlowpan-address-context-count-3 = []
iface-max-sixlowpan-address-context-count-4 = [] # Default
iface-max-sixlowpan-address-context-count-5 = []
iface-max-sixlowpan-address-context-count-6 = []
iface-max-sixlowpan-address-context-count-7 = []
iface-max-sixlowpan-address-context-count-8 = []
iface-max-sixlowpan-address-context-count-16 = []
iface-max-sixlowpan-address-context-count-32 = []
iface-max-sixlowpan-address-context-count-64 = []
iface-max-sixlowpan-address-context-count-128 = []
iface-max-sixlowpan-address-context-count-256 = []
iface-max-sixlowpan-address-context-count-512 = []
iface-max-sixlowpan-address-context-count-1024 = []
iface-neighbor-cache-count-1 = []
iface-neighbor-cache-count-2 = []
iface-neighbor-cache-count-3 = []
iface-neighbor-cache-count-4 = [] # Default
iface-neighbor-cache-count-5 = []
iface-neighbor-cache-count-6 = []
iface-neighbor-cache-count-7 = []
iface-neighbor-cache-count-8 = []
iface-neighbor-cache-count-16 = []
iface-neighbor-cache-count-32 = []
iface-neighbor-cache-count-64 = []
iface-neighbor-cache-count-128 = []
iface-neighbor-cache-count-256 = []
iface-neighbor-cache-count-512 = []
iface-neighbor-cache-count-1024 = []
iface-max-route-count-1 = []
iface-max-route-count-2 = [] # Default
iface-max-route-count-3 = []
iface-max-route-count-4 = []
iface-max-route-count-5 = []
iface-max-route-count-6 = []
iface-max-route-count-7 = []
iface-max-route-count-8 = []
iface-max-route-count-16 = []
iface-max-route-count-32 = []
iface-max-route-count-64 = []
iface-max-route-count-128 = []
iface-max-route-count-256 = []
iface-max-route-count-512 = []
iface-max-route-count-1024 = []
fragmentation-buffer-size-256 = []
fragmentation-buffer-size-512 = []
fragmentation-buffer-size-1024 = []
fragmentation-buffer-size-1500 = [] # Default
fragmentation-buffer-size-2048 = []
fragmentation-buffer-size-4096 = []
fragmentation-buffer-size-8192 = []
fragmentation-buffer-size-16384 = []
fragmentation-buffer-size-32768 = []
fragmentation-buffer-size-65536 = []
assembler-max-segment-count-1 = []
assembler-max-segment-count-2 = []
assembler-max-segment-count-3 = []
assembler-max-segment-count-4 = [] # Default
assembler-max-segment-count-8 = []
assembler-max-segment-count-16 = []
assembler-max-segment-count-32 = []
reassembly-buffer-size-256 = []
reassembly-buffer-size-512 = []
reassembly-buffer-size-1024 = []
reassembly-buffer-size-1500 = [] # Default
reassembly-buffer-size-2048 = []
reassembly-buffer-size-4096 = []
reassembly-buffer-size-8192 = []
reassembly-buffer-size-16384 = []
reassembly-buffer-size-32768 = []
reassembly-buffer-size-65536 = []
reassembly-buffer-count-1 = [] # Default
reassembly-buffer-count-2 = []
reassembly-buffer-count-3 = []
reassembly-buffer-count-4 = []
reassembly-buffer-count-8 = []
reassembly-buffer-count-16 = []
reassembly-buffer-count-32 = []
ipv6-hbh-max-options-1 = [] # Default
ipv6-hbh-max-options-2 = []
ipv6-hbh-max-options-3 = []
ipv6-hbh-max-options-4 = []
ipv6-hbh-max-options-8 = []
ipv6-hbh-max-options-16 = []
ipv6-hbh-max-options-32 = []
dns-max-result-count-1 = [] # Default
dns-max-result-count-2 = []
dns-max-result-count-3 = []
dns-max-result-count-4 = []
dns-max-result-count-8 = []
dns-max-result-count-16 = []
dns-max-result-count-32 = []
dns-max-server-count-1 = [] # Default
dns-max-server-count-2 = []
dns-max-server-count-3 = []
dns-max-server-count-4 = []
dns-max-server-count-8 = []
dns-max-server-count-16 = []
dns-max-server-count-32 = []
dns-max-name-size-64 = []
dns-max-name-size-128 = []
dns-max-name-size-255 = [] # Default
rpl-relations-buffer-count-1 = []
rpl-relations-buffer-count-2 = []
rpl-relations-buffer-count-4 = []
rpl-relations-buffer-count-8 = []
rpl-relations-buffer-count-16 = [] # Default
rpl-relations-buffer-count-32 = []
rpl-relations-buffer-count-64 = []
rpl-relations-buffer-count-128 = []
rpl-parents-buffer-count-2 = []
rpl-parents-buffer-count-4 = []
rpl-parents-buffer-count-8 = [] # Default
rpl-parents-buffer-count-16 = []
rpl-parents-buffer-count-32 = []
# END AUTOGENERATED CONFIG FEATURES
[[example]]
name = "packet2pcap"
path = "utils/packet2pcap.rs"
required-features = ["std"]
[[example]]
name = "tcpdump"
required-features = ["std", "phy-raw_socket", "proto-ipv4"]
[[example]]
name = "httpclient"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "proto-ipv6", "socket-tcp"]
[[example]]
name = "ping"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "proto-ipv6", "socket-icmp"]
[[example]]
name = "server"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "socket-tcp", "socket-udp"]
[[example]]
name = "client"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "socket-tcp", "socket-udp"]
[[example]]
name = "loopback"
required-features = ["log", "medium-ethernet", "proto-ipv4", "socket-tcp"]
[[example]]
name = "multicast"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "proto-igmp", "socket-udp"]
[[example]]
name = "benchmark"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "socket-raw", "socket-udp"]
[[example]]
name = "dhcp_client"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "proto-dhcpv4", "socket-raw"]
[[example]]
name = "sixlowpan"
required-features = ["std", "medium-ieee802154", "phy-raw_socket", "proto-sixlowpan", "proto-sixlowpan-fragmentation", "socket-udp"]
[[example]]
name = "sixlowpan_benchmark"
required-features = ["std", "medium-ieee802154", "phy-raw_socket", "proto-sixlowpan", "proto-sixlowpan-fragmentation", "socket-udp"]
[[example]]
name = "dns"
required-features = ["std", "medium-ethernet", "medium-ip", "phy-tuntap_interface", "proto-ipv4", "socket-dns"]
[profile.release]
debug = 2