forked from DataDog/pup
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
157 lines (133 loc) · 4.65 KB
/
Copy pathCargo.toml
File metadata and controls
157 lines (133 loc) · 4.65 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 = "pup"
version = "0.39.0"
edition = "2021"
rust-version = "1.93.1"
publish = false
[lib]
name = "pup_wasm"
path = "src/lib.rs"
crate-type = ["cdylib", "rlib"]
[features]
default = ["native"]
native = [
"dep:datadog-api-client",
"datadog-api-client/native-tls",
"datadog-api-client/zstd",
"datadog-api-client/retry",
"dep:keyring",
"dep:dirs",
"dep:open",
"dep:task-local-extensions",
"dep:sha2",
"dep:base64",
"dep:rand",
"dep:url",
"dep:aes-gcm",
"dep:uuid",
"dep:chrono",
"dep:regex",
"dep:clap",
"dep:clap_complete",
"tokio/full",
"comfy-table/tty",
"dep:tokio-tungstenite",
"dep:yamux",
"dep:russh",
"dep:ssh-key",
"dep:futures",
"dep:tokio-util",
]
wasi = [
"dep:datadog-api-client",
"datadog-api-client/rustls-tls",
"datadog-api-client/retry",
"dep:sha2",
"dep:base64",
"dep:rand",
"dep:url",
"dep:aes-gcm",
"dep:uuid",
"dep:chrono",
"dep:regex",
"dep:clap",
"dep:clap_complete",
"tokio/rt",
"tokio/macros",
"tokio/time",
]
vendored-openssl = ["dep:openssl"]
browser = [
"dep:datadog-api-client",
"dep:wasm-bindgen",
"dep:wasm-bindgen-futures",
"dep:js-sys",
"dep:web-sys",
"dep:serde-wasm-bindgen",
"dep:getrandom",
]
[dependencies]
# CLI (optional — not needed for browser WASM library)
clap = { version = "4", features = ["derive"], optional = true }
clap_complete = { version = "4", optional = true }
# Async runtime (features selected by native/wasi feature flags)
tokio = { version = "1", default-features = false }
# Serialization
serde = { version = "1", features = ["derive"] }
serde_json = { version = "1", features = ["preserve_order"] }
serde_norway = "0.9"
# HTTP (version-matched to DD client for native; used directly for WASI/browser)
reqwest = { version = "0.11", features = ["json", "stream"] }
# Error handling
anyhow = "1"
# UUID parsing (version-matched to DD client)
uuid = { version = "1", features = ["v4"], optional = true }
# Time
chrono = { version = "0.4", optional = true }
regex = { version = "1", optional = true }
# Output formatting (tty feature disabled for WASM — no crossterm)
comfy-table = { version = "7", default-features = false }
# Auth — OAuth2 PKCE + token storage (optional — not needed for browser)
sha2 = { version = "0.10", optional = true }
base64 = { version = "0.22", optional = true }
rand = { version = "0.9", optional = true }
url = { version = "2", optional = true }
# Vendored OpenSSL for cross-compilation (optional — only for CI cross-builds)
openssl = { version = "0.10", features = ["vendored"], optional = true }
# Crypto for fallback storage (optional — not needed for browser)
aes-gcm = { version = "0.10", optional = true }
# ---- Native-only dependencies ----
# Synthetics tunnel
tokio-tungstenite = { version = "0.29", features = ["native-tls"], optional = true }
yamux = { version = "0.13", optional = true }
russh = { version = "0.58", optional = true }
ssh-key = { version = "0.6", features = ["p256", "std"], optional = true }
futures = { version = "0.3", optional = true }
tokio-util = { version = "0.7", features = ["compat", "io"], optional = true }
# Datadog API client — wasm32 build support merged in f3ff218c
# Use default-features = false; feature sets are activated per-target via features above
datadog-api-client = { git = "https://github.com/DataDog/datadog-api-client-rust", rev = "f3ff218ce6456fd859652f0b1f84cc307637f115", optional = true, default-features = false }
# HTTP middleware (version-matched to DD client; compiles on all targets)
reqwest-middleware = "0.2"
async-trait = "0.1"
# task-local-extensions is used only by the native bearer-token middleware impl
task-local-extensions = { version = "0.1", optional = true }
# OS keychain for token storage
keyring = { version = "3", features = ["apple-native", "linux-native"], optional = true }
# XDG config directory resolution
dirs = { version = "6", optional = true }
# Browser opening for OAuth login
open = { version = "5", optional = true }
# ---- Browser WASM dependencies (wasm-bindgen) ----
wasm-bindgen = { version = "0.2", optional = true }
wasm-bindgen-futures = { version = "0.4", optional = true }
js-sys = { version = "0.3", optional = true }
web-sys = { version = "0.3", features = ["Window", "Storage"], optional = true }
serde-wasm-bindgen = { version = "0.6", optional = true }
# RNG support in browser WASM (getrandom 0.2 with JS backend)
getrandom = { version = "0.2", features = ["js"], optional = true }
[target.'cfg(target_os = "macos")'.dependencies]
security-framework = "3.7"
security-framework-sys = "2.17"
[dev-dependencies]
mockito = "1"