-
Notifications
You must be signed in to change notification settings - Fork 256
/
Cargo.toml
85 lines (75 loc) · 2.62 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
[package]
name = "rumqttc"
version = "0.24.0"
publish = true
description = "An efficient and robust mqtt client for your connected devices"
keywords = ["mqtt", "iot", "coap", "http"]
categories = ["network-programming"]
rust-version = "1.64.0"
edition.workspace = true
repository.workspace = true
license.workspace = true
authors.workspace = true
[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]
[features]
default = ["use-rustls"]
use-rustls = ["dep:tokio-rustls", "dep:rustls-webpki", "dep:rustls-pemfile", "dep:rustls-native-certs"]
use-native-tls = ["dep:tokio-native-tls", "dep:native-tls"]
websocket = ["dep:async-tungstenite", "dep:ws_stream_tungstenite", "dep:http"]
proxy = ["dep:async-http-proxy"]
[dependencies]
futures-util = { version = "0.3", default-features = false, features = ["std", "sink"] }
tokio = { version = "1.36", features = ["rt", "macros", "io-util", "net", "time"] }
tokio-util = { version = "0.7", features = ["codec"] }
bytes = "1.5"
log = "0.4"
flume = { version = "0.11", default-features = false, features = ["async"] }
thiserror = "2.0.8"
# Optional
# rustls
tokio-rustls = { version = "0.26.0", optional = true }
rustls-webpki = { version = "0.102.8", optional = true }
rustls-pemfile = { version = "2.2.0", optional = true }
rustls-native-certs = { version = "0.8.1", optional = true }
# websockets
async-tungstenite = { version = "0.28.0", default-features = false, features = ["tokio-rustls-native-certs"], optional = true }
ws_stream_tungstenite = { version= "0.14.0", default-features = false, features = ["tokio_io"], optional = true }
http = { version = "1.0.0", optional = true }
# native-tls
tokio-native-tls = { version = "0.3.1", optional = true }
native-tls = { version = "0.2.12", optional = true }
# url
url = { version = "2", default-features = false, optional = true }
# proxy
async-http-proxy = { version = "1.2.5", features = ["runtime-tokio", "basic-auth"], optional = true }
tokio-stream = "0.1.16"
fixedbitset = "0.5.7"
[dev-dependencies]
bincode = "1.3.3"
color-backtrace = "0.6.1"
matches = "0.1"
pretty_assertions = "1"
pretty_env_logger = "0.5"
serde = { version = "1", features = ["derive"] }
[[example]]
name = "tls"
path = "examples/tls.rs"
required-features = ["use-rustls"]
[[example]]
name = "tls_native"
path = "examples/tls_native.rs"
required-features = ["use-native-tls"]
[[example]]
name = "tls2"
path = "examples/tls2.rs"
required-features = ["use-rustls"]
[[example]]
name = "websocket"
path = "examples/websocket.rs"
required-features = ["websocket"]
[[example]]
name = "websocket_proxy"
path = "examples/websocket_proxy.rs"
required-features = ["websocket", "proxy"]