diff options
author | FxQnLr <[email protected]> | 2024-02-12 16:00:45 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2024-02-12 16:00:45 +0100 |
commit | c663810817183c8f92a4279236ca84d271365088 (patch) | |
tree | 0c844cc883e5e474a9cdad30004108852f13f903 | |
parent | da6367885d31698464e1bec122e3e673974427c6 (diff) | |
parent | 9139d76cb1cf462820b2ddfa80d9a8d55bb30996 (diff) | |
download | webol-c663810817183c8f92a4279236ca84d271365088.tar webol-c663810817183c8f92a4279236ca84d271365088.tar.gz webol-c663810817183c8f92a4279236ca84d271365088.zip |
Merge pull request #14 from FxQnLr/axum7
Axum7 & config changes
-rw-r--r-- | .github/workflows/pull_request.yml | 45 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Cargo.lock | 909 | ||||
-rw-r--r-- | Cargo.toml | 30 | ||||
-rw-r--r-- | Dockerfile | 15 | ||||
-rw-r--r-- | README.md | 4 | ||||
-rw-r--r-- | src/auth.rs | 24 | ||||
-rw-r--r-- | src/config.rs | 32 | ||||
-rw-r--r-- | src/db.rs | 16 | ||||
-rw-r--r-- | src/error.rs | 8 | ||||
-rw-r--r-- | src/main.rs | 41 | ||||
-rw-r--r-- | src/routes/device.rs | 28 | ||||
-rw-r--r-- | src/routes/start.rs | 76 | ||||
-rw-r--r-- | src/routes/status.rs | 2 | ||||
-rw-r--r-- | src/services/ping.rs | 84 | ||||
-rw-r--r-- | src/wol.rs | 14 |
16 files changed, 789 insertions, 540 deletions
diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 279e16d..7196d4e 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml | |||
@@ -1,35 +1,32 @@ | |||
1 | name: check | 1 | name: check |
2 | 2 | ||
3 | on: | 3 | on: [ pull_request, workflow_dispatch ] |
4 | pull_request: | ||
5 | branches: [ "main" ] | ||
6 | workflow_dispatch: | ||
7 | 4 | ||
8 | env: | 5 | env: |
9 | SCCACHE_GHA_ENABLED: "true" | 6 | SCCACHE_GHA_ENABLED: "true" |
10 | RUSTC_WRAPPER: "sccache" | 7 | RUSTC_WRAPPER: "sccache" |
11 | SQLX_OFFLINE: "true" | 8 | SQLX_OFFLINE: "true" |
12 | CARGO_TERM_COLOR: always | 9 | CARGO_TERM_COLOR: always |
13 | 10 | ||
14 | jobs: | 11 | jobs: |
15 | check: | 12 | check: |
16 | runs-on: ubuntu-latest | 13 | runs-on: ubuntu-latest |
17 | steps: | 14 | steps: |
18 | - name: Run sccache-cache | 15 | - name: Run sccache-cache |
19 | uses: mozilla-actions/[email protected] | 16 | uses: mozilla-actions/[email protected] |
20 | 17 | ||
21 | - uses: actions/checkout@v4 | 18 | - uses: actions/checkout@v4 |
22 | 19 | ||
23 | - run: cargo check | 20 | - run: cargo check |
24 | - run: cargo clippy | 21 | - run: cargo clippy |
25 | 22 | ||
26 | check-release: | 23 | check-release: |
27 | runs-on: ubuntu-latest | 24 | runs-on: ubuntu-latest |
28 | steps: | 25 | steps: |
29 | - name: Run sccache-cache | 26 | - name: Run sccache-cache |
30 | uses: mozilla-actions/[email protected] | 27 | uses: mozilla-actions/[email protected] |
31 | 28 | ||
32 | - uses: actions/checkout@v4 | 29 | - uses: actions/checkout@v4 |
33 | 30 | ||
34 | - run: cargo check --release | 31 | - run: cargo check --release |
35 | - run: cargo clippy --release \ No newline at end of file | 32 | - run: cargo clippy --release |
@@ -11,5 +11,6 @@ target/ | |||
11 | 11 | ||
12 | *.sqlite* | 12 | *.sqlite* |
13 | .env | 13 | .env |
14 | config.* | ||
14 | 15 | ||
15 | .idea | 16 | .idea |
@@ -19,20 +19,9 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" | |||
19 | 19 | ||
20 | [[package]] | 20 | [[package]] |
21 | name = "ahash" | 21 | name = "ahash" |
22 | version = "0.7.7" | 22 | version = "0.8.8" |
23 | source = "registry+https://github.com/rust-lang/crates.io-index" | 23 | source = "registry+https://github.com/rust-lang/crates.io-index" |
24 | checksum = "5a824f2aa7e75a0c98c5a504fceb80649e9c35265d44525b5f94de4771a395cd" | 24 | checksum = "42cd52102d3df161c77a887b608d7a4897d7cc112886a9537b738a887a03aaff" |
25 | dependencies = [ | ||
26 | "getrandom", | ||
27 | "once_cell", | ||
28 | "version_check", | ||
29 | ] | ||
30 | |||
31 | [[package]] | ||
32 | name = "ahash" | ||
33 | version = "0.8.6" | ||
34 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
35 | checksum = "91429305e9f0a25f6205c5b8e0d2db09e0708a7a6df0f42212bb56c32c8ac97a" | ||
36 | dependencies = [ | 25 | dependencies = [ |
37 | "cfg-if", | 26 | "cfg-if", |
38 | "getrandom", | 27 | "getrandom", |
@@ -58,13 +47,13 @@ checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" | |||
58 | 47 | ||
59 | [[package]] | 48 | [[package]] |
60 | name = "async-trait" | 49 | name = "async-trait" |
61 | version = "0.1.74" | 50 | version = "0.1.77" |
62 | source = "registry+https://github.com/rust-lang/crates.io-index" | 51 | source = "registry+https://github.com/rust-lang/crates.io-index" |
63 | checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" | 52 | checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" |
64 | dependencies = [ | 53 | dependencies = [ |
65 | "proc-macro2", | 54 | "proc-macro2", |
66 | "quote", | 55 | "quote", |
67 | "syn 2.0.38", | 56 | "syn 2.0.48", |
68 | ] | 57 | ] |
69 | 58 | ||
70 | [[package]] | 59 | [[package]] |
@@ -77,6 +66,16 @@ dependencies = [ | |||
77 | ] | 66 | ] |
78 | 67 | ||
79 | [[package]] | 68 | [[package]] |
69 | name = "atomic-write-file" | ||
70 | version = "0.1.2" | ||
71 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
72 | checksum = "edcdbedc2236483ab103a53415653d6b4442ea6141baf1ffa85df29635e88436" | ||
73 | dependencies = [ | ||
74 | "nix", | ||
75 | "rand", | ||
76 | ] | ||
77 | |||
78 | [[package]] | ||
80 | name = "autocfg" | 79 | name = "autocfg" |
81 | version = "1.1.0" | 80 | version = "1.1.0" |
82 | source = "registry+https://github.com/rust-lang/crates.io-index" | 81 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -84,20 +83,20 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" | |||
84 | 83 | ||
85 | [[package]] | 84 | [[package]] |
86 | name = "axum" | 85 | name = "axum" |
87 | version = "0.6.20" | 86 | version = "0.7.4" |
88 | source = "registry+https://github.com/rust-lang/crates.io-index" | 87 | source = "registry+https://github.com/rust-lang/crates.io-index" |
89 | checksum = "3b829e4e32b91e643de6eafe82b1d90675f5874230191a4ffbc1b336dec4d6bf" | 88 | checksum = "1236b4b292f6c4d6dc34604bb5120d85c3fe1d1aa596bd5cc52ca054d13e7b9e" |
90 | dependencies = [ | 89 | dependencies = [ |
91 | "async-trait", | 90 | "async-trait", |
92 | "axum-core", | 91 | "axum-core", |
93 | "base64 0.21.5", | 92 | "base64", |
94 | "bitflags 1.3.2", | ||
95 | "bytes", | 93 | "bytes", |
96 | "futures-util", | 94 | "futures-util", |
97 | "headers", | ||
98 | "http", | 95 | "http", |
99 | "http-body", | 96 | "http-body", |
97 | "http-body-util", | ||
100 | "hyper", | 98 | "hyper", |
99 | "hyper-util", | ||
101 | "itoa", | 100 | "itoa", |
102 | "matchit", | 101 | "matchit", |
103 | "memchr", | 102 | "memchr", |
@@ -116,35 +115,40 @@ dependencies = [ | |||
116 | "tower", | 115 | "tower", |
117 | "tower-layer", | 116 | "tower-layer", |
118 | "tower-service", | 117 | "tower-service", |
118 | "tracing", | ||
119 | ] | 119 | ] |
120 | 120 | ||
121 | [[package]] | 121 | [[package]] |
122 | name = "axum-core" | 122 | name = "axum-core" |
123 | version = "0.3.4" | 123 | version = "0.4.3" |
124 | source = "registry+https://github.com/rust-lang/crates.io-index" | 124 | source = "registry+https://github.com/rust-lang/crates.io-index" |
125 | checksum = "759fa577a247914fd3f7f76d62972792636412fbfd634cd452f6a385a74d2d2c" | 125 | checksum = "a15c63fd72d41492dc4f497196f5da1fb04fb7529e631d73630d1b491e47a2e3" |
126 | dependencies = [ | 126 | dependencies = [ |
127 | "async-trait", | 127 | "async-trait", |
128 | "bytes", | 128 | "bytes", |
129 | "futures-util", | 129 | "futures-util", |
130 | "http", | 130 | "http", |
131 | "http-body", | 131 | "http-body", |
132 | "http-body-util", | ||
132 | "mime", | 133 | "mime", |
134 | "pin-project-lite", | ||
133 | "rustversion", | 135 | "rustversion", |
136 | "sync_wrapper", | ||
134 | "tower-layer", | 137 | "tower-layer", |
135 | "tower-service", | 138 | "tower-service", |
139 | "tracing", | ||
136 | ] | 140 | ] |
137 | 141 | ||
138 | [[package]] | 142 | [[package]] |
139 | name = "axum-macros" | 143 | name = "axum-macros" |
140 | version = "0.3.8" | 144 | version = "0.4.1" |
141 | source = "registry+https://github.com/rust-lang/crates.io-index" | 145 | source = "registry+https://github.com/rust-lang/crates.io-index" |
142 | checksum = "cdca6a10ecad987bda04e95606ef85a5417dcaac1a78455242d72e031e2b6b62" | 146 | checksum = "00c055ee2d014ae5981ce1016374e8213682aa14d9bf40e48ab48b5f3ef20eaa" |
143 | dependencies = [ | 147 | dependencies = [ |
144 | "heck", | 148 | "heck", |
145 | "proc-macro2", | 149 | "proc-macro2", |
146 | "quote", | 150 | "quote", |
147 | "syn 2.0.38", | 151 | "syn 2.0.48", |
148 | ] | 152 | ] |
149 | 153 | ||
150 | [[package]] | 154 | [[package]] |
@@ -164,15 +168,9 @@ dependencies = [ | |||
164 | 168 | ||
165 | [[package]] | 169 | [[package]] |
166 | name = "base64" | 170 | name = "base64" |
167 | version = "0.13.1" | 171 | version = "0.21.7" |
168 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
169 | checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" | ||
170 | |||
171 | [[package]] | ||
172 | name = "base64" | ||
173 | version = "0.21.5" | ||
174 | source = "registry+https://github.com/rust-lang/crates.io-index" | 172 | source = "registry+https://github.com/rust-lang/crates.io-index" |
175 | checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" | 173 | checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" |
176 | 174 | ||
177 | [[package]] | 175 | [[package]] |
178 | name = "base64ct" | 176 | name = "base64ct" |
@@ -188,9 +186,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" | |||
188 | 186 | ||
189 | [[package]] | 187 | [[package]] |
190 | name = "bitflags" | 188 | name = "bitflags" |
191 | version = "2.4.1" | 189 | version = "2.4.2" |
192 | source = "registry+https://github.com/rust-lang/crates.io-index" | 190 | source = "registry+https://github.com/rust-lang/crates.io-index" |
193 | checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" | 191 | checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" |
194 | dependencies = [ | 192 | dependencies = [ |
195 | "serde", | 193 | "serde", |
196 | ] | 194 | ] |
@@ -232,12 +230,40 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
232 | checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" | 230 | checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" |
233 | 231 | ||
234 | [[package]] | 232 | [[package]] |
233 | name = "color-eyre" | ||
234 | version = "0.6.2" | ||
235 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
236 | checksum = "5a667583cca8c4f8436db8de46ea8233c42a7d9ae424a82d338f2e4675229204" | ||
237 | dependencies = [ | ||
238 | "backtrace", | ||
239 | "color-spantrace", | ||
240 | "eyre", | ||
241 | "indenter", | ||
242 | "once_cell", | ||
243 | "owo-colors", | ||
244 | "tracing-error", | ||
245 | ] | ||
246 | |||
247 | [[package]] | ||
248 | name = "color-spantrace" | ||
249 | version = "0.2.1" | ||
250 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
251 | checksum = "cd6be1b2a7e382e2b98b43b2adcca6bb0e465af0bdd38123873ae61eb17a72c2" | ||
252 | dependencies = [ | ||
253 | "once_cell", | ||
254 | "owo-colors", | ||
255 | "tracing-core", | ||
256 | "tracing-error", | ||
257 | ] | ||
258 | |||
259 | [[package]] | ||
235 | name = "config" | 260 | name = "config" |
236 | version = "0.13.3" | 261 | version = "0.14.0" |
237 | source = "registry+https://github.com/rust-lang/crates.io-index" | 262 | source = "registry+https://github.com/rust-lang/crates.io-index" |
238 | checksum = "d379af7f68bfc21714c6c7dea883544201741d2ce8274bb12fa54f89507f52a7" | 263 | checksum = "7328b20597b53c2454f0b1919720c25c7339051c02b72b7e05409e00b14132be" |
239 | dependencies = [ | 264 | dependencies = [ |
240 | "async-trait", | 265 | "async-trait", |
266 | "convert_case", | ||
241 | "json5", | 267 | "json5", |
242 | "lazy_static", | 268 | "lazy_static", |
243 | "nom", | 269 | "nom", |
@@ -252,15 +278,44 @@ dependencies = [ | |||
252 | 278 | ||
253 | [[package]] | 279 | [[package]] |
254 | name = "const-oid" | 280 | name = "const-oid" |
255 | version = "0.9.5" | 281 | version = "0.9.6" |
256 | source = "registry+https://github.com/rust-lang/crates.io-index" | 282 | source = "registry+https://github.com/rust-lang/crates.io-index" |
257 | checksum = "28c122c3980598d243d63d9a704629a2d748d101f278052ff068be5a4423ab6f" | 283 | checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" |
284 | |||
285 | [[package]] | ||
286 | name = "const-random" | ||
287 | version = "0.1.17" | ||
288 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
289 | checksum = "5aaf16c9c2c612020bcfd042e170f6e32de9b9d75adb5277cdbbd2e2c8c8299a" | ||
290 | dependencies = [ | ||
291 | "const-random-macro", | ||
292 | ] | ||
293 | |||
294 | [[package]] | ||
295 | name = "const-random-macro" | ||
296 | version = "0.1.16" | ||
297 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
298 | checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e" | ||
299 | dependencies = [ | ||
300 | "getrandom", | ||
301 | "once_cell", | ||
302 | "tiny-keccak", | ||
303 | ] | ||
304 | |||
305 | [[package]] | ||
306 | name = "convert_case" | ||
307 | version = "0.6.0" | ||
308 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
309 | checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" | ||
310 | dependencies = [ | ||
311 | "unicode-segmentation", | ||
312 | ] | ||
258 | 313 | ||
259 | [[package]] | 314 | [[package]] |
260 | name = "cpufeatures" | 315 | name = "cpufeatures" |
261 | version = "0.2.11" | 316 | version = "0.2.12" |
262 | source = "registry+https://github.com/rust-lang/crates.io-index" | 317 | source = "registry+https://github.com/rust-lang/crates.io-index" |
263 | checksum = "ce420fe07aecd3e67c5f910618fe65e94158f6dcc0adf44e00d69ce2bdfe0fd0" | 318 | checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" |
264 | dependencies = [ | 319 | dependencies = [ |
265 | "libc", | 320 | "libc", |
266 | ] | 321 | ] |
@@ -276,28 +331,30 @@ dependencies = [ | |||
276 | 331 | ||
277 | [[package]] | 332 | [[package]] |
278 | name = "crc-catalog" | 333 | name = "crc-catalog" |
279 | version = "2.3.0" | 334 | version = "2.4.0" |
280 | source = "registry+https://github.com/rust-lang/crates.io-index" | 335 | source = "registry+https://github.com/rust-lang/crates.io-index" |
281 | checksum = "4939f9ed1444bd8c896d37f3090012fa6e7834fe84ef8c9daa166109515732f9" | 336 | checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" |
282 | 337 | ||
283 | [[package]] | 338 | [[package]] |
284 | name = "crossbeam-queue" | 339 | name = "crossbeam-queue" |
285 | version = "0.3.8" | 340 | version = "0.3.11" |
286 | source = "registry+https://github.com/rust-lang/crates.io-index" | 341 | source = "registry+https://github.com/rust-lang/crates.io-index" |
287 | checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" | 342 | checksum = "df0346b5d5e76ac2fe4e327c5fd1118d6be7c51dfb18f9b7922923f287471e35" |
288 | dependencies = [ | 343 | dependencies = [ |
289 | "cfg-if", | ||
290 | "crossbeam-utils", | 344 | "crossbeam-utils", |
291 | ] | 345 | ] |
292 | 346 | ||
293 | [[package]] | 347 | [[package]] |
294 | name = "crossbeam-utils" | 348 | name = "crossbeam-utils" |
295 | version = "0.8.16" | 349 | version = "0.8.19" |
296 | source = "registry+https://github.com/rust-lang/crates.io-index" | 350 | source = "registry+https://github.com/rust-lang/crates.io-index" |
297 | checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" | 351 | checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" |
298 | dependencies = [ | 352 | |
299 | "cfg-if", | 353 | [[package]] |
300 | ] | 354 | name = "crunchy" |
355 | version = "0.2.2" | ||
356 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
357 | checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" | ||
301 | 358 | ||
302 | [[package]] | 359 | [[package]] |
303 | name = "crypto-common" | 360 | name = "crypto-common" |
@@ -316,7 +373,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
316 | checksum = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" | 373 | checksum = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" |
317 | dependencies = [ | 374 | dependencies = [ |
318 | "cfg-if", | 375 | "cfg-if", |
319 | "hashbrown 0.14.2", | 376 | "hashbrown 0.14.3", |
320 | "lock_api", | 377 | "lock_api", |
321 | "once_cell", | 378 | "once_cell", |
322 | "parking_lot_core", | 379 | "parking_lot_core", |
@@ -324,9 +381,9 @@ dependencies = [ | |||
324 | 381 | ||
325 | [[package]] | 382 | [[package]] |
326 | name = "data-encoding" | 383 | name = "data-encoding" |
327 | version = "2.4.0" | 384 | version = "2.5.0" |
328 | source = "registry+https://github.com/rust-lang/crates.io-index" | 385 | source = "registry+https://github.com/rust-lang/crates.io-index" |
329 | checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" | 386 | checksum = "7e962a19be5cfc3f3bf6dd8f61eb50107f356ad6270fbb3ed41476571db78be5" |
330 | 387 | ||
331 | [[package]] | 388 | [[package]] |
332 | name = "der" | 389 | name = "der" |
@@ -341,9 +398,9 @@ dependencies = [ | |||
341 | 398 | ||
342 | [[package]] | 399 | [[package]] |
343 | name = "deranged" | 400 | name = "deranged" |
344 | version = "0.3.9" | 401 | version = "0.3.11" |
345 | source = "registry+https://github.com/rust-lang/crates.io-index" | 402 | source = "registry+https://github.com/rust-lang/crates.io-index" |
346 | checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" | 403 | checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" |
347 | dependencies = [ | 404 | dependencies = [ |
348 | "powerfmt", | 405 | "powerfmt", |
349 | ] | 406 | ] |
@@ -362,9 +419,12 @@ dependencies = [ | |||
362 | 419 | ||
363 | [[package]] | 420 | [[package]] |
364 | name = "dlv-list" | 421 | name = "dlv-list" |
365 | version = "0.3.0" | 422 | version = "0.5.2" |
366 | source = "registry+https://github.com/rust-lang/crates.io-index" | 423 | source = "registry+https://github.com/rust-lang/crates.io-index" |
367 | checksum = "0688c2a7f92e427f44895cd63841bff7b29f8d7a1648b9e7e07a4a365b2e1257" | 424 | checksum = "442039f5147480ba31067cb00ada1adae6892028e40e45fc5de7b7df6dcc1b5f" |
425 | dependencies = [ | ||
426 | "const-random", | ||
427 | ] | ||
368 | 428 | ||
369 | [[package]] | 429 | [[package]] |
370 | name = "dotenvy" | 430 | name = "dotenvy" |
@@ -374,9 +434,9 @@ checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" | |||
374 | 434 | ||
375 | [[package]] | 435 | [[package]] |
376 | name = "either" | 436 | name = "either" |
377 | version = "1.9.0" | 437 | version = "1.10.0" |
378 | source = "registry+https://github.com/rust-lang/crates.io-index" | 438 | source = "registry+https://github.com/rust-lang/crates.io-index" |
379 | checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" | 439 | checksum = "11157ac094ffbdde99aa67b23417ebdd801842852b500e395a45a9c0aac03e4a" |
380 | dependencies = [ | 440 | dependencies = [ |
381 | "serde", | 441 | "serde", |
382 | ] | 442 | ] |
@@ -389,12 +449,12 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" | |||
389 | 449 | ||
390 | [[package]] | 450 | [[package]] |
391 | name = "errno" | 451 | name = "errno" |
392 | version = "0.3.5" | 452 | version = "0.3.8" |
393 | source = "registry+https://github.com/rust-lang/crates.io-index" | 453 | source = "registry+https://github.com/rust-lang/crates.io-index" |
394 | checksum = "ac3e13f66a2f95e32a39eaa81f6b95d42878ca0e1db0c7543723dfe12557e860" | 454 | checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" |
395 | dependencies = [ | 455 | dependencies = [ |
396 | "libc", | 456 | "libc", |
397 | "windows-sys", | 457 | "windows-sys 0.52.0", |
398 | ] | 458 | ] |
399 | 459 | ||
400 | [[package]] | 460 | [[package]] |
@@ -405,7 +465,7 @@ checksum = "136d1b5283a1ab77bd9257427ffd09d8667ced0570b6f938942bc7568ed5b943" | |||
405 | dependencies = [ | 465 | dependencies = [ |
406 | "cfg-if", | 466 | "cfg-if", |
407 | "home", | 467 | "home", |
408 | "windows-sys", | 468 | "windows-sys 0.48.0", |
409 | ] | 469 | ] |
410 | 470 | ||
411 | [[package]] | 471 | [[package]] |
@@ -415,6 +475,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
415 | checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" | 475 | checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" |
416 | 476 | ||
417 | [[package]] | 477 | [[package]] |
478 | name = "eyre" | ||
479 | version = "0.6.12" | ||
480 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
481 | checksum = "7cd915d99f24784cdc19fd37ef22b97e3ff0ae756c7e492e9fbfe897d61e2aec" | ||
482 | dependencies = [ | ||
483 | "indenter", | ||
484 | "once_cell", | ||
485 | ] | ||
486 | |||
487 | [[package]] | ||
418 | name = "fastrand" | 488 | name = "fastrand" |
419 | version = "2.0.1" | 489 | version = "2.0.1" |
420 | source = "registry+https://github.com/rust-lang/crates.io-index" | 490 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -445,18 +515,18 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" | |||
445 | 515 | ||
446 | [[package]] | 516 | [[package]] |
447 | name = "form_urlencoded" | 517 | name = "form_urlencoded" |
448 | version = "1.2.0" | 518 | version = "1.2.1" |
449 | source = "registry+https://github.com/rust-lang/crates.io-index" | 519 | source = "registry+https://github.com/rust-lang/crates.io-index" |
450 | checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" | 520 | checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" |
451 | dependencies = [ | 521 | dependencies = [ |
452 | "percent-encoding", | 522 | "percent-encoding", |
453 | ] | 523 | ] |
454 | 524 | ||
455 | [[package]] | 525 | [[package]] |
456 | name = "futures-channel" | 526 | name = "futures-channel" |
457 | version = "0.3.29" | 527 | version = "0.3.30" |
458 | source = "registry+https://github.com/rust-lang/crates.io-index" | 528 | source = "registry+https://github.com/rust-lang/crates.io-index" |
459 | checksum = "ff4dd66668b557604244583e3e1e1eada8c5c2e96a6d0d6653ede395b78bbacb" | 529 | checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" |
460 | dependencies = [ | 530 | dependencies = [ |
461 | "futures-core", | 531 | "futures-core", |
462 | "futures-sink", | 532 | "futures-sink", |
@@ -464,15 +534,15 @@ dependencies = [ | |||
464 | 534 | ||
465 | [[package]] | 535 | [[package]] |
466 | name = "futures-core" | 536 | name = "futures-core" |
467 | version = "0.3.29" | 537 | version = "0.3.30" |
468 | source = "registry+https://github.com/rust-lang/crates.io-index" | 538 | source = "registry+https://github.com/rust-lang/crates.io-index" |
469 | checksum = "eb1d22c66e66d9d72e1758f0bd7d4fd0bee04cad842ee34587d68c07e45d088c" | 539 | checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" |
470 | 540 | ||
471 | [[package]] | 541 | [[package]] |
472 | name = "futures-executor" | 542 | name = "futures-executor" |
473 | version = "0.3.29" | 543 | version = "0.3.30" |
474 | source = "registry+https://github.com/rust-lang/crates.io-index" | 544 | source = "registry+https://github.com/rust-lang/crates.io-index" |
475 | checksum = "0f4fb8693db0cf099eadcca0efe2a5a22e4550f98ed16aba6c48700da29597bc" | 545 | checksum = "a576fc72ae164fca6b9db127eaa9a9dda0d61316034f33a0a0d4eda41f02b01d" |
476 | dependencies = [ | 546 | dependencies = [ |
477 | "futures-core", | 547 | "futures-core", |
478 | "futures-task", | 548 | "futures-task", |
@@ -492,27 +562,27 @@ dependencies = [ | |||
492 | 562 | ||
493 | [[package]] | 563 | [[package]] |
494 | name = "futures-io" | 564 | name = "futures-io" |
495 | version = "0.3.29" | 565 | version = "0.3.30" |
496 | source = "registry+https://github.com/rust-lang/crates.io-index" | 566 | source = "registry+https://github.com/rust-lang/crates.io-index" |
497 | checksum = "8bf34a163b5c4c52d0478a4d757da8fb65cabef42ba90515efee0f6f9fa45aaa" | 567 | checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" |
498 | 568 | ||
499 | [[package]] | 569 | [[package]] |
500 | name = "futures-sink" | 570 | name = "futures-sink" |
501 | version = "0.3.29" | 571 | version = "0.3.30" |
502 | source = "registry+https://github.com/rust-lang/crates.io-index" | 572 | source = "registry+https://github.com/rust-lang/crates.io-index" |
503 | checksum = "e36d3378ee38c2a36ad710c5d30c2911d752cb941c00c72dbabfb786a7970817" | 573 | checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" |
504 | 574 | ||
505 | [[package]] | 575 | [[package]] |
506 | name = "futures-task" | 576 | name = "futures-task" |
507 | version = "0.3.29" | 577 | version = "0.3.30" |
508 | source = "registry+https://github.com/rust-lang/crates.io-index" | 578 | source = "registry+https://github.com/rust-lang/crates.io-index" |
509 | checksum = "efd193069b0ddadc69c46389b740bbccdd97203899b48d09c5f7969591d6bae2" | 579 | checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" |
510 | 580 | ||
511 | [[package]] | 581 | [[package]] |
512 | name = "futures-util" | 582 | name = "futures-util" |
513 | version = "0.3.29" | 583 | version = "0.3.30" |
514 | source = "registry+https://github.com/rust-lang/crates.io-index" | 584 | source = "registry+https://github.com/rust-lang/crates.io-index" |
515 | checksum = "a19526d624e703a3179b3d322efec918b6246ea0fa51d41124525f00f1cc8104" | 585 | checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" |
516 | dependencies = [ | 586 | dependencies = [ |
517 | "futures-core", | 587 | "futures-core", |
518 | "futures-io", | 588 | "futures-io", |
@@ -536,9 +606,9 @@ dependencies = [ | |||
536 | 606 | ||
537 | [[package]] | 607 | [[package]] |
538 | name = "getrandom" | 608 | name = "getrandom" |
539 | version = "0.2.10" | 609 | version = "0.2.12" |
540 | source = "registry+https://github.com/rust-lang/crates.io-index" | 610 | source = "registry+https://github.com/rust-lang/crates.io-index" |
541 | checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" | 611 | checksum = "190092ea657667030ac6a35e305e62fc4dd69fd98ac98631e5d3a2b1575a12b5" |
542 | dependencies = [ | 612 | dependencies = [ |
543 | "cfg-if", | 613 | "cfg-if", |
544 | "libc", | 614 | "libc", |
@@ -547,9 +617,9 @@ dependencies = [ | |||
547 | 617 | ||
548 | [[package]] | 618 | [[package]] |
549 | name = "gimli" | 619 | name = "gimli" |
550 | version = "0.28.0" | 620 | version = "0.28.1" |
551 | source = "registry+https://github.com/rust-lang/crates.io-index" | 621 | source = "registry+https://github.com/rust-lang/crates.io-index" |
552 | checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" | 622 | checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253" |
553 | 623 | ||
554 | [[package]] | 624 | [[package]] |
555 | name = "glob" | 625 | name = "glob" |
@@ -558,21 +628,37 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
558 | checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" | 628 | checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" |
559 | 629 | ||
560 | [[package]] | 630 | [[package]] |
561 | name = "hashbrown" | 631 | name = "h2" |
562 | version = "0.12.3" | 632 | version = "0.4.2" |
563 | source = "registry+https://github.com/rust-lang/crates.io-index" | 633 | source = "registry+https://github.com/rust-lang/crates.io-index" |
564 | checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" | 634 | checksum = "31d030e59af851932b72ceebadf4a2b5986dba4c3b99dd2493f8273a0f151943" |
565 | dependencies = [ | 635 | dependencies = [ |
566 | "ahash 0.7.7", | 636 | "bytes", |
637 | "fnv", | ||
638 | "futures-core", | ||
639 | "futures-sink", | ||
640 | "futures-util", | ||
641 | "http", | ||
642 | "indexmap", | ||
643 | "slab", | ||
644 | "tokio", | ||
645 | "tokio-util", | ||
646 | "tracing", | ||
567 | ] | 647 | ] |
568 | 648 | ||
569 | [[package]] | 649 | [[package]] |
570 | name = "hashbrown" | 650 | name = "hashbrown" |
571 | version = "0.14.2" | 651 | version = "0.13.2" |
572 | source = "registry+https://github.com/rust-lang/crates.io-index" | 652 | source = "registry+https://github.com/rust-lang/crates.io-index" |
573 | checksum = "f93e7192158dbcda357bdec5fb5788eebf8bbac027f3f33e719d29135ae84156" | 653 | checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" |
654 | |||
655 | [[package]] | ||
656 | name = "hashbrown" | ||
657 | version = "0.14.3" | ||
658 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
659 | checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" | ||
574 | dependencies = [ | 660 | dependencies = [ |
575 | "ahash 0.8.6", | 661 | "ahash", |
576 | "allocator-api2", | 662 | "allocator-api2", |
577 | ] | 663 | ] |
578 | 664 | ||
@@ -582,31 +668,7 @@ version = "0.8.4" | |||
582 | source = "registry+https://github.com/rust-lang/crates.io-index" | 668 | source = "registry+https://github.com/rust-lang/crates.io-index" |
583 | checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" | 669 | checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" |
584 | dependencies = [ | 670 | dependencies = [ |
585 | "hashbrown 0.14.2", | 671 | "hashbrown 0.14.3", |
586 | ] | ||
587 | |||
588 | [[package]] | ||
589 | name = "headers" | ||
590 | version = "0.3.9" | ||
591 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
592 | checksum = "06683b93020a07e3dbcf5f8c0f6d40080d725bea7936fc01ad345c01b97dc270" | ||
593 | dependencies = [ | ||
594 | "base64 0.21.5", | ||
595 | "bytes", | ||
596 | "headers-core", | ||
597 | "http", | ||
598 | "httpdate", | ||
599 | "mime", | ||
600 | "sha1", | ||
601 | ] | ||
602 | |||
603 | [[package]] | ||
604 | name = "headers-core" | ||
605 | version = "0.2.0" | ||
606 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
607 | checksum = "e7f66481bfee273957b1f20485a4ff3362987f85b2c236580d81b4eb7a326429" | ||
608 | dependencies = [ | ||
609 | "http", | ||
610 | ] | 672 | ] |
611 | 673 | ||
612 | [[package]] | 674 | [[package]] |
@@ -620,9 +682,9 @@ dependencies = [ | |||
620 | 682 | ||
621 | [[package]] | 683 | [[package]] |
622 | name = "hermit-abi" | 684 | name = "hermit-abi" |
623 | version = "0.3.3" | 685 | version = "0.3.5" |
624 | source = "registry+https://github.com/rust-lang/crates.io-index" | 686 | source = "registry+https://github.com/rust-lang/crates.io-index" |
625 | checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" | 687 | checksum = "d0c62115964e08cb8039170eb33c1d0e2388a256930279edca206fff675f82c3" |
626 | 688 | ||
627 | [[package]] | 689 | [[package]] |
628 | name = "hex" | 690 | name = "hex" |
@@ -632,9 +694,9 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" | |||
632 | 694 | ||
633 | [[package]] | 695 | [[package]] |
634 | name = "hkdf" | 696 | name = "hkdf" |
635 | version = "0.12.3" | 697 | version = "0.12.4" |
636 | source = "registry+https://github.com/rust-lang/crates.io-index" | 698 | source = "registry+https://github.com/rust-lang/crates.io-index" |
637 | checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" | 699 | checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" |
638 | dependencies = [ | 700 | dependencies = [ |
639 | "hmac", | 701 | "hmac", |
640 | ] | 702 | ] |
@@ -650,18 +712,18 @@ dependencies = [ | |||
650 | 712 | ||
651 | [[package]] | 713 | [[package]] |
652 | name = "home" | 714 | name = "home" |
653 | version = "0.5.5" | 715 | version = "0.5.9" |
654 | source = "registry+https://github.com/rust-lang/crates.io-index" | 716 | source = "registry+https://github.com/rust-lang/crates.io-index" |
655 | checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" | 717 | checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5" |
656 | dependencies = [ | 718 | dependencies = [ |
657 | "windows-sys", | 719 | "windows-sys 0.52.0", |
658 | ] | 720 | ] |
659 | 721 | ||
660 | [[package]] | 722 | [[package]] |
661 | name = "http" | 723 | name = "http" |
662 | version = "0.2.9" | 724 | version = "1.0.0" |
663 | source = "registry+https://github.com/rust-lang/crates.io-index" | 725 | source = "registry+https://github.com/rust-lang/crates.io-index" |
664 | checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" | 726 | checksum = "b32afd38673a8016f7c9ae69e5af41a58f81b1d31689040f2f1959594ce194ea" |
665 | dependencies = [ | 727 | dependencies = [ |
666 | "bytes", | 728 | "bytes", |
667 | "fnv", | 729 | "fnv", |
@@ -670,12 +732,24 @@ dependencies = [ | |||
670 | 732 | ||
671 | [[package]] | 733 | [[package]] |
672 | name = "http-body" | 734 | name = "http-body" |
673 | version = "0.4.5" | 735 | version = "1.0.0" |
674 | source = "registry+https://github.com/rust-lang/crates.io-index" | 736 | source = "registry+https://github.com/rust-lang/crates.io-index" |
675 | checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" | 737 | checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" |
676 | dependencies = [ | 738 | dependencies = [ |
677 | "bytes", | 739 | "bytes", |
678 | "http", | 740 | "http", |
741 | ] | ||
742 | |||
743 | [[package]] | ||
744 | name = "http-body-util" | ||
745 | version = "0.1.0" | ||
746 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
747 | checksum = "41cb79eb393015dadd30fc252023adb0b2400a0caee0fa2a077e6e21a551e840" | ||
748 | dependencies = [ | ||
749 | "bytes", | ||
750 | "futures-util", | ||
751 | "http", | ||
752 | "http-body", | ||
679 | "pin-project-lite", | 753 | "pin-project-lite", |
680 | ] | 754 | ] |
681 | 755 | ||
@@ -693,61 +767,79 @@ checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" | |||
693 | 767 | ||
694 | [[package]] | 768 | [[package]] |
695 | name = "hyper" | 769 | name = "hyper" |
696 | version = "0.14.27" | 770 | version = "1.1.0" |
697 | source = "registry+https://github.com/rust-lang/crates.io-index" | 771 | source = "registry+https://github.com/rust-lang/crates.io-index" |
698 | checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" | 772 | checksum = "fb5aa53871fc917b1a9ed87b683a5d86db645e23acb32c2e0785a353e522fb75" |
699 | dependencies = [ | 773 | dependencies = [ |
700 | "bytes", | 774 | "bytes", |
701 | "futures-channel", | 775 | "futures-channel", |
702 | "futures-core", | ||
703 | "futures-util", | 776 | "futures-util", |
777 | "h2", | ||
704 | "http", | 778 | "http", |
705 | "http-body", | 779 | "http-body", |
706 | "httparse", | 780 | "httparse", |
707 | "httpdate", | 781 | "httpdate", |
708 | "itoa", | 782 | "itoa", |
709 | "pin-project-lite", | 783 | "pin-project-lite", |
710 | "socket2 0.4.10", | ||
711 | "tokio", | 784 | "tokio", |
712 | "tower-service", | 785 | ] |
713 | "tracing", | 786 | |
714 | "want", | 787 | [[package]] |
788 | name = "hyper-util" | ||
789 | version = "0.1.3" | ||
790 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
791 | checksum = "ca38ef113da30126bbff9cd1705f9273e15d45498615d138b0c20279ac7a76aa" | ||
792 | dependencies = [ | ||
793 | "bytes", | ||
794 | "futures-util", | ||
795 | "http", | ||
796 | "http-body", | ||
797 | "hyper", | ||
798 | "pin-project-lite", | ||
799 | "socket2", | ||
800 | "tokio", | ||
715 | ] | 801 | ] |
716 | 802 | ||
717 | [[package]] | 803 | [[package]] |
718 | name = "idna" | 804 | name = "idna" |
719 | version = "0.4.0" | 805 | version = "0.5.0" |
720 | source = "registry+https://github.com/rust-lang/crates.io-index" | 806 | source = "registry+https://github.com/rust-lang/crates.io-index" |
721 | checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" | 807 | checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" |
722 | dependencies = [ | 808 | dependencies = [ |
723 | "unicode-bidi", | 809 | "unicode-bidi", |
724 | "unicode-normalization", | 810 | "unicode-normalization", |
725 | ] | 811 | ] |
726 | 812 | ||
727 | [[package]] | 813 | [[package]] |
814 | name = "indenter" | ||
815 | version = "0.3.3" | ||
816 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
817 | checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" | ||
818 | |||
819 | [[package]] | ||
728 | name = "indexmap" | 820 | name = "indexmap" |
729 | version = "2.1.0" | 821 | version = "2.2.3" |
730 | source = "registry+https://github.com/rust-lang/crates.io-index" | 822 | source = "registry+https://github.com/rust-lang/crates.io-index" |
731 | checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" | 823 | checksum = "233cf39063f058ea2caae4091bf4a3ef70a653afbc026f5c4a4135d114e3c177" |
732 | dependencies = [ | 824 | dependencies = [ |
733 | "equivalent", | 825 | "equivalent", |
734 | "hashbrown 0.14.2", | 826 | "hashbrown 0.14.3", |
735 | ] | 827 | ] |
736 | 828 | ||
737 | [[package]] | 829 | [[package]] |
738 | name = "itertools" | 830 | name = "itertools" |
739 | version = "0.11.0" | 831 | version = "0.12.1" |
740 | source = "registry+https://github.com/rust-lang/crates.io-index" | 832 | source = "registry+https://github.com/rust-lang/crates.io-index" |
741 | checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57" | 833 | checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" |
742 | dependencies = [ | 834 | dependencies = [ |
743 | "either", | 835 | "either", |
744 | ] | 836 | ] |
745 | 837 | ||
746 | [[package]] | 838 | [[package]] |
747 | name = "itoa" | 839 | name = "itoa" |
748 | version = "1.0.9" | 840 | version = "1.0.10" |
749 | source = "registry+https://github.com/rust-lang/crates.io-index" | 841 | source = "registry+https://github.com/rust-lang/crates.io-index" |
750 | checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" | 842 | checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" |
751 | 843 | ||
752 | [[package]] | 844 | [[package]] |
753 | name = "json5" | 845 | name = "json5" |
@@ -771,9 +863,9 @@ dependencies = [ | |||
771 | 863 | ||
772 | [[package]] | 864 | [[package]] |
773 | name = "libc" | 865 | name = "libc" |
774 | version = "0.2.149" | 866 | version = "0.2.153" |
775 | source = "registry+https://github.com/rust-lang/crates.io-index" | 867 | source = "registry+https://github.com/rust-lang/crates.io-index" |
776 | checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" | 868 | checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" |
777 | 869 | ||
778 | [[package]] | 870 | [[package]] |
779 | name = "libm" | 871 | name = "libm" |
@@ -783,9 +875,9 @@ checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" | |||
783 | 875 | ||
784 | [[package]] | 876 | [[package]] |
785 | name = "libsqlite3-sys" | 877 | name = "libsqlite3-sys" |
786 | version = "0.26.0" | 878 | version = "0.27.0" |
787 | source = "registry+https://github.com/rust-lang/crates.io-index" | 879 | source = "registry+https://github.com/rust-lang/crates.io-index" |
788 | checksum = "afc22eff61b133b115c6e8c74e818c628d6d5e7a502afea6f64dee076dd94326" | 880 | checksum = "cf4e226dcd58b4be396f7bd3c20da8fdee2911400705297ba7d2d7cc2c30f716" |
789 | dependencies = [ | 881 | dependencies = [ |
790 | "cc", | 882 | "cc", |
791 | "pkg-config", | 883 | "pkg-config", |
@@ -800,9 +892,9 @@ checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" | |||
800 | 892 | ||
801 | [[package]] | 893 | [[package]] |
802 | name = "linux-raw-sys" | 894 | name = "linux-raw-sys" |
803 | version = "0.4.10" | 895 | version = "0.4.13" |
804 | source = "registry+https://github.com/rust-lang/crates.io-index" | 896 | source = "registry+https://github.com/rust-lang/crates.io-index" |
805 | checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" | 897 | checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" |
806 | 898 | ||
807 | [[package]] | 899 | [[package]] |
808 | name = "lock_api" | 900 | name = "lock_api" |
@@ -847,9 +939,9 @@ dependencies = [ | |||
847 | 939 | ||
848 | [[package]] | 940 | [[package]] |
849 | name = "memchr" | 941 | name = "memchr" |
850 | version = "2.6.4" | 942 | version = "2.7.1" |
851 | source = "registry+https://github.com/rust-lang/crates.io-index" | 943 | source = "registry+https://github.com/rust-lang/crates.io-index" |
852 | checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" | 944 | checksum = "523dc4f511e55ab87b694dc30d0f820d60906ef06413f93d4d7a1385599cc149" |
853 | 945 | ||
854 | [[package]] | 946 | [[package]] |
855 | name = "mime" | 947 | name = "mime" |
@@ -865,22 +957,33 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" | |||
865 | 957 | ||
866 | [[package]] | 958 | [[package]] |
867 | name = "miniz_oxide" | 959 | name = "miniz_oxide" |
868 | version = "0.7.1" | 960 | version = "0.7.2" |
869 | source = "registry+https://github.com/rust-lang/crates.io-index" | 961 | source = "registry+https://github.com/rust-lang/crates.io-index" |
870 | checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" | 962 | checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" |
871 | dependencies = [ | 963 | dependencies = [ |
872 | "adler", | 964 | "adler", |
873 | ] | 965 | ] |
874 | 966 | ||
875 | [[package]] | 967 | [[package]] |
876 | name = "mio" | 968 | name = "mio" |
877 | version = "0.8.9" | 969 | version = "0.8.10" |
878 | source = "registry+https://github.com/rust-lang/crates.io-index" | 970 | source = "registry+https://github.com/rust-lang/crates.io-index" |
879 | checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" | 971 | checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" |
880 | dependencies = [ | 972 | dependencies = [ |
881 | "libc", | 973 | "libc", |
882 | "wasi", | 974 | "wasi", |
883 | "windows-sys", | 975 | "windows-sys 0.48.0", |
976 | ] | ||
977 | |||
978 | [[package]] | ||
979 | name = "nix" | ||
980 | version = "0.27.1" | ||
981 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
982 | checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" | ||
983 | dependencies = [ | ||
984 | "bitflags 2.4.2", | ||
985 | "cfg-if", | ||
986 | "libc", | ||
884 | ] | 987 | ] |
885 | 988 | ||
886 | [[package]] | 989 | [[package]] |
@@ -927,20 +1030,25 @@ dependencies = [ | |||
927 | ] | 1030 | ] |
928 | 1031 | ||
929 | [[package]] | 1032 | [[package]] |
1033 | name = "num-conv" | ||
1034 | version = "0.1.0" | ||
1035 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
1036 | checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" | ||
1037 | |||
1038 | [[package]] | ||
930 | name = "num-integer" | 1039 | name = "num-integer" |
931 | version = "0.1.45" | 1040 | version = "0.1.46" |
932 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1041 | source = "registry+https://github.com/rust-lang/crates.io-index" |
933 | checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" | 1042 | checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" |
934 | dependencies = [ | 1043 | dependencies = [ |
935 | "autocfg", | ||
936 | "num-traits", | 1044 | "num-traits", |
937 | ] | 1045 | ] |
938 | 1046 | ||
939 | [[package]] | 1047 | [[package]] |
940 | name = "num-iter" | 1048 | name = "num-iter" |
941 | version = "0.1.43" | 1049 | version = "0.1.44" |
942 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1050 | source = "registry+https://github.com/rust-lang/crates.io-index" |
943 | checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" | 1051 | checksum = "d869c01cc0c455284163fd0092f1f93835385ccab5a98a0dcc497b2f8bf055a9" |
944 | dependencies = [ | 1052 | dependencies = [ |
945 | "autocfg", | 1053 | "autocfg", |
946 | "num-integer", | 1054 | "num-integer", |
@@ -949,9 +1057,9 @@ dependencies = [ | |||
949 | 1057 | ||
950 | [[package]] | 1058 | [[package]] |
951 | name = "num-traits" | 1059 | name = "num-traits" |
952 | version = "0.2.17" | 1060 | version = "0.2.18" |
953 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1061 | source = "registry+https://github.com/rust-lang/crates.io-index" |
954 | checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" | 1062 | checksum = "da0df0e5185db44f69b44f26786fe401b6c293d1907744beaa7fa62b2e5a517a" |
955 | dependencies = [ | 1063 | dependencies = [ |
956 | "autocfg", | 1064 | "autocfg", |
957 | "libm", | 1065 | "libm", |
@@ -978,27 +1086,27 @@ dependencies = [ | |||
978 | 1086 | ||
979 | [[package]] | 1087 | [[package]] |
980 | name = "object" | 1088 | name = "object" |
981 | version = "0.32.1" | 1089 | version = "0.32.2" |
982 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1090 | source = "registry+https://github.com/rust-lang/crates.io-index" |
983 | checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" | 1091 | checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" |
984 | dependencies = [ | 1092 | dependencies = [ |
985 | "memchr", | 1093 | "memchr", |
986 | ] | 1094 | ] |
987 | 1095 | ||
988 | [[package]] | 1096 | [[package]] |
989 | name = "once_cell" | 1097 | name = "once_cell" |
990 | version = "1.18.0" | 1098 | version = "1.19.0" |
991 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1099 | source = "registry+https://github.com/rust-lang/crates.io-index" |
992 | checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" | 1100 | checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" |
993 | 1101 | ||
994 | [[package]] | 1102 | [[package]] |
995 | name = "ordered-multimap" | 1103 | name = "ordered-multimap" |
996 | version = "0.4.3" | 1104 | version = "0.6.0" |
997 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1105 | source = "registry+https://github.com/rust-lang/crates.io-index" |
998 | checksum = "ccd746e37177e1711c20dd619a1620f34f5c8b569c53590a72dedd5344d8924a" | 1106 | checksum = "4ed8acf08e98e744e5384c8bc63ceb0364e68a6854187221c18df61c4797690e" |
999 | dependencies = [ | 1107 | dependencies = [ |
1000 | "dlv-list", | 1108 | "dlv-list", |
1001 | "hashbrown 0.12.3", | 1109 | "hashbrown 0.13.2", |
1002 | ] | 1110 | ] |
1003 | 1111 | ||
1004 | [[package]] | 1112 | [[package]] |
@@ -1008,6 +1116,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
1008 | checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" | 1116 | checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" |
1009 | 1117 | ||
1010 | [[package]] | 1118 | [[package]] |
1119 | name = "owo-colors" | ||
1120 | version = "3.5.0" | ||
1121 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
1122 | checksum = "c1b04fb49957986fdce4d6ee7a65027d55d4b6d2265e5848bbb507b58ccfdb6f" | ||
1123 | |||
1124 | [[package]] | ||
1011 | name = "parking_lot" | 1125 | name = "parking_lot" |
1012 | version = "0.12.1" | 1126 | version = "0.12.1" |
1013 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1127 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -1027,7 +1141,7 @@ dependencies = [ | |||
1027 | "libc", | 1141 | "libc", |
1028 | "redox_syscall", | 1142 | "redox_syscall", |
1029 | "smallvec", | 1143 | "smallvec", |
1030 | "windows-targets", | 1144 | "windows-targets 0.48.5", |
1031 | ] | 1145 | ] |
1032 | 1146 | ||
1033 | [[package]] | 1147 | [[package]] |
@@ -1053,15 +1167,15 @@ dependencies = [ | |||
1053 | 1167 | ||
1054 | [[package]] | 1168 | [[package]] |
1055 | name = "percent-encoding" | 1169 | name = "percent-encoding" |
1056 | version = "2.3.0" | 1170 | version = "2.3.1" |
1057 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1171 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1058 | checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" | 1172 | checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" |
1059 | 1173 | ||
1060 | [[package]] | 1174 | [[package]] |
1061 | name = "pest" | 1175 | name = "pest" |
1062 | version = "2.7.5" | 1176 | version = "2.7.7" |
1063 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1177 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1064 | checksum = "ae9cee2a55a544be8b89dc6848072af97a20f2422603c10865be2a42b580fff5" | 1178 | checksum = "219c0dcc30b6a27553f9cc242972b67f75b60eb0db71f0b5462f38b058c41546" |
1065 | dependencies = [ | 1179 | dependencies = [ |
1066 | "memchr", | 1180 | "memchr", |
1067 | "thiserror", | 1181 | "thiserror", |
@@ -1070,9 +1184,9 @@ dependencies = [ | |||
1070 | 1184 | ||
1071 | [[package]] | 1185 | [[package]] |
1072 | name = "pest_derive" | 1186 | name = "pest_derive" |
1073 | version = "2.7.5" | 1187 | version = "2.7.7" |
1074 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1188 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1075 | checksum = "81d78524685f5ef2a3b3bd1cafbc9fcabb036253d9b1463e726a91cd16e2dfc2" | 1189 | checksum = "22e1288dbd7786462961e69bfd4df7848c1e37e8b74303dbdab82c3a9cdd2809" |
1076 | dependencies = [ | 1190 | dependencies = [ |
1077 | "pest", | 1191 | "pest", |
1078 | "pest_generator", | 1192 | "pest_generator", |
@@ -1080,22 +1194,22 @@ dependencies = [ | |||
1080 | 1194 | ||
1081 | [[package]] | 1195 | [[package]] |
1082 | name = "pest_generator" | 1196 | name = "pest_generator" |
1083 | version = "2.7.5" | 1197 | version = "2.7.7" |
1084 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1198 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1085 | checksum = "68bd1206e71118b5356dae5ddc61c8b11e28b09ef6a31acbd15ea48a28e0c227" | 1199 | checksum = "1381c29a877c6d34b8c176e734f35d7f7f5b3adaefe940cb4d1bb7af94678e2e" |
1086 | dependencies = [ | 1200 | dependencies = [ |
1087 | "pest", | 1201 | "pest", |
1088 | "pest_meta", | 1202 | "pest_meta", |
1089 | "proc-macro2", | 1203 | "proc-macro2", |
1090 | "quote", | 1204 | "quote", |
1091 | "syn 2.0.38", | 1205 | "syn 2.0.48", |
1092 | ] | 1206 | ] |
1093 | 1207 | ||
1094 | [[package]] | 1208 | [[package]] |
1095 | name = "pest_meta" | 1209 | name = "pest_meta" |
1096 | version = "2.7.5" | 1210 | version = "2.7.7" |
1097 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1211 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1098 | checksum = "7c747191d4ad9e4a4ab9c8798f1e82a39affe7ef9648390b7e5548d18e099de6" | 1212 | checksum = "d0934d6907f148c22a3acbda520c7eed243ad7487a30f51f6ce52b58b7077a8a" |
1099 | dependencies = [ | 1213 | dependencies = [ |
1100 | "once_cell", | 1214 | "once_cell", |
1101 | "pest", | 1215 | "pest", |
@@ -1104,22 +1218,22 @@ dependencies = [ | |||
1104 | 1218 | ||
1105 | [[package]] | 1219 | [[package]] |
1106 | name = "pin-project" | 1220 | name = "pin-project" |
1107 | version = "1.1.3" | 1221 | version = "1.1.4" |
1108 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1222 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1109 | checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" | 1223 | checksum = "0302c4a0442c456bd56f841aee5c3bfd17967563f6fadc9ceb9f9c23cf3807e0" |
1110 | dependencies = [ | 1224 | dependencies = [ |
1111 | "pin-project-internal", | 1225 | "pin-project-internal", |
1112 | ] | 1226 | ] |
1113 | 1227 | ||
1114 | [[package]] | 1228 | [[package]] |
1115 | name = "pin-project-internal" | 1229 | name = "pin-project-internal" |
1116 | version = "1.1.3" | 1230 | version = "1.1.4" |
1117 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1231 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1118 | checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" | 1232 | checksum = "266c042b60c9c76b8d53061e52b2e0d1116abc57cefc8c5cd671619a56ac3690" |
1119 | dependencies = [ | 1233 | dependencies = [ |
1120 | "proc-macro2", | 1234 | "proc-macro2", |
1121 | "quote", | 1235 | "quote", |
1122 | "syn 2.0.38", | 1236 | "syn 2.0.48", |
1123 | ] | 1237 | ] |
1124 | 1238 | ||
1125 | [[package]] | 1239 | [[package]] |
@@ -1157,9 +1271,9 @@ dependencies = [ | |||
1157 | 1271 | ||
1158 | [[package]] | 1272 | [[package]] |
1159 | name = "pkg-config" | 1273 | name = "pkg-config" |
1160 | version = "0.3.27" | 1274 | version = "0.3.29" |
1161 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1275 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1162 | checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" | 1276 | checksum = "2900ede94e305130c13ddd391e0ab7cbaeb783945ae07a279c268cb05109c6cb" |
1163 | 1277 | ||
1164 | [[package]] | 1278 | [[package]] |
1165 | name = "pnet_base" | 1279 | name = "pnet_base" |
@@ -1217,18 +1331,18 @@ checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" | |||
1217 | 1331 | ||
1218 | [[package]] | 1332 | [[package]] |
1219 | name = "proc-macro2" | 1333 | name = "proc-macro2" |
1220 | version = "1.0.69" | 1334 | version = "1.0.78" |
1221 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1335 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1222 | checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" | 1336 | checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" |
1223 | dependencies = [ | 1337 | dependencies = [ |
1224 | "unicode-ident", | 1338 | "unicode-ident", |
1225 | ] | 1339 | ] |
1226 | 1340 | ||
1227 | [[package]] | 1341 | [[package]] |
1228 | name = "quote" | 1342 | name = "quote" |
1229 | version = "1.0.33" | 1343 | version = "1.0.35" |
1230 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1344 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1231 | checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" | 1345 | checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" |
1232 | dependencies = [ | 1346 | dependencies = [ |
1233 | "proc-macro2", | 1347 | "proc-macro2", |
1234 | ] | 1348 | ] |
@@ -1274,13 +1388,13 @@ dependencies = [ | |||
1274 | 1388 | ||
1275 | [[package]] | 1389 | [[package]] |
1276 | name = "regex" | 1390 | name = "regex" |
1277 | version = "1.10.2" | 1391 | version = "1.10.3" |
1278 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1392 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1279 | checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" | 1393 | checksum = "b62dbe01f0b06f9d8dc7d49e05a0785f153b00b2c227856282f671e0318c9b15" |
1280 | dependencies = [ | 1394 | dependencies = [ |
1281 | "aho-corasick", | 1395 | "aho-corasick", |
1282 | "memchr", | 1396 | "memchr", |
1283 | "regex-automata 0.4.3", | 1397 | "regex-automata 0.4.5", |
1284 | "regex-syntax 0.8.2", | 1398 | "regex-syntax 0.8.2", |
1285 | ] | 1399 | ] |
1286 | 1400 | ||
@@ -1295,9 +1409,9 @@ dependencies = [ | |||
1295 | 1409 | ||
1296 | [[package]] | 1410 | [[package]] |
1297 | name = "regex-automata" | 1411 | name = "regex-automata" |
1298 | version = "0.4.3" | 1412 | version = "0.4.5" |
1299 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1413 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1300 | checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" | 1414 | checksum = "5bb987efffd3c6d0d8f5f89510bb458559eab11e4f869acb20bf845e016259cd" |
1301 | dependencies = [ | 1415 | dependencies = [ |
1302 | "aho-corasick", | 1416 | "aho-corasick", |
1303 | "memchr", | 1417 | "memchr", |
@@ -1318,20 +1432,21 @@ checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" | |||
1318 | 1432 | ||
1319 | [[package]] | 1433 | [[package]] |
1320 | name = "ron" | 1434 | name = "ron" |
1321 | version = "0.7.1" | 1435 | version = "0.8.1" |
1322 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1436 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1323 | checksum = "88073939a61e5b7680558e6be56b419e208420c2adb92be54921fa6b72283f1a" | 1437 | checksum = "b91f7eff05f748767f183df4320a63d6936e9c6107d97c9e6bdd9784f4289c94" |
1324 | dependencies = [ | 1438 | dependencies = [ |
1325 | "base64 0.13.1", | 1439 | "base64", |
1326 | "bitflags 1.3.2", | 1440 | "bitflags 2.4.2", |
1327 | "serde", | 1441 | "serde", |
1442 | "serde_derive", | ||
1328 | ] | 1443 | ] |
1329 | 1444 | ||
1330 | [[package]] | 1445 | [[package]] |
1331 | name = "rsa" | 1446 | name = "rsa" |
1332 | version = "0.9.3" | 1447 | version = "0.9.6" |
1333 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1448 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1334 | checksum = "86ef35bf3e7fe15a53c4ab08a998e42271eab13eb0db224126bc7bc4c4bad96d" | 1449 | checksum = "5d0e5124fcb30e76a7e79bfee683a2746db83784b86289f6251b54b7950a0dfc" |
1335 | dependencies = [ | 1450 | dependencies = [ |
1336 | "const-oid", | 1451 | "const-oid", |
1337 | "digest", | 1452 | "digest", |
@@ -1349,9 +1464,9 @@ dependencies = [ | |||
1349 | 1464 | ||
1350 | [[package]] | 1465 | [[package]] |
1351 | name = "rust-ini" | 1466 | name = "rust-ini" |
1352 | version = "0.18.0" | 1467 | version = "0.19.0" |
1353 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1468 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1354 | checksum = "f6d5f2436026b4f6e79dc829837d467cc7e9a55ee40e750d716713540715a2df" | 1469 | checksum = "7e2a3bcec1f113553ef1c88aae6c020a369d03d55b58de9869a0908930385091" |
1355 | dependencies = [ | 1470 | dependencies = [ |
1356 | "cfg-if", | 1471 | "cfg-if", |
1357 | "ordered-multimap", | 1472 | "ordered-multimap", |
@@ -1365,15 +1480,15 @@ checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" | |||
1365 | 1480 | ||
1366 | [[package]] | 1481 | [[package]] |
1367 | name = "rustix" | 1482 | name = "rustix" |
1368 | version = "0.38.21" | 1483 | version = "0.38.31" |
1369 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1484 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1370 | checksum = "2b426b0506e5d50a7d8dafcf2e81471400deb602392c7dd110815afb4eaf02a3" | 1485 | checksum = "6ea3e1a662af26cd7a3ba09c0297a31af215563ecf42817c98df621387f4e949" |
1371 | dependencies = [ | 1486 | dependencies = [ |
1372 | "bitflags 2.4.1", | 1487 | "bitflags 2.4.2", |
1373 | "errno", | 1488 | "errno", |
1374 | "libc", | 1489 | "libc", |
1375 | "linux-raw-sys", | 1490 | "linux-raw-sys", |
1376 | "windows-sys", | 1491 | "windows-sys 0.52.0", |
1377 | ] | 1492 | ] |
1378 | 1493 | ||
1379 | [[package]] | 1494 | [[package]] |
@@ -1384,9 +1499,9 @@ checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" | |||
1384 | 1499 | ||
1385 | [[package]] | 1500 | [[package]] |
1386 | name = "ryu" | 1501 | name = "ryu" |
1387 | version = "1.0.15" | 1502 | version = "1.0.16" |
1388 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1503 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1389 | checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" | 1504 | checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" |
1390 | 1505 | ||
1391 | [[package]] | 1506 | [[package]] |
1392 | name = "scopeguard" | 1507 | name = "scopeguard" |
@@ -1396,29 +1511,29 @@ checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" | |||
1396 | 1511 | ||
1397 | [[package]] | 1512 | [[package]] |
1398 | name = "serde" | 1513 | name = "serde" |
1399 | version = "1.0.190" | 1514 | version = "1.0.196" |
1400 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1515 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1401 | checksum = "91d3c334ca1ee894a2c6f6ad698fe8c435b76d504b13d436f0685d648d6d96f7" | 1516 | checksum = "870026e60fa08c69f064aa766c10f10b1d62db9ccd4d0abb206472bee0ce3b32" |
1402 | dependencies = [ | 1517 | dependencies = [ |
1403 | "serde_derive", | 1518 | "serde_derive", |
1404 | ] | 1519 | ] |
1405 | 1520 | ||
1406 | [[package]] | 1521 | [[package]] |
1407 | name = "serde_derive" | 1522 | name = "serde_derive" |
1408 | version = "1.0.190" | 1523 | version = "1.0.196" |
1409 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1524 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1410 | checksum = "67c5609f394e5c2bd7fc51efda478004ea80ef42fee983d5c67a65e34f32c0e3" | 1525 | checksum = "33c85360c95e7d137454dc81d9a4ed2b8efd8fbe19cee57357b32b9771fccb67" |
1411 | dependencies = [ | 1526 | dependencies = [ |
1412 | "proc-macro2", | 1527 | "proc-macro2", |
1413 | "quote", | 1528 | "quote", |
1414 | "syn 2.0.38", | 1529 | "syn 2.0.48", |
1415 | ] | 1530 | ] |
1416 | 1531 | ||
1417 | [[package]] | 1532 | [[package]] |
1418 | name = "serde_json" | 1533 | name = "serde_json" |
1419 | version = "1.0.108" | 1534 | version = "1.0.113" |
1420 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1535 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1421 | checksum = "3d1c7e3eac408d115102c4c24ad393e0821bb3a5df4d506a80f85f7a742a526b" | 1536 | checksum = "69801b70b1c3dac963ecb03a364ba0ceda9cf60c71cfe475e99864759c8b8a79" |
1422 | dependencies = [ | 1537 | dependencies = [ |
1423 | "itoa", | 1538 | "itoa", |
1424 | "ryu", | 1539 | "ryu", |
@@ -1427,15 +1542,24 @@ dependencies = [ | |||
1427 | 1542 | ||
1428 | [[package]] | 1543 | [[package]] |
1429 | name = "serde_path_to_error" | 1544 | name = "serde_path_to_error" |
1430 | version = "0.1.14" | 1545 | version = "0.1.15" |
1431 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1546 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1432 | checksum = "4beec8bce849d58d06238cb50db2e1c417cfeafa4c63f692b15c82b7c80f8335" | 1547 | checksum = "ebd154a240de39fdebcf5775d2675c204d7c13cf39a4c697be6493c8e734337c" |
1433 | dependencies = [ | 1548 | dependencies = [ |
1434 | "itoa", | 1549 | "itoa", |
1435 | "serde", | 1550 | "serde", |
1436 | ] | 1551 | ] |
1437 | 1552 | ||
1438 | [[package]] | 1553 | [[package]] |
1554 | name = "serde_spanned" | ||
1555 | version = "0.6.5" | ||
1556 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
1557 | checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" | ||
1558 | dependencies = [ | ||
1559 | "serde", | ||
1560 | ] | ||
1561 | |||
1562 | [[package]] | ||
1439 | name = "serde_urlencoded" | 1563 | name = "serde_urlencoded" |
1440 | version = "0.7.1" | 1564 | version = "0.7.1" |
1441 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1565 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -1480,9 +1604,9 @@ dependencies = [ | |||
1480 | 1604 | ||
1481 | [[package]] | 1605 | [[package]] |
1482 | name = "signature" | 1606 | name = "signature" |
1483 | version = "2.1.0" | 1607 | version = "2.2.0" |
1484 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1608 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1485 | checksum = "5e1788eed21689f9cf370582dfc467ef36ed9c707f073528ddafa8d83e3b8500" | 1609 | checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" |
1486 | dependencies = [ | 1610 | dependencies = [ |
1487 | "digest", | 1611 | "digest", |
1488 | "rand_core", | 1612 | "rand_core", |
@@ -1499,19 +1623,9 @@ dependencies = [ | |||
1499 | 1623 | ||
1500 | [[package]] | 1624 | [[package]] |
1501 | name = "smallvec" | 1625 | name = "smallvec" |
1502 | version = "1.11.1" | 1626 | version = "1.13.1" |
1503 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
1504 | checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" | ||
1505 | |||
1506 | [[package]] | ||
1507 | name = "socket2" | ||
1508 | version = "0.4.10" | ||
1509 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1627 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1510 | checksum = "9f7916fc008ca5542385b89a3d3ce689953c143e9304a9bf8beec1de48994c0d" | 1628 | checksum = "e6ecd384b10a64542d77071bd64bd7b231f4ed5940fba55e98c3de13824cf3d7" |
1511 | dependencies = [ | ||
1512 | "libc", | ||
1513 | "winapi", | ||
1514 | ] | ||
1515 | 1629 | ||
1516 | [[package]] | 1630 | [[package]] |
1517 | name = "socket2" | 1631 | name = "socket2" |
@@ -1520,7 +1634,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
1520 | checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" | 1634 | checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" |
1521 | dependencies = [ | 1635 | dependencies = [ |
1522 | "libc", | 1636 | "libc", |
1523 | "windows-sys", | 1637 | "windows-sys 0.48.0", |
1524 | ] | 1638 | ] |
1525 | 1639 | ||
1526 | [[package]] | 1640 | [[package]] |
@@ -1540,9 +1654,9 @@ dependencies = [ | |||
1540 | 1654 | ||
1541 | [[package]] | 1655 | [[package]] |
1542 | name = "spki" | 1656 | name = "spki" |
1543 | version = "0.7.2" | 1657 | version = "0.7.3" |
1544 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1658 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1545 | checksum = "9d1e996ef02c474957d681f1b05213dfb0abab947b446a62d37770b23500184a" | 1659 | checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" |
1546 | dependencies = [ | 1660 | dependencies = [ |
1547 | "base64ct", | 1661 | "base64ct", |
1548 | "der", | 1662 | "der", |
@@ -1550,9 +1664,9 @@ dependencies = [ | |||
1550 | 1664 | ||
1551 | [[package]] | 1665 | [[package]] |
1552 | name = "sqlformat" | 1666 | name = "sqlformat" |
1553 | version = "0.2.2" | 1667 | version = "0.2.3" |
1554 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1668 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1555 | checksum = "6b7b278788e7be4d0d29c0f39497a0eef3fba6bbc8e70d8bf7fde46edeaa9e85" | 1669 | checksum = "ce81b7bd7c4493975347ef60d8c7e8b742d4694f4c49f93e0a12ea263938176c" |
1556 | dependencies = [ | 1670 | dependencies = [ |
1557 | "itertools", | 1671 | "itertools", |
1558 | "nom", | 1672 | "nom", |
@@ -1561,9 +1675,9 @@ dependencies = [ | |||
1561 | 1675 | ||
1562 | [[package]] | 1676 | [[package]] |
1563 | name = "sqlx" | 1677 | name = "sqlx" |
1564 | version = "0.7.2" | 1678 | version = "0.7.3" |
1565 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1679 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1566 | checksum = "0e50c216e3624ec8e7ecd14c6a6a6370aad6ee5d8cfc3ab30b5162eeeef2ed33" | 1680 | checksum = "dba03c279da73694ef99763320dea58b51095dfe87d001b1d4b5fe78ba8763cf" |
1567 | dependencies = [ | 1681 | dependencies = [ |
1568 | "sqlx-core", | 1682 | "sqlx-core", |
1569 | "sqlx-macros", | 1683 | "sqlx-macros", |
@@ -1574,11 +1688,11 @@ dependencies = [ | |||
1574 | 1688 | ||
1575 | [[package]] | 1689 | [[package]] |
1576 | name = "sqlx-core" | 1690 | name = "sqlx-core" |
1577 | version = "0.7.2" | 1691 | version = "0.7.3" |
1578 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1692 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1579 | checksum = "8d6753e460c998bbd4cd8c6f0ed9a64346fcca0723d6e75e52fdc351c5d2169d" | 1693 | checksum = "d84b0a3c3739e220d94b3239fd69fb1f74bc36e16643423bd99de3b43c21bfbd" |
1580 | dependencies = [ | 1694 | dependencies = [ |
1581 | "ahash 0.8.6", | 1695 | "ahash", |
1582 | "atoi", | 1696 | "atoi", |
1583 | "byteorder", | 1697 | "byteorder", |
1584 | "bytes", | 1698 | "bytes", |
@@ -1614,9 +1728,9 @@ dependencies = [ | |||
1614 | 1728 | ||
1615 | [[package]] | 1729 | [[package]] |
1616 | name = "sqlx-macros" | 1730 | name = "sqlx-macros" |
1617 | version = "0.7.2" | 1731 | version = "0.7.3" |
1618 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1732 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1619 | checksum = "9a793bb3ba331ec8359c1853bd39eed32cdd7baaf22c35ccf5c92a7e8d1189ec" | 1733 | checksum = "89961c00dc4d7dffb7aee214964b065072bff69e36ddb9e2c107541f75e4f2a5" |
1620 | dependencies = [ | 1734 | dependencies = [ |
1621 | "proc-macro2", | 1735 | "proc-macro2", |
1622 | "quote", | 1736 | "quote", |
@@ -1627,10 +1741,11 @@ dependencies = [ | |||
1627 | 1741 | ||
1628 | [[package]] | 1742 | [[package]] |
1629 | name = "sqlx-macros-core" | 1743 | name = "sqlx-macros-core" |
1630 | version = "0.7.2" | 1744 | version = "0.7.3" |
1631 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1745 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1632 | checksum = "0a4ee1e104e00dedb6aa5ffdd1343107b0a4702e862a84320ee7cc74782d96fc" | 1746 | checksum = "d0bd4519486723648186a08785143599760f7cc81c52334a55d6a83ea1e20841" |
1633 | dependencies = [ | 1747 | dependencies = [ |
1748 | "atomic-write-file", | ||
1634 | "dotenvy", | 1749 | "dotenvy", |
1635 | "either", | 1750 | "either", |
1636 | "heck", | 1751 | "heck", |
@@ -1653,13 +1768,13 @@ dependencies = [ | |||
1653 | 1768 | ||
1654 | [[package]] | 1769 | [[package]] |
1655 | name = "sqlx-mysql" | 1770 | name = "sqlx-mysql" |
1656 | version = "0.7.2" | 1771 | version = "0.7.3" |
1657 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1772 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1658 | checksum = "864b869fdf56263f4c95c45483191ea0af340f9f3e3e7b4d57a61c7c87a970db" | 1773 | checksum = "e37195395df71fd068f6e2082247891bc11e3289624bbc776a0cdfa1ca7f1ea4" |
1659 | dependencies = [ | 1774 | dependencies = [ |
1660 | "atoi", | 1775 | "atoi", |
1661 | "base64 0.21.5", | 1776 | "base64", |
1662 | "bitflags 2.4.1", | 1777 | "bitflags 2.4.2", |
1663 | "byteorder", | 1778 | "byteorder", |
1664 | "bytes", | 1779 | "bytes", |
1665 | "crc", | 1780 | "crc", |
@@ -1695,13 +1810,13 @@ dependencies = [ | |||
1695 | 1810 | ||
1696 | [[package]] | 1811 | [[package]] |
1697 | name = "sqlx-postgres" | 1812 | name = "sqlx-postgres" |
1698 | version = "0.7.2" | 1813 | version = "0.7.3" |
1699 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1814 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1700 | checksum = "eb7ae0e6a97fb3ba33b23ac2671a5ce6e3cabe003f451abd5a56e7951d975624" | 1815 | checksum = "d6ac0ac3b7ccd10cc96c7ab29791a7dd236bd94021f31eec7ba3d46a74aa1c24" |
1701 | dependencies = [ | 1816 | dependencies = [ |
1702 | "atoi", | 1817 | "atoi", |
1703 | "base64 0.21.5", | 1818 | "base64", |
1704 | "bitflags 2.4.1", | 1819 | "bitflags 2.4.2", |
1705 | "byteorder", | 1820 | "byteorder", |
1706 | "crc", | 1821 | "crc", |
1707 | "dotenvy", | 1822 | "dotenvy", |
@@ -1734,9 +1849,9 @@ dependencies = [ | |||
1734 | 1849 | ||
1735 | [[package]] | 1850 | [[package]] |
1736 | name = "sqlx-sqlite" | 1851 | name = "sqlx-sqlite" |
1737 | version = "0.7.2" | 1852 | version = "0.7.3" |
1738 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1853 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1739 | checksum = "d59dc83cf45d89c555a577694534fcd1b55c545a816c816ce51f20bbe56a4f3f" | 1854 | checksum = "210976b7d948c7ba9fced8ca835b11cbb2d677c59c79de41ac0d397e14547490" |
1740 | dependencies = [ | 1855 | dependencies = [ |
1741 | "atoi", | 1856 | "atoi", |
1742 | "flume", | 1857 | "flume", |
@@ -1752,6 +1867,7 @@ dependencies = [ | |||
1752 | "sqlx-core", | 1867 | "sqlx-core", |
1753 | "tracing", | 1868 | "tracing", |
1754 | "url", | 1869 | "url", |
1870 | "urlencoding", | ||
1755 | ] | 1871 | ] |
1756 | 1872 | ||
1757 | [[package]] | 1873 | [[package]] |
@@ -1781,7 +1897,7 @@ dependencies = [ | |||
1781 | "parking_lot", | 1897 | "parking_lot", |
1782 | "pnet_packet", | 1898 | "pnet_packet", |
1783 | "rand", | 1899 | "rand", |
1784 | "socket2 0.5.5", | 1900 | "socket2", |
1785 | "thiserror", | 1901 | "thiserror", |
1786 | "tokio", | 1902 | "tokio", |
1787 | "tracing", | 1903 | "tracing", |
@@ -1800,9 +1916,9 @@ dependencies = [ | |||
1800 | 1916 | ||
1801 | [[package]] | 1917 | [[package]] |
1802 | name = "syn" | 1918 | name = "syn" |
1803 | version = "2.0.38" | 1919 | version = "2.0.48" |
1804 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1920 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1805 | checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" | 1921 | checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" |
1806 | dependencies = [ | 1922 | dependencies = [ |
1807 | "proc-macro2", | 1923 | "proc-macro2", |
1808 | "quote", | 1924 | "quote", |
@@ -1817,35 +1933,34 @@ checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" | |||
1817 | 1933 | ||
1818 | [[package]] | 1934 | [[package]] |
1819 | name = "tempfile" | 1935 | name = "tempfile" |
1820 | version = "3.8.1" | 1936 | version = "3.10.0" |
1821 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1937 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1822 | checksum = "7ef1adac450ad7f4b3c28589471ade84f25f731a7a0fe30d71dfa9f60fd808e5" | 1938 | checksum = "a365e8cd18e44762ef95d87f284f4b5cd04107fec2ff3052bd6a3e6069669e67" |
1823 | dependencies = [ | 1939 | dependencies = [ |
1824 | "cfg-if", | 1940 | "cfg-if", |
1825 | "fastrand", | 1941 | "fastrand", |
1826 | "redox_syscall", | ||
1827 | "rustix", | 1942 | "rustix", |
1828 | "windows-sys", | 1943 | "windows-sys 0.52.0", |
1829 | ] | 1944 | ] |
1830 | 1945 | ||
1831 | [[package]] | 1946 | [[package]] |
1832 | name = "thiserror" | 1947 | name = "thiserror" |
1833 | version = "1.0.50" | 1948 | version = "1.0.57" |
1834 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1949 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1835 | checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2" | 1950 | checksum = "1e45bcbe8ed29775f228095caf2cd67af7a4ccf756ebff23a306bf3e8b47b24b" |
1836 | dependencies = [ | 1951 | dependencies = [ |
1837 | "thiserror-impl", | 1952 | "thiserror-impl", |
1838 | ] | 1953 | ] |
1839 | 1954 | ||
1840 | [[package]] | 1955 | [[package]] |
1841 | name = "thiserror-impl" | 1956 | name = "thiserror-impl" |
1842 | version = "1.0.50" | 1957 | version = "1.0.57" |
1843 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1958 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1844 | checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" | 1959 | checksum = "a953cb265bef375dae3de6663da4d3804eee9682ea80d8e2542529b73c531c81" |
1845 | dependencies = [ | 1960 | dependencies = [ |
1846 | "proc-macro2", | 1961 | "proc-macro2", |
1847 | "quote", | 1962 | "quote", |
1848 | "syn 2.0.38", | 1963 | "syn 2.0.48", |
1849 | ] | 1964 | ] |
1850 | 1965 | ||
1851 | [[package]] | 1966 | [[package]] |
@@ -1860,13 +1975,14 @@ dependencies = [ | |||
1860 | 1975 | ||
1861 | [[package]] | 1976 | [[package]] |
1862 | name = "time" | 1977 | name = "time" |
1863 | version = "0.3.30" | 1978 | version = "0.3.34" |
1864 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1979 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1865 | checksum = "c4a34ab300f2dee6e562c10a046fc05e358b29f9bf92277f30c3c8d82275f6f5" | 1980 | checksum = "c8248b6521bb14bc45b4067159b9b6ad792e2d6d754d6c41fb50e29fefe38749" |
1866 | dependencies = [ | 1981 | dependencies = [ |
1867 | "deranged", | 1982 | "deranged", |
1868 | "itoa", | 1983 | "itoa", |
1869 | "libc", | 1984 | "libc", |
1985 | "num-conv", | ||
1870 | "num_threads", | 1986 | "num_threads", |
1871 | "powerfmt", | 1987 | "powerfmt", |
1872 | "serde", | 1988 | "serde", |
@@ -1882,14 +1998,24 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" | |||
1882 | 1998 | ||
1883 | [[package]] | 1999 | [[package]] |
1884 | name = "time-macros" | 2000 | name = "time-macros" |
1885 | version = "0.2.15" | 2001 | version = "0.2.17" |
1886 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2002 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1887 | checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" | 2003 | checksum = "7ba3a3ef41e6672a2f0f001392bb5dcd3ff0a9992d618ca761a11c3121547774" |
1888 | dependencies = [ | 2004 | dependencies = [ |
2005 | "num-conv", | ||
1889 | "time-core", | 2006 | "time-core", |
1890 | ] | 2007 | ] |
1891 | 2008 | ||
1892 | [[package]] | 2009 | [[package]] |
2010 | name = "tiny-keccak" | ||
2011 | version = "2.0.2" | ||
2012 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2013 | checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" | ||
2014 | dependencies = [ | ||
2015 | "crunchy", | ||
2016 | ] | ||
2017 | |||
2018 | [[package]] | ||
1893 | name = "tinyvec" | 2019 | name = "tinyvec" |
1894 | version = "1.6.0" | 2020 | version = "1.6.0" |
1895 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2021 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -1906,9 +2032,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" | |||
1906 | 2032 | ||
1907 | [[package]] | 2033 | [[package]] |
1908 | name = "tokio" | 2034 | name = "tokio" |
1909 | version = "1.33.0" | 2035 | version = "1.36.0" |
1910 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2036 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1911 | checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653" | 2037 | checksum = "61285f6515fa018fb2d1e46eb21223fff441ee8db5d0f1435e8ab4f5cdb80931" |
1912 | dependencies = [ | 2038 | dependencies = [ |
1913 | "backtrace", | 2039 | "backtrace", |
1914 | "bytes", | 2040 | "bytes", |
@@ -1916,20 +2042,20 @@ dependencies = [ | |||
1916 | "mio", | 2042 | "mio", |
1917 | "num_cpus", | 2043 | "num_cpus", |
1918 | "pin-project-lite", | 2044 | "pin-project-lite", |
1919 | "socket2 0.5.5", | 2045 | "socket2", |
1920 | "tokio-macros", | 2046 | "tokio-macros", |
1921 | "windows-sys", | 2047 | "windows-sys 0.48.0", |
1922 | ] | 2048 | ] |
1923 | 2049 | ||
1924 | [[package]] | 2050 | [[package]] |
1925 | name = "tokio-macros" | 2051 | name = "tokio-macros" |
1926 | version = "2.1.0" | 2052 | version = "2.2.0" |
1927 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2053 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1928 | checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" | 2054 | checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" |
1929 | dependencies = [ | 2055 | dependencies = [ |
1930 | "proc-macro2", | 2056 | "proc-macro2", |
1931 | "quote", | 2057 | "quote", |
1932 | "syn 2.0.38", | 2058 | "syn 2.0.48", |
1933 | ] | 2059 | ] |
1934 | 2060 | ||
1935 | [[package]] | 2061 | [[package]] |
@@ -1945,9 +2071,9 @@ dependencies = [ | |||
1945 | 2071 | ||
1946 | [[package]] | 2072 | [[package]] |
1947 | name = "tokio-tungstenite" | 2073 | name = "tokio-tungstenite" |
1948 | version = "0.20.1" | 2074 | version = "0.21.0" |
1949 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2075 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1950 | checksum = "212d5dcb2a1ce06d81107c3d0ffa3121fe974b73f068c8282cb1c32328113b6c" | 2076 | checksum = "c83b561d025642014097b66e6c1bb422783339e0909e4429cde4749d1990bc38" |
1951 | dependencies = [ | 2077 | dependencies = [ |
1952 | "futures-util", | 2078 | "futures-util", |
1953 | "log", | 2079 | "log", |
@@ -1956,12 +2082,51 @@ dependencies = [ | |||
1956 | ] | 2082 | ] |
1957 | 2083 | ||
1958 | [[package]] | 2084 | [[package]] |
2085 | name = "tokio-util" | ||
2086 | version = "0.7.10" | ||
2087 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2088 | checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" | ||
2089 | dependencies = [ | ||
2090 | "bytes", | ||
2091 | "futures-core", | ||
2092 | "futures-sink", | ||
2093 | "pin-project-lite", | ||
2094 | "tokio", | ||
2095 | "tracing", | ||
2096 | ] | ||
2097 | |||
2098 | [[package]] | ||
1959 | name = "toml" | 2099 | name = "toml" |
1960 | version = "0.5.11" | 2100 | version = "0.8.10" |
1961 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2101 | source = "registry+https://github.com/rust-lang/crates.io-index" |
1962 | checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" | 2102 | checksum = "9a9aad4a3066010876e8dcf5a8a06e70a558751117a145c6ce2b82c2e2054290" |
1963 | dependencies = [ | 2103 | dependencies = [ |
1964 | "serde", | 2104 | "serde", |
2105 | "serde_spanned", | ||
2106 | "toml_datetime", | ||
2107 | "toml_edit", | ||
2108 | ] | ||
2109 | |||
2110 | [[package]] | ||
2111 | name = "toml_datetime" | ||
2112 | version = "0.6.5" | ||
2113 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2114 | checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" | ||
2115 | dependencies = [ | ||
2116 | "serde", | ||
2117 | ] | ||
2118 | |||
2119 | [[package]] | ||
2120 | name = "toml_edit" | ||
2121 | version = "0.22.4" | ||
2122 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2123 | checksum = "0c9ffdf896f8daaabf9b66ba8e77ea1ed5ed0f72821b398aba62352e95062951" | ||
2124 | dependencies = [ | ||
2125 | "indexmap", | ||
2126 | "serde", | ||
2127 | "serde_spanned", | ||
2128 | "toml_datetime", | ||
2129 | "winnow", | ||
1965 | ] | 2130 | ] |
1966 | 2131 | ||
1967 | [[package]] | 2132 | [[package]] |
@@ -2012,7 +2177,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" | |||
2012 | dependencies = [ | 2177 | dependencies = [ |
2013 | "proc-macro2", | 2178 | "proc-macro2", |
2014 | "quote", | 2179 | "quote", |
2015 | "syn 2.0.38", | 2180 | "syn 2.0.48", |
2016 | ] | 2181 | ] |
2017 | 2182 | ||
2018 | [[package]] | 2183 | [[package]] |
@@ -2026,10 +2191,20 @@ dependencies = [ | |||
2026 | ] | 2191 | ] |
2027 | 2192 | ||
2028 | [[package]] | 2193 | [[package]] |
2194 | name = "tracing-error" | ||
2195 | version = "0.2.0" | ||
2196 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2197 | checksum = "d686ec1c0f384b1277f097b2f279a2ecc11afe8c133c1aabf036a27cb4cd206e" | ||
2198 | dependencies = [ | ||
2199 | "tracing", | ||
2200 | "tracing-subscriber", | ||
2201 | ] | ||
2202 | |||
2203 | [[package]] | ||
2029 | name = "tracing-log" | 2204 | name = "tracing-log" |
2030 | version = "0.1.4" | 2205 | version = "0.2.0" |
2031 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2206 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2032 | checksum = "f751112709b4e791d8ce53e32c4ed2d353565a795ce84da2285393f41557bdf2" | 2207 | checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" |
2033 | dependencies = [ | 2208 | dependencies = [ |
2034 | "log", | 2209 | "log", |
2035 | "once_cell", | 2210 | "once_cell", |
@@ -2038,9 +2213,9 @@ dependencies = [ | |||
2038 | 2213 | ||
2039 | [[package]] | 2214 | [[package]] |
2040 | name = "tracing-subscriber" | 2215 | name = "tracing-subscriber" |
2041 | version = "0.3.17" | 2216 | version = "0.3.18" |
2042 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2217 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2043 | checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" | 2218 | checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" |
2044 | dependencies = [ | 2219 | dependencies = [ |
2045 | "matchers", | 2220 | "matchers", |
2046 | "nu-ansi-term", | 2221 | "nu-ansi-term", |
@@ -2056,16 +2231,10 @@ dependencies = [ | |||
2056 | ] | 2231 | ] |
2057 | 2232 | ||
2058 | [[package]] | 2233 | [[package]] |
2059 | name = "try-lock" | ||
2060 | version = "0.2.4" | ||
2061 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2062 | checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" | ||
2063 | |||
2064 | [[package]] | ||
2065 | name = "tungstenite" | 2234 | name = "tungstenite" |
2066 | version = "0.20.1" | 2235 | version = "0.21.0" |
2067 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2236 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2068 | checksum = "9e3dac10fd62eaf6617d3a904ae222845979aec67c615d1c842b4002c7666fb9" | 2237 | checksum = "9ef1a641ea34f399a848dea702823bbecfb4c486f911735368f1f137cb8257e1" |
2069 | dependencies = [ | 2238 | dependencies = [ |
2070 | "byteorder", | 2239 | "byteorder", |
2071 | "bytes", | 2240 | "bytes", |
@@ -2094,9 +2263,9 @@ checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" | |||
2094 | 2263 | ||
2095 | [[package]] | 2264 | [[package]] |
2096 | name = "unicode-bidi" | 2265 | name = "unicode-bidi" |
2097 | version = "0.3.13" | 2266 | version = "0.3.15" |
2098 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2267 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2099 | checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" | 2268 | checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" |
2100 | 2269 | ||
2101 | [[package]] | 2270 | [[package]] |
2102 | name = "unicode-ident" | 2271 | name = "unicode-ident" |
@@ -2115,9 +2284,9 @@ dependencies = [ | |||
2115 | 2284 | ||
2116 | [[package]] | 2285 | [[package]] |
2117 | name = "unicode-segmentation" | 2286 | name = "unicode-segmentation" |
2118 | version = "1.10.1" | 2287 | version = "1.11.0" |
2119 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2288 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2120 | checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" | 2289 | checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" |
2121 | 2290 | ||
2122 | [[package]] | 2291 | [[package]] |
2123 | name = "unicode_categories" | 2292 | name = "unicode_categories" |
@@ -2127,9 +2296,9 @@ checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" | |||
2127 | 2296 | ||
2128 | [[package]] | 2297 | [[package]] |
2129 | name = "url" | 2298 | name = "url" |
2130 | version = "2.4.1" | 2299 | version = "2.5.0" |
2131 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2300 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2132 | checksum = "143b538f18257fac9cad154828a57c6bf5157e1aa604d4816b5995bf6de87ae5" | 2301 | checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" |
2133 | dependencies = [ | 2302 | dependencies = [ |
2134 | "form_urlencoded", | 2303 | "form_urlencoded", |
2135 | "idna", | 2304 | "idna", |
@@ -2137,6 +2306,12 @@ dependencies = [ | |||
2137 | ] | 2306 | ] |
2138 | 2307 | ||
2139 | [[package]] | 2308 | [[package]] |
2309 | name = "urlencoding" | ||
2310 | version = "2.1.3" | ||
2311 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2312 | checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" | ||
2313 | |||
2314 | [[package]] | ||
2140 | name = "utf-8" | 2315 | name = "utf-8" |
2141 | version = "0.7.6" | 2316 | version = "0.7.6" |
2142 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2317 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -2144,9 +2319,9 @@ checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" | |||
2144 | 2319 | ||
2145 | [[package]] | 2320 | [[package]] |
2146 | name = "uuid" | 2321 | name = "uuid" |
2147 | version = "1.5.0" | 2322 | version = "1.7.0" |
2148 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2323 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2149 | checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" | 2324 | checksum = "f00cc9702ca12d3c81455259621e676d0f7251cec66a21e98fe2e9a37db93b2a" |
2150 | dependencies = [ | 2325 | dependencies = [ |
2151 | "getrandom", | 2326 | "getrandom", |
2152 | "rand", | 2327 | "rand", |
@@ -2171,15 +2346,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
2171 | checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" | 2346 | checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" |
2172 | 2347 | ||
2173 | [[package]] | 2348 | [[package]] |
2174 | name = "want" | ||
2175 | version = "0.3.1" | ||
2176 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2177 | checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" | ||
2178 | dependencies = [ | ||
2179 | "try-lock", | ||
2180 | ] | ||
2181 | |||
2182 | [[package]] | ||
2183 | name = "wasi" | 2349 | name = "wasi" |
2184 | version = "0.11.0+wasi-snapshot-preview1" | 2350 | version = "0.11.0+wasi-snapshot-preview1" |
2185 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2351 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -2187,13 +2353,13 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" | |||
2187 | 2353 | ||
2188 | [[package]] | 2354 | [[package]] |
2189 | name = "webol" | 2355 | name = "webol" |
2190 | version = "0.3.0" | 2356 | version = "0.3.1" |
2191 | dependencies = [ | 2357 | dependencies = [ |
2192 | "axum", | 2358 | "axum", |
2193 | "axum-macros", | 2359 | "axum-macros", |
2360 | "color-eyre", | ||
2194 | "config", | 2361 | "config", |
2195 | "dashmap", | 2362 | "dashmap", |
2196 | "once_cell", | ||
2197 | "serde", | 2363 | "serde", |
2198 | "serde_json", | 2364 | "serde_json", |
2199 | "sqlx", | 2365 | "sqlx", |
@@ -2239,7 +2405,16 @@ version = "0.48.0" | |||
2239 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2405 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2240 | checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" | 2406 | checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" |
2241 | dependencies = [ | 2407 | dependencies = [ |
2242 | "windows-targets", | 2408 | "windows-targets 0.48.5", |
2409 | ] | ||
2410 | |||
2411 | [[package]] | ||
2412 | name = "windows-sys" | ||
2413 | version = "0.52.0" | ||
2414 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2415 | checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" | ||
2416 | dependencies = [ | ||
2417 | "windows-targets 0.52.0", | ||
2243 | ] | 2418 | ] |
2244 | 2419 | ||
2245 | [[package]] | 2420 | [[package]] |
@@ -2248,13 +2423,28 @@ version = "0.48.5" | |||
2248 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2423 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2249 | checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" | 2424 | checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" |
2250 | dependencies = [ | 2425 | dependencies = [ |
2251 | "windows_aarch64_gnullvm", | 2426 | "windows_aarch64_gnullvm 0.48.5", |
2252 | "windows_aarch64_msvc", | 2427 | "windows_aarch64_msvc 0.48.5", |
2253 | "windows_i686_gnu", | 2428 | "windows_i686_gnu 0.48.5", |
2254 | "windows_i686_msvc", | 2429 | "windows_i686_msvc 0.48.5", |
2255 | "windows_x86_64_gnu", | 2430 | "windows_x86_64_gnu 0.48.5", |
2256 | "windows_x86_64_gnullvm", | 2431 | "windows_x86_64_gnullvm 0.48.5", |
2257 | "windows_x86_64_msvc", | 2432 | "windows_x86_64_msvc 0.48.5", |
2433 | ] | ||
2434 | |||
2435 | [[package]] | ||
2436 | name = "windows-targets" | ||
2437 | version = "0.52.0" | ||
2438 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2439 | checksum = "8a18201040b24831fbb9e4eb208f8892e1f50a37feb53cc7ff887feb8f50e7cd" | ||
2440 | dependencies = [ | ||
2441 | "windows_aarch64_gnullvm 0.52.0", | ||
2442 | "windows_aarch64_msvc 0.52.0", | ||
2443 | "windows_i686_gnu 0.52.0", | ||
2444 | "windows_i686_msvc 0.52.0", | ||
2445 | "windows_x86_64_gnu 0.52.0", | ||
2446 | "windows_x86_64_gnullvm 0.52.0", | ||
2447 | "windows_x86_64_msvc 0.52.0", | ||
2258 | ] | 2448 | ] |
2259 | 2449 | ||
2260 | [[package]] | 2450 | [[package]] |
@@ -2264,42 +2454,93 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
2264 | checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" | 2454 | checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" |
2265 | 2455 | ||
2266 | [[package]] | 2456 | [[package]] |
2457 | name = "windows_aarch64_gnullvm" | ||
2458 | version = "0.52.0" | ||
2459 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2460 | checksum = "cb7764e35d4db8a7921e09562a0304bf2f93e0a51bfccee0bd0bb0b666b015ea" | ||
2461 | |||
2462 | [[package]] | ||
2267 | name = "windows_aarch64_msvc" | 2463 | name = "windows_aarch64_msvc" |
2268 | version = "0.48.5" | 2464 | version = "0.48.5" |
2269 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2465 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2270 | checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" | 2466 | checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" |
2271 | 2467 | ||
2272 | [[package]] | 2468 | [[package]] |
2469 | name = "windows_aarch64_msvc" | ||
2470 | version = "0.52.0" | ||
2471 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2472 | checksum = "bbaa0368d4f1d2aaefc55b6fcfee13f41544ddf36801e793edbbfd7d7df075ef" | ||
2473 | |||
2474 | [[package]] | ||
2273 | name = "windows_i686_gnu" | 2475 | name = "windows_i686_gnu" |
2274 | version = "0.48.5" | 2476 | version = "0.48.5" |
2275 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2477 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2276 | checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" | 2478 | checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" |
2277 | 2479 | ||
2278 | [[package]] | 2480 | [[package]] |
2481 | name = "windows_i686_gnu" | ||
2482 | version = "0.52.0" | ||
2483 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2484 | checksum = "a28637cb1fa3560a16915793afb20081aba2c92ee8af57b4d5f28e4b3e7df313" | ||
2485 | |||
2486 | [[package]] | ||
2279 | name = "windows_i686_msvc" | 2487 | name = "windows_i686_msvc" |
2280 | version = "0.48.5" | 2488 | version = "0.48.5" |
2281 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2489 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2282 | checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" | 2490 | checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" |
2283 | 2491 | ||
2284 | [[package]] | 2492 | [[package]] |
2493 | name = "windows_i686_msvc" | ||
2494 | version = "0.52.0" | ||
2495 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2496 | checksum = "ffe5e8e31046ce6230cc7215707b816e339ff4d4d67c65dffa206fd0f7aa7b9a" | ||
2497 | |||
2498 | [[package]] | ||
2285 | name = "windows_x86_64_gnu" | 2499 | name = "windows_x86_64_gnu" |
2286 | version = "0.48.5" | 2500 | version = "0.48.5" |
2287 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2501 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2288 | checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" | 2502 | checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" |
2289 | 2503 | ||
2290 | [[package]] | 2504 | [[package]] |
2505 | name = "windows_x86_64_gnu" | ||
2506 | version = "0.52.0" | ||
2507 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2508 | checksum = "3d6fa32db2bc4a2f5abeacf2b69f7992cd09dca97498da74a151a3132c26befd" | ||
2509 | |||
2510 | [[package]] | ||
2291 | name = "windows_x86_64_gnullvm" | 2511 | name = "windows_x86_64_gnullvm" |
2292 | version = "0.48.5" | 2512 | version = "0.48.5" |
2293 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2513 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2294 | checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" | 2514 | checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" |
2295 | 2515 | ||
2296 | [[package]] | 2516 | [[package]] |
2517 | name = "windows_x86_64_gnullvm" | ||
2518 | version = "0.52.0" | ||
2519 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2520 | checksum = "1a657e1e9d3f514745a572a6846d3c7aa7dbe1658c056ed9c3344c4109a6949e" | ||
2521 | |||
2522 | [[package]] | ||
2297 | name = "windows_x86_64_msvc" | 2523 | name = "windows_x86_64_msvc" |
2298 | version = "0.48.5" | 2524 | version = "0.48.5" |
2299 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2525 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2300 | checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" | 2526 | checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" |
2301 | 2527 | ||
2302 | [[package]] | 2528 | [[package]] |
2529 | name = "windows_x86_64_msvc" | ||
2530 | version = "0.52.0" | ||
2531 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2532 | checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" | ||
2533 | |||
2534 | [[package]] | ||
2535 | name = "winnow" | ||
2536 | version = "0.5.39" | ||
2537 | source = "registry+https://github.com/rust-lang/crates.io-index" | ||
2538 | checksum = "5389a154b01683d28c77f8f68f49dea75f0a4da32557a58f68ee51ebba472d29" | ||
2539 | dependencies = [ | ||
2540 | "memchr", | ||
2541 | ] | ||
2542 | |||
2543 | [[package]] | ||
2303 | name = "yaml-rust" | 2544 | name = "yaml-rust" |
2304 | version = "0.4.5" | 2545 | version = "0.4.5" |
2305 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2546 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -2310,26 +2551,26 @@ dependencies = [ | |||
2310 | 2551 | ||
2311 | [[package]] | 2552 | [[package]] |
2312 | name = "zerocopy" | 2553 | name = "zerocopy" |
2313 | version = "0.7.23" | 2554 | version = "0.7.32" |
2314 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2555 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2315 | checksum = "e50cbb27c30666a6108abd6bc7577556265b44f243e2be89a8bc4e07a528c107" | 2556 | checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be" |
2316 | dependencies = [ | 2557 | dependencies = [ |
2317 | "zerocopy-derive", | 2558 | "zerocopy-derive", |
2318 | ] | 2559 | ] |
2319 | 2560 | ||
2320 | [[package]] | 2561 | [[package]] |
2321 | name = "zerocopy-derive" | 2562 | name = "zerocopy-derive" |
2322 | version = "0.7.23" | 2563 | version = "0.7.32" |
2323 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2564 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2324 | checksum = "a25f293fe55f0a48e7010d65552bb63704f6ceb55a1a385da10d41d8f78e4a3d" | 2565 | checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" |
2325 | dependencies = [ | 2566 | dependencies = [ |
2326 | "proc-macro2", | 2567 | "proc-macro2", |
2327 | "quote", | 2568 | "quote", |
2328 | "syn 2.0.38", | 2569 | "syn 2.0.48", |
2329 | ] | 2570 | ] |
2330 | 2571 | ||
2331 | [[package]] | 2572 | [[package]] |
2332 | name = "zeroize" | 2573 | name = "zeroize" |
2333 | version = "1.6.0" | 2574 | version = "1.7.0" |
2334 | source = "registry+https://github.com/rust-lang/crates.io-index" | 2575 | source = "registry+https://github.com/rust-lang/crates.io-index" |
2335 | checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" | 2576 | checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" |
@@ -1,22 +1,22 @@ | |||
1 | [package] | 1 | [package] |
2 | name = "webol" | 2 | name = "webol" |
3 | version = "0.3.0" | 3 | version = "0.3.1" |
4 | edition = "2021" | 4 | edition = "2021" |
5 | 5 | ||
6 | # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | 6 | # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html |
7 | 7 | ||
8 | [dependencies] | 8 | [dependencies] |
9 | axum = { version = "0.6.20", features = ["headers", "ws"] } | 9 | axum = { version = "0.7", features = ["ws"] } |
10 | tokio = { version = "1.33.0", features = ["macros", "rt-multi-thread"] } | 10 | tokio = { version = "1.34", features = ["macros", "rt-multi-thread"] } |
11 | tracing = "0.1.40" | 11 | tracing = "0.1" |
12 | tracing-subscriber = { version = "0.3.17", features = ["env-filter", "local-time", "time"] } | 12 | tracing-subscriber = { version = "0.3", features = ["env-filter", "local-time", "time"] } |
13 | time = { version = "0.3.30", features = ["macros"] } | 13 | time = { version = "0.3", features = ["macros"] } |
14 | serde = { version = "1.0.190", features = ["derive"] } | 14 | serde = { version = "1.0", features = ["derive"] } |
15 | serde_json = "1.0.107" | 15 | serde_json = "1.0" |
16 | config = "0.13.3" | 16 | config = "0.14" |
17 | once_cell = "1.18.0" | 17 | sqlx = { version = "0.7", features = ["postgres", "runtime-tokio"]} |
18 | sqlx = { version = "0.7.2", features = ["postgres", "runtime-tokio"]} | 18 | surge-ping = "0.8" |
19 | surge-ping = "0.8.0" | 19 | axum-macros = "0.4" |
20 | axum-macros = "0.3.8" | 20 | uuid = { version = "1.6", features = ["v4", "fast-rng"] } |
21 | uuid = { version = "1.5.0", features = ["v4", "fast-rng"] } | 21 | dashmap = "5.5" |
22 | dashmap = "5.5.3" | 22 | color-eyre = "0.6" |
@@ -5,22 +5,15 @@ RUN cd /tmp && \ | |||
5 | mkdir /dpkg && \ | 5 | mkdir /dpkg && \ |
6 | for deb in *.deb; do dpkg --extract $deb /dpkg || exit 10; done | 6 | for deb in *.deb; do dpkg --extract $deb /dpkg || exit 10; done |
7 | 7 | ||
8 | FROM lukemathwalker/cargo-chef:latest-rust-1.73.0 as chef | 8 | FROM rust:1.76 as builder |
9 | WORKDIR app | 9 | WORKDIR /app |
10 | |||
11 | FROM chef AS planner | ||
12 | COPY . . | 10 | COPY . . |
13 | RUN cargo chef prepare --recipe-path recipe.json | 11 | RUN cargo install --path . |
14 | 12 | ||
15 | FROM chef as builder | ||
16 | COPY --from=planner /app/recipe.json recipe.json | ||
17 | RUN cargo chef cook --release --recipe-path recipe.json | ||
18 | COPY . . | ||
19 | RUN cargo build --release | ||
20 | 13 | ||
21 | FROM gcr.io/distroless/cc | 14 | FROM gcr.io/distroless/cc |
22 | COPY --from=builder /app/target/release/webol / | 15 | COPY --from=builder /app/target/release/webol / |
23 | COPY --from=deb_extractor /dpkg / | 16 | COPY --from=deb_extractor /dpkg / |
24 | 17 | ||
25 | EXPOSE 7229 | 18 | EXPOSE 7229 |
26 | ENTRYPOINT ["./webol"] \ No newline at end of file | 19 | ENTRYPOINT ["./webol"] |
@@ -6,6 +6,4 @@ WEBOL_APIKEY: `String` | |||
6 | 6 | ||
7 | WEBOL_SERVERADDR: `Option<String>` (0.0.0.0:7229) | 7 | WEBOL_SERVERADDR: `Option<String>` (0.0.0.0:7229) |
8 | 8 | ||
9 | WEBOL_BINDADDR: `Option<String>` (0.0.0.0:1111) | 9 | WEBOL_PINGTIMEOUT: `Option<i64>` (10) |
10 | |||
11 | WEBOL_PINGTIMEOUT: `Option<i64>` (10) \ No newline at end of file | ||
diff --git a/src/auth.rs b/src/auth.rs index e4b1c2f..feca652 100644 --- a/src/auth.rs +++ b/src/auth.rs | |||
@@ -1,18 +1,15 @@ | |||
1 | use axum::headers::HeaderValue; | 1 | use axum::http::{StatusCode, HeaderValue}; |
2 | use axum::http::StatusCode; | ||
3 | use axum::http::header::ToStrError; | 2 | use axum::http::header::ToStrError; |
4 | use tracing::{debug, error, trace}; | 3 | use tracing::{debug, error, trace}; |
5 | use crate::auth::AuthError::{MissingSecret, WrongSecret}; | 4 | use crate::auth::Error::{MissingSecret, WrongSecret}; |
6 | use crate::config::SETTINGS; | 5 | use crate::config::Config; |
7 | 6 | ||
8 | pub fn auth(secret: Option<&HeaderValue>) -> Result<bool, AuthError> { | 7 | pub fn auth(config: &Config, secret: Option<&HeaderValue>) -> Result<bool, Error> { |
9 | debug!("auth request with secret {:?}", secret); | 8 | debug!("auth request with secret {:?}", secret); |
10 | if let Some(value) = secret { | 9 | if let Some(value) = secret { |
11 | trace!("value exists"); | 10 | trace!("value exists"); |
12 | let key = SETTINGS | 11 | let key = &config.apikey; |
13 | .get_string("apikey") | 12 | if value.to_str().map_err(Error::HeaderToStr)? == key.as_str() { |
14 | .map_err(AuthError::Config)?; | ||
15 | if value.to_str().map_err(AuthError::HeaderToStr)? == key.as_str() { | ||
16 | debug!("successful auth"); | 13 | debug!("successful auth"); |
17 | Ok(true) | 14 | Ok(true) |
18 | } else { | 15 | } else { |
@@ -26,22 +23,17 @@ pub fn auth(secret: Option<&HeaderValue>) -> Result<bool, AuthError> { | |||
26 | } | 23 | } |
27 | 24 | ||
28 | #[derive(Debug)] | 25 | #[derive(Debug)] |
29 | pub enum AuthError { | 26 | pub enum Error { |
30 | WrongSecret, | 27 | WrongSecret, |
31 | MissingSecret, | 28 | MissingSecret, |
32 | Config(config::ConfigError), | ||
33 | HeaderToStr(ToStrError) | 29 | HeaderToStr(ToStrError) |
34 | } | 30 | } |
35 | 31 | ||
36 | impl AuthError { | 32 | impl Error { |
37 | pub fn get(self) -> (StatusCode, &'static str) { | 33 | pub fn get(self) -> (StatusCode, &'static str) { |
38 | match self { | 34 | match self { |
39 | Self::WrongSecret => (StatusCode::UNAUTHORIZED, "Wrong credentials"), | 35 | Self::WrongSecret => (StatusCode::UNAUTHORIZED, "Wrong credentials"), |
40 | Self::MissingSecret => (StatusCode::BAD_REQUEST, "Missing credentials"), | 36 | Self::MissingSecret => (StatusCode::BAD_REQUEST, "Missing credentials"), |
41 | Self::Config(err) => { | ||
42 | error!("server error: {}", err.to_string()); | ||
43 | (StatusCode::INTERNAL_SERVER_ERROR, "Server Error") | ||
44 | }, | ||
45 | Self::HeaderToStr(err) => { | 37 | Self::HeaderToStr(err) => { |
46 | error!("server error: {}", err.to_string()); | 38 | error!("server error: {}", err.to_string()); |
47 | (StatusCode::INTERNAL_SERVER_ERROR, "Server Error") | 39 | (StatusCode::INTERNAL_SERVER_ERROR, "Server Error") |
diff --git a/src/config.rs b/src/config.rs index 4c79810..4319ffc 100644 --- a/src/config.rs +++ b/src/config.rs | |||
@@ -1,11 +1,25 @@ | |||
1 | use config::Config; | 1 | use config::File; |
2 | use once_cell::sync::Lazy; | 2 | use serde::Deserialize; |
3 | 3 | ||
4 | pub static SETTINGS: Lazy<Config> = Lazy::new(setup); | 4 | #[derive(Debug, Clone, Deserialize)] |
5 | pub struct Config { | ||
6 | pub database_url: String, | ||
7 | pub apikey: String, | ||
8 | pub serveraddr: String, | ||
9 | pub pingtimeout: i64, | ||
10 | } | ||
11 | |||
12 | impl Config { | ||
13 | pub fn load() -> Result<Self, config::ConfigError> { | ||
14 | let config = config::Config::builder() | ||
15 | .set_default("serveraddr", "0.0.0.0:7229")? | ||
16 | .set_default("pingtimeout", 10)? | ||
17 | .add_source(File::with_name("config.toml").required(false)) | ||
18 | .add_source(File::with_name("config.dev.toml").required(false)) | ||
19 | .add_source(config::Environment::with_prefix("WEBOL").prefix_separator("_")) | ||
20 | .build()?; | ||
21 | |||
22 | config.try_deserialize() | ||
23 | } | ||
24 | } | ||
5 | 25 | ||
6 | fn setup() -> Config { | ||
7 | Config::builder() | ||
8 | .add_source(config::Environment::with_prefix("WEBOL").separator("_")) | ||
9 | .build() | ||
10 | .unwrap() | ||
11 | } \ No newline at end of file | ||
@@ -1,13 +1,7 @@ | |||
1 | #[cfg(debug_assertions)] | ||
2 | use std::env; | ||
3 | |||
4 | use serde::Serialize; | 1 | use serde::Serialize; |
5 | use sqlx::{PgPool, postgres::PgPoolOptions}; | 2 | use sqlx::{PgPool, postgres::PgPoolOptions}; |
6 | use tracing::{debug, info}; | 3 | use tracing::{debug, info}; |
7 | 4 | ||
8 | #[cfg(not(debug_assertions))] | ||
9 | use crate::config::SETTINGS; | ||
10 | |||
11 | #[derive(Serialize, Debug)] | 5 | #[derive(Serialize, Debug)] |
12 | pub struct Device { | 6 | pub struct Device { |
13 | pub id: String, | 7 | pub id: String, |
@@ -17,18 +11,12 @@ pub struct Device { | |||
17 | pub times: Option<Vec<i64>> | 11 | pub times: Option<Vec<i64>> |
18 | } | 12 | } |
19 | 13 | ||
20 | pub async fn init_db_pool() -> PgPool { | 14 | pub async fn init_db_pool(db_url: &str) -> PgPool { |
21 | #[cfg(not(debug_assertions))] | ||
22 | let db_url = SETTINGS.get_string("database.url").unwrap(); | ||
23 | |||
24 | #[cfg(debug_assertions)] | ||
25 | let db_url = env::var("DATABASE_URL").unwrap(); | ||
26 | |||
27 | debug!("attempt to connect dbPool to '{}'", db_url); | 15 | debug!("attempt to connect dbPool to '{}'", db_url); |
28 | 16 | ||
29 | let pool = PgPoolOptions::new() | 17 | let pool = PgPoolOptions::new() |
30 | .max_connections(5) | 18 | .max_connections(5) |
31 | .connect(&db_url) | 19 | .connect(db_url) |
32 | .await | 20 | .await |
33 | .unwrap(); | 21 | .unwrap(); |
34 | 22 | ||
diff --git a/src/error.rs b/src/error.rs index 5b82534..56d6c52 100644 --- a/src/error.rs +++ b/src/error.rs | |||
@@ -4,10 +4,10 @@ use axum::Json; | |||
4 | use axum::response::{IntoResponse, Response}; | 4 | use axum::response::{IntoResponse, Response}; |
5 | use serde_json::json; | 5 | use serde_json::json; |
6 | use tracing::error; | 6 | use tracing::error; |
7 | use crate::auth::AuthError; | 7 | use crate::auth::Error as AuthError; |
8 | 8 | ||
9 | #[derive(Debug)] | 9 | #[derive(Debug)] |
10 | pub enum WebolError { | 10 | pub enum Error { |
11 | Generic, | 11 | Generic, |
12 | Auth(AuthError), | 12 | Auth(AuthError), |
13 | DB(sqlx::Error), | 13 | DB(sqlx::Error), |
@@ -16,7 +16,7 @@ pub enum WebolError { | |||
16 | Broadcast(io::Error), | 16 | Broadcast(io::Error), |
17 | } | 17 | } |
18 | 18 | ||
19 | impl IntoResponse for WebolError { | 19 | impl IntoResponse for Error { |
20 | fn into_response(self) -> Response { | 20 | fn into_response(self) -> Response { |
21 | let (status, error_message) = match self { | 21 | let (status, error_message) = match self { |
22 | Self::Auth(err) => { | 22 | Self::Auth(err) => { |
@@ -45,4 +45,4 @@ impl IntoResponse for WebolError { | |||
45 | })); | 45 | })); |
46 | (status, body).into_response() | 46 | (status, body).into_response() |
47 | } | 47 | } |
48 | } \ No newline at end of file | 48 | } |
diff --git a/src/main.rs b/src/main.rs index e96b736..4ef129b 100644 --- a/src/main.rs +++ b/src/main.rs | |||
@@ -8,12 +8,12 @@ use time::util::local_offset; | |||
8 | use tokio::sync::broadcast::{channel, Sender}; | 8 | use tokio::sync::broadcast::{channel, Sender}; |
9 | use tracing::{info, level_filters::LevelFilter}; | 9 | use tracing::{info, level_filters::LevelFilter}; |
10 | use tracing_subscriber::{EnvFilter, fmt::{self, time::LocalTime}, prelude::*}; | 10 | use tracing_subscriber::{EnvFilter, fmt::{self, time::LocalTime}, prelude::*}; |
11 | use crate::config::SETTINGS; | 11 | use crate::config::Config; |
12 | use crate::db::init_db_pool; | 12 | use crate::db::init_db_pool; |
13 | use crate::routes::device::{get_device, post_device, put_device}; | 13 | use crate::routes::device; |
14 | use crate::routes::start::start; | 14 | use crate::routes::start::start; |
15 | use crate::routes::status::status; | 15 | use crate::routes::status::status; |
16 | use crate::services::ping::{BroadcastCommands, PingMap}; | 16 | use crate::services::ping::{BroadcastCommands, StatusMap}; |
17 | 17 | ||
18 | mod auth; | 18 | mod auth; |
19 | mod config; | 19 | mod config; |
@@ -24,7 +24,10 @@ mod error; | |||
24 | mod services; | 24 | mod services; |
25 | 25 | ||
26 | #[tokio::main] | 26 | #[tokio::main] |
27 | async fn main() { | 27 | async fn main() -> color_eyre::eyre::Result<()> { |
28 | |||
29 | color_eyre::install()?; | ||
30 | |||
28 | unsafe { local_offset::set_soundness(local_offset::Soundness::Unsound); } | 31 | unsafe { local_offset::set_soundness(local_offset::Soundness::Unsound); } |
29 | let time_format = | 32 | let time_format = |
30 | time::macros::format_description!("[year]-[month]-[day] [hour]:[minute]:[second]"); | 33 | time::macros::format_description!("[year]-[month]-[day] [hour]:[minute]:[second]"); |
@@ -43,35 +46,39 @@ async fn main() { | |||
43 | 46 | ||
44 | let version = env!("CARGO_PKG_VERSION"); | 47 | let version = env!("CARGO_PKG_VERSION"); |
45 | 48 | ||
49 | let config = Config::load()?; | ||
50 | |||
46 | info!("start webol v{}", version); | 51 | info!("start webol v{}", version); |
47 | 52 | ||
48 | let db = init_db_pool().await; | 53 | let db = init_db_pool(&config.database_url).await; |
49 | sqlx::migrate!().run(&db).await.unwrap(); | 54 | sqlx::migrate!().run(&db).await.unwrap(); |
50 | 55 | ||
51 | let (tx, _) = channel(32); | 56 | let (tx, _) = channel(32); |
52 | 57 | ||
53 | let ping_map: PingMap = DashMap::new(); | 58 | let ping_map: StatusMap = DashMap::new(); |
54 | 59 | ||
55 | let shared_state = Arc::new(AppState { db, ping_send: tx, ping_map }); | 60 | let shared_state = Arc::new(AppState { db, config: config.clone(), ping_send: tx, ping_map }); |
56 | 61 | ||
57 | let app = Router::new() | 62 | let app = Router::new() |
58 | .route("/start", post(start)) | 63 | .route("/start", post(start)) |
59 | .route("/device", get(get_device)) | 64 | .route("/device", get(device::get)) |
60 | .route("/device", put(put_device)) | 65 | .route("/device", put(device::put)) |
61 | .route("/device", post(post_device)) | 66 | .route("/device", post(device::post)) |
62 | .route("/status", get(status)) | 67 | .route("/status", get(status)) |
63 | .with_state(shared_state); | 68 | .with_state(shared_state); |
64 | 69 | ||
65 | let addr = SETTINGS.get_string("serveraddr").unwrap_or("0.0.0.0:7229".to_string()); | 70 | let addr = config.serveraddr; |
66 | info!("start server on {}", addr); | 71 | info!("start server on {}", addr); |
67 | axum::Server::bind(&addr.parse().unwrap()) | 72 | let listener = tokio::net::TcpListener::bind(addr) |
68 | .serve(app.into_make_service()) | 73 | .await?; |
69 | .await | 74 | axum::serve(listener, app).await?; |
70 | .unwrap(); | 75 | |
76 | Ok(()) | ||
71 | } | 77 | } |
72 | 78 | ||
73 | pub struct AppState { | 79 | pub struct AppState { |
74 | db: PgPool, | 80 | db: PgPool, |
81 | config: Config, | ||
75 | ping_send: Sender<BroadcastCommands>, | 82 | ping_send: Sender<BroadcastCommands>, |
76 | ping_map: PingMap, | 83 | ping_map: StatusMap, |
77 | } \ No newline at end of file | 84 | } |
diff --git a/src/routes/device.rs b/src/routes/device.rs index 678d117..c85df1b 100644 --- a/src/routes/device.rs +++ b/src/routes/device.rs | |||
@@ -1,18 +1,18 @@ | |||
1 | use std::sync::Arc; | 1 | use std::sync::Arc; |
2 | use axum::extract::State; | 2 | use axum::extract::State; |
3 | use axum::headers::HeaderMap; | ||
4 | use axum::Json; | 3 | use axum::Json; |
4 | use axum::http::HeaderMap; | ||
5 | use serde::{Deserialize, Serialize}; | 5 | use serde::{Deserialize, Serialize}; |
6 | use serde_json::{json, Value}; | 6 | use serde_json::{json, Value}; |
7 | use tracing::{debug, info}; | 7 | use tracing::{debug, info}; |
8 | use crate::auth::auth; | 8 | use crate::auth::auth; |
9 | use crate::db::Device; | 9 | use crate::db::Device; |
10 | use crate::error::WebolError; | 10 | use crate::error::Error; |
11 | 11 | ||
12 | pub async fn get_device(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<GetDevicePayload>) -> Result<Json<Value>, WebolError> { | 12 | pub async fn get(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<GetDevicePayload>) -> Result<Json<Value>, Error> { |
13 | info!("add device {}", payload.id); | 13 | info!("add device {}", payload.id); |
14 | let secret = headers.get("authorization"); | 14 | let secret = headers.get("authorization"); |
15 | if auth(secret).map_err(WebolError::Auth)? { | 15 | if auth(&state.config, secret).map_err(Error::Auth)? { |
16 | let device = sqlx::query_as!( | 16 | let device = sqlx::query_as!( |
17 | Device, | 17 | Device, |
18 | r#" | 18 | r#" |
@@ -21,13 +21,13 @@ pub async fn get_device(State(state): State<Arc<crate::AppState>>, headers: Head | |||
21 | WHERE id = $1; | 21 | WHERE id = $1; |
22 | "#, | 22 | "#, |
23 | payload.id | 23 | payload.id |
24 | ).fetch_one(&state.db).await.map_err(WebolError::DB)?; | 24 | ).fetch_one(&state.db).await.map_err(Error::DB)?; |
25 | 25 | ||
26 | debug!("got device {:?}", device); | 26 | debug!("got device {:?}", device); |
27 | 27 | ||
28 | Ok(Json(json!(device))) | 28 | Ok(Json(json!(device))) |
29 | } else { | 29 | } else { |
30 | Err(WebolError::Generic) | 30 | Err(Error::Generic) |
31 | } | 31 | } |
32 | } | 32 | } |
33 | 33 | ||
@@ -36,10 +36,10 @@ pub struct GetDevicePayload { | |||
36 | id: String, | 36 | id: String, |
37 | } | 37 | } |
38 | 38 | ||
39 | pub async fn put_device(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<PutDevicePayload>) -> Result<Json<Value>, WebolError> { | 39 | pub async fn put(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<PutDevicePayload>) -> Result<Json<Value>, Error> { |
40 | info!("add device {} ({}, {}, {})", payload.id, payload.mac, payload.broadcast_addr, payload.ip); | 40 | info!("add device {} ({}, {}, {})", payload.id, payload.mac, payload.broadcast_addr, payload.ip); |
41 | let secret = headers.get("authorization"); | 41 | let secret = headers.get("authorization"); |
42 | if auth(secret).map_err(WebolError::Auth)? { | 42 | if auth(&state.config, secret).map_err(Error::Auth)? { |
43 | sqlx::query!( | 43 | sqlx::query!( |
44 | r#" | 44 | r#" |
45 | INSERT INTO devices (id, mac, broadcast_addr, ip) | 45 | INSERT INTO devices (id, mac, broadcast_addr, ip) |
@@ -49,11 +49,11 @@ pub async fn put_device(State(state): State<Arc<crate::AppState>>, headers: Head | |||
49 | payload.mac, | 49 | payload.mac, |
50 | payload.broadcast_addr, | 50 | payload.broadcast_addr, |
51 | payload.ip | 51 | payload.ip |
52 | ).execute(&state.db).await.map_err(WebolError::DB)?; | 52 | ).execute(&state.db).await.map_err(Error::DB)?; |
53 | 53 | ||
54 | Ok(Json(json!(PutDeviceResponse { success: true }))) | 54 | Ok(Json(json!(PutDeviceResponse { success: true }))) |
55 | } else { | 55 | } else { |
56 | Err(WebolError::Generic) | 56 | Err(Error::Generic) |
57 | } | 57 | } |
58 | } | 58 | } |
59 | 59 | ||
@@ -70,10 +70,10 @@ pub struct PutDeviceResponse { | |||
70 | success: bool | 70 | success: bool |
71 | } | 71 | } |
72 | 72 | ||
73 | pub async fn post_device(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<PostDevicePayload>) -> Result<Json<Value>, WebolError> { | 73 | pub async fn post(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<PostDevicePayload>) -> Result<Json<Value>, Error> { |
74 | info!("edit device {} ({}, {}, {})", payload.id, payload.mac, payload.broadcast_addr, payload.ip); | 74 | info!("edit device {} ({}, {}, {})", payload.id, payload.mac, payload.broadcast_addr, payload.ip); |
75 | let secret = headers.get("authorization"); | 75 | let secret = headers.get("authorization"); |
76 | if auth(secret).map_err(WebolError::Auth)? { | 76 | if auth(&state.config, secret).map_err(Error::Auth)? { |
77 | let device = sqlx::query_as!( | 77 | let device = sqlx::query_as!( |
78 | Device, | 78 | Device, |
79 | r#" | 79 | r#" |
@@ -85,11 +85,11 @@ pub async fn post_device(State(state): State<Arc<crate::AppState>>, headers: Hea | |||
85 | payload.broadcast_addr, | 85 | payload.broadcast_addr, |
86 | payload.ip, | 86 | payload.ip, |
87 | payload.id | 87 | payload.id |
88 | ).fetch_one(&state.db).await.map_err(WebolError::DB)?; | 88 | ).fetch_one(&state.db).await.map_err(Error::DB)?; |
89 | 89 | ||
90 | Ok(Json(json!(device))) | 90 | Ok(Json(json!(device))) |
91 | } else { | 91 | } else { |
92 | Err(WebolError::Generic) | 92 | Err(Error::Generic) |
93 | } | 93 | } |
94 | } | 94 | } |
95 | 95 | ||
diff --git a/src/routes/start.rs b/src/routes/start.rs index 1555db3..ce95bf3 100644 --- a/src/routes/start.rs +++ b/src/routes/start.rs | |||
@@ -1,23 +1,26 @@ | |||
1 | use axum::headers::HeaderMap; | 1 | use crate::auth::auth; |
2 | use crate::db::Device; | ||
3 | use crate::error::Error; | ||
4 | use crate::services::ping::Value as PingValue; | ||
5 | use crate::wol::{create_buffer, send_packet}; | ||
6 | use axum::extract::State; | ||
7 | use axum::http::HeaderMap; | ||
2 | use axum::Json; | 8 | use axum::Json; |
3 | use serde::{Deserialize, Serialize}; | 9 | use serde::{Deserialize, Serialize}; |
4 | use std::sync::Arc; | ||
5 | use axum::extract::State; | ||
6 | use serde_json::{json, Value}; | 10 | use serde_json::{json, Value}; |
11 | use std::sync::Arc; | ||
7 | use tracing::{debug, info}; | 12 | use tracing::{debug, info}; |
8 | use uuid::Uuid; | 13 | use uuid::Uuid; |
9 | use crate::auth::auth; | ||
10 | use crate::config::SETTINGS; | ||
11 | use crate::wol::{create_buffer, send_packet}; | ||
12 | use crate::db::Device; | ||
13 | use crate::error::WebolError; | ||
14 | use crate::services::ping::PingValue; | ||
15 | 14 | ||
16 | #[axum_macros::debug_handler] | 15 | #[axum_macros::debug_handler] |
17 | pub async fn start(State(state): State<Arc<crate::AppState>>, headers: HeaderMap, Json(payload): Json<StartPayload>) -> Result<Json<Value>, WebolError> { | 16 | pub async fn start( |
17 | State(state): State<Arc<crate::AppState>>, | ||
18 | headers: HeaderMap, | ||
19 | Json(payload): Json<Payload>, | ||
20 | ) -> Result<Json<Value>, Error> { | ||
18 | info!("POST request"); | 21 | info!("POST request"); |
19 | let secret = headers.get("authorization"); | 22 | let secret = headers.get("authorization"); |
20 | let authorized = auth(secret).map_err(WebolError::Auth)?; | 23 | let authorized = auth(&state.config, secret).map_err(Error::Auth)?; |
21 | if authorized { | 24 | if authorized { |
22 | let device = sqlx::query_as!( | 25 | let device = sqlx::query_as!( |
23 | Device, | 26 | Device, |
@@ -27,18 +30,19 @@ pub async fn start(State(state): State<Arc<crate::AppState>>, headers: HeaderMap | |||
27 | WHERE id = $1; | 30 | WHERE id = $1; |
28 | "#, | 31 | "#, |
29 | payload.id | 32 | payload.id |
30 | ).fetch_one(&state.db).await.map_err(WebolError::DB)?; | 33 | ) |
34 | .fetch_one(&state.db) | ||
35 | .await | ||
36 | .map_err(Error::DB)?; | ||
31 | 37 | ||
32 | info!("starting {}", device.id); | 38 | info!("starting {}", device.id); |
33 | 39 | ||
34 | let bind_addr = SETTINGS | 40 | let bind_addr = "0.0.0.0:0"; |
35 | .get_string("bindaddr") | ||
36 | .unwrap_or("0.0.0.0:1111".to_string()); | ||
37 | 41 | ||
38 | let _ = send_packet( | 42 | let _ = send_packet( |
39 | &bind_addr.parse().map_err(WebolError::IpParse)?, | 43 | &bind_addr.parse().map_err(Error::IpParse)?, |
40 | &device.broadcast_addr.parse().map_err(WebolError::IpParse)?, | 44 | &device.broadcast_addr.parse().map_err(Error::IpParse)?, |
41 | create_buffer(&device.mac)? | 45 | &create_buffer(&device.mac)?, |
42 | )?; | 46 | )?; |
43 | let dev_id = device.id.clone(); | 47 | let dev_id = device.id.clone(); |
44 | let uuid = if payload.ping.is_some_and(|ping| ping) { | 48 | let uuid = if payload.ping.is_some_and(|ping| ping) { |
@@ -49,7 +53,7 @@ pub async fn start(State(state): State<Arc<crate::AppState>>, headers: HeaderMap | |||
49 | uuid = Some(key); | 53 | uuid = Some(key); |
50 | break; | 54 | break; |
51 | } | 55 | } |
52 | }; | 56 | } |
53 | let uuid_gen = match uuid { | 57 | let uuid_gen = match uuid { |
54 | Some(u) => u, | 58 | Some(u) => u, |
55 | None => Uuid::new_v4().to_string(), | 59 | None => Uuid::new_v4().to_string(), |
@@ -58,26 +62,46 @@ pub async fn start(State(state): State<Arc<crate::AppState>>, headers: HeaderMap | |||
58 | 62 | ||
59 | tokio::spawn(async move { | 63 | tokio::spawn(async move { |
60 | debug!("init ping service"); | 64 | debug!("init ping service"); |
61 | state.ping_map.insert(uuid_gen.clone(), PingValue { ip: device.ip.clone(), online: false }); | 65 | state.ping_map.insert( |
66 | uuid_gen.clone(), | ||
67 | PingValue { | ||
68 | ip: device.ip.clone(), | ||
69 | online: false, | ||
70 | }, | ||
71 | ); | ||
62 | 72 | ||
63 | crate::services::ping::spawn(state.ping_send.clone(), device, uuid_gen.clone(), &state.ping_map, &state.db).await | 73 | crate::services::ping::spawn( |
74 | state.ping_send.clone(), | ||
75 | &state.config, | ||
76 | device, | ||
77 | uuid_gen.clone(), | ||
78 | &state.ping_map, | ||
79 | &state.db, | ||
80 | ) | ||
81 | .await; | ||
64 | }); | 82 | }); |
65 | Some(uuid_genc) | 83 | Some(uuid_genc) |
66 | } else { None }; | 84 | } else { |
67 | Ok(Json(json!(StartResponse { id: dev_id, boot: true, uuid }))) | 85 | None |
86 | }; | ||
87 | Ok(Json(json!(Response { | ||
88 | id: dev_id, | ||
89 | boot: true, | ||
90 | uuid | ||
91 | }))) | ||
68 | } else { | 92 | } else { |
69 | Err(WebolError::Generic) | 93 | Err(Error::Generic) |
70 | } | 94 | } |
71 | } | 95 | } |
72 | 96 | ||
73 | #[derive(Deserialize)] | 97 | #[derive(Deserialize)] |
74 | pub struct StartPayload { | 98 | pub struct Payload { |
75 | id: String, | 99 | id: String, |
76 | ping: Option<bool>, | 100 | ping: Option<bool>, |
77 | } | 101 | } |
78 | 102 | ||
79 | #[derive(Serialize)] | 103 | #[derive(Serialize)] |
80 | struct StartResponse { | 104 | struct Response { |
81 | id: String, | 105 | id: String, |
82 | boot: bool, | 106 | boot: bool, |
83 | uuid: Option<String>, | 107 | uuid: Option<String>, |
diff --git a/src/routes/status.rs b/src/routes/status.rs index 45f3e51..31ef996 100644 --- a/src/routes/status.rs +++ b/src/routes/status.rs | |||
@@ -7,4 +7,4 @@ use crate::services::ping::status_websocket; | |||
7 | #[axum_macros::debug_handler] | 7 | #[axum_macros::debug_handler] |
8 | pub async fn status(State(state): State<Arc<AppState>>, ws: WebSocketUpgrade) -> Response { | 8 | pub async fn status(State(state): State<Arc<AppState>>, ws: WebSocketUpgrade) -> Response { |
9 | ws.on_upgrade(move |socket| status_websocket(socket, state)) | 9 | ws.on_upgrade(move |socket| status_websocket(socket, state)) |
10 | } \ No newline at end of file | 10 | } |
diff --git a/src/services/ping.rs b/src/services/ping.rs index c3bdced..9b164c8 100644 --- a/src/services/ping.rs +++ b/src/services/ping.rs | |||
@@ -2,26 +2,26 @@ use std::str::FromStr; | |||
2 | use std::net::IpAddr; | 2 | use std::net::IpAddr; |
3 | use std::sync::Arc; | 3 | use std::sync::Arc; |
4 | 4 | ||
5 | use axum::extract::{ws::WebSocket}; | 5 | use axum::extract::ws::WebSocket; |
6 | use axum::extract::ws::Message; | 6 | use axum::extract::ws::Message; |
7 | use dashmap::DashMap; | 7 | use dashmap::DashMap; |
8 | use sqlx::PgPool; | 8 | use sqlx::PgPool; |
9 | use time::{Duration, Instant}; | 9 | use time::{Duration, Instant}; |
10 | use tokio::sync::broadcast::{Sender}; | 10 | use tokio::sync::broadcast::Sender; |
11 | use tracing::{debug, error, trace}; | 11 | use tracing::{debug, error, trace}; |
12 | use crate::AppState; | 12 | use crate::AppState; |
13 | use crate::config::SETTINGS; | 13 | use crate::config::Config; |
14 | use crate::db::Device; | 14 | use crate::db::Device; |
15 | 15 | ||
16 | pub type PingMap = DashMap<String, PingValue>; | 16 | pub type StatusMap = DashMap<String, Value>; |
17 | 17 | ||
18 | #[derive(Debug, Clone)] | 18 | #[derive(Debug, Clone)] |
19 | pub struct PingValue { | 19 | pub struct Value { |
20 | pub ip: String, | 20 | pub ip: String, |
21 | pub online: bool | 21 | pub online: bool |
22 | } | 22 | } |
23 | 23 | ||
24 | pub async fn spawn(tx: Sender<BroadcastCommands>, device: Device, uuid: String, ping_map: &PingMap, db: &PgPool) { | 24 | pub async fn spawn(tx: Sender<BroadcastCommands>, config: &Config, device: Device, uuid: String, ping_map: &StatusMap, db: &PgPool) { |
25 | let timer = Instant::now(); | 25 | let timer = Instant::now(); |
26 | let payload = [0; 8]; | 26 | let payload = [0; 8]; |
27 | 27 | ||
@@ -40,7 +40,7 @@ pub async fn spawn(tx: Sender<BroadcastCommands>, device: Device, uuid: String, | |||
40 | error!("{}", ping.to_string()); | 40 | error!("{}", ping.to_string()); |
41 | msg = Some(BroadcastCommands::Error(uuid.clone())); | 41 | msg = Some(BroadcastCommands::Error(uuid.clone())); |
42 | } | 42 | } |
43 | if timer.elapsed() >= Duration::minutes(SETTINGS.get_int("pingtimeout").unwrap_or(10)) { | 43 | if timer.elapsed() >= Duration::minutes(config.pingtimeout) { |
44 | msg = Some(BroadcastCommands::Timeout(uuid.clone())); | 44 | msg = Some(BroadcastCommands::Timeout(uuid.clone())); |
45 | } | 45 | } |
46 | } else { | 46 | } else { |
@@ -63,7 +63,7 @@ pub async fn spawn(tx: Sender<BroadcastCommands>, device: Device, uuid: String, | |||
63 | timer.elapsed().whole_seconds(), | 63 | timer.elapsed().whole_seconds(), |
64 | device.id | 64 | device.id |
65 | ).execute(db).await.unwrap(); | 65 | ).execute(db).await.unwrap(); |
66 | ping_map.insert(uuid.clone(), PingValue { ip: device.ip.clone(), online: true }); | 66 | ping_map.insert(uuid.clone(), Value { ip: device.ip.clone(), online: true }); |
67 | tokio::time::sleep(tokio::time::Duration::from_secs(60)).await; | 67 | tokio::time::sleep(tokio::time::Duration::from_secs(60)).await; |
68 | } | 68 | } |
69 | trace!("remove {} from ping_map", uuid); | 69 | trace!("remove {} from ping_map", uuid); |
@@ -85,17 +85,14 @@ pub async fn status_websocket(mut socket: WebSocket, state: Arc<AppState>) { | |||
85 | trace!("Search for uuid: {}", uuid); | 85 | trace!("Search for uuid: {}", uuid); |
86 | 86 | ||
87 | let eta = get_eta(&state.db).await; | 87 | let eta = get_eta(&state.db).await; |
88 | let _ = socket.send(Message::Text(format!("eta_{}_{}", eta, uuid))).await; | 88 | let _ = socket.send(Message::Text(format!("eta_{eta}_{uuid}"))).await; |
89 | 89 | ||
90 | let device_exists = state.ping_map.contains_key(&uuid); | 90 | let device_exists = state.ping_map.contains_key(&uuid); |
91 | match device_exists { | 91 | if device_exists { |
92 | true => { | 92 | let _ = socket.send(process_device(state.clone(), uuid).await).await; |
93 | let _ = socket.send(process_device(state.clone(), uuid).await).await; | 93 | } else { |
94 | }, | 94 | debug!("didn't find any device"); |
95 | false => { | 95 | let _ = socket.send(Message::Text(format!("notfound_{uuid}"))).await; |
96 | debug!("didn't find any device"); | ||
97 | let _ = socket.send(Message::Text(format!("notfound_{}", uuid))).await; | ||
98 | }, | ||
99 | }; | 96 | }; |
100 | 97 | ||
101 | let _ = socket.close().await; | 98 | let _ = socket.close().await; |
@@ -110,7 +107,7 @@ async fn get_eta(db: &PgPool) -> i64 { | |||
110 | None => { vec![0] }, | 107 | None => { vec![0] }, |
111 | Some(t) => t, | 108 | Some(t) => t, |
112 | }; | 109 | }; |
113 | times.iter().sum::<i64>() / times.len() as i64 | 110 | times.iter().sum::<i64>() / i64::try_from(times.len()).unwrap() |
114 | 111 | ||
115 | } | 112 | } |
116 | 113 | ||
@@ -118,34 +115,31 @@ async fn process_device(state: Arc<AppState>, uuid: String) -> Message { | |||
118 | let pm = state.ping_map.clone().into_read_only(); | 115 | let pm = state.ping_map.clone().into_read_only(); |
119 | let device = pm.get(&uuid).expect("fatal error"); | 116 | let device = pm.get(&uuid).expect("fatal error"); |
120 | debug!("got device: {} (online: {})", device.ip, device.online); | 117 | debug!("got device: {} (online: {})", device.ip, device.online); |
121 | match device.online { | 118 | if device.online { |
122 | true => { | 119 | debug!("already started"); |
123 | debug!("already started"); | 120 | Message::Text(format!("start_{uuid}")) |
124 | Message::Text(format!("start_{}", uuid)) | 121 | } else { |
125 | }, | 122 | loop { |
126 | false => { | 123 | trace!("wait for tx message"); |
127 | loop{ | 124 | let message = state.ping_send.subscribe().recv().await.expect("fatal error"); |
128 | trace!("wait for tx message"); | 125 | trace!("got message {:?}", message); |
129 | let message = state.ping_send.subscribe().recv().await.expect("fatal error"); | 126 | return match message { |
130 | trace!("got message {:?}", message); | 127 | BroadcastCommands::Success(msg_uuid) => { |
131 | return match message { | 128 | if msg_uuid != uuid { continue; } |
132 | BroadcastCommands::Success(msg_uuid) => { | 129 | trace!("message == uuid success"); |
133 | if msg_uuid != uuid { continue; } | 130 | Message::Text(format!("start_{uuid}")) |
134 | trace!("message == uuid success"); | 131 | }, |
135 | Message::Text(format!("start_{}", uuid)) | 132 | BroadcastCommands::Timeout(msg_uuid) => { |
136 | }, | 133 | if msg_uuid != uuid { continue; } |
137 | BroadcastCommands::Timeout(msg_uuid) => { | 134 | trace!("message == uuid timeout"); |
138 | if msg_uuid != uuid { continue; } | 135 | Message::Text(format!("timeout_{uuid}")) |
139 | trace!("message == uuid timeout"); | 136 | }, |
140 | Message::Text(format!("timeout_{}", uuid)) | 137 | BroadcastCommands::Error(msg_uuid) => { |
141 | }, | 138 | if msg_uuid != uuid { continue; } |
142 | BroadcastCommands::Error(msg_uuid) => { | 139 | trace!("message == uuid error"); |
143 | if msg_uuid != uuid { continue; } | 140 | Message::Text(format!("error_{uuid}")) |
144 | trace!("message == uuid error"); | ||
145 | Message::Text(format!("error_{}", uuid)) | ||
146 | } | ||
147 | } | 141 | } |
148 | } | 142 | } |
149 | } | 143 | } |
150 | } | 144 | } |
151 | } \ No newline at end of file | 145 | } |
@@ -1,17 +1,17 @@ | |||
1 | use std::net::{SocketAddr, UdpSocket}; | 1 | use std::net::{SocketAddr, UdpSocket}; |
2 | 2 | ||
3 | use crate::error::WebolError; | 3 | use crate::error::Error; |
4 | 4 | ||
5 | /// Creates the magic packet from a mac address | 5 | /// Creates the magic packet from a mac address |
6 | /// | 6 | /// |
7 | /// # Panics | 7 | /// # Panics |
8 | /// | 8 | /// |
9 | /// Panics if `mac_addr` is an invalid mac | 9 | /// Panics if `mac_addr` is an invalid mac |
10 | pub fn create_buffer(mac_addr: &str) -> Result<Vec<u8>, WebolError> { | 10 | pub fn create_buffer(mac_addr: &str) -> Result<Vec<u8>, Error> { |
11 | let mut mac = Vec::new(); | 11 | let mut mac = Vec::new(); |
12 | let sp = mac_addr.split(':'); | 12 | let sp = mac_addr.split(':'); |
13 | for f in sp { | 13 | for f in sp { |
14 | mac.push(u8::from_str_radix(f, 16).map_err(WebolError::BufferParse)?) | 14 | mac.push(u8::from_str_radix(f, 16).map_err(Error::BufferParse)?); |
15 | }; | 15 | }; |
16 | let mut buf = vec![255; 6]; | 16 | let mut buf = vec![255; 6]; |
17 | for _ in 0..16 { | 17 | for _ in 0..16 { |
@@ -23,8 +23,8 @@ pub fn create_buffer(mac_addr: &str) -> Result<Vec<u8>, WebolError> { | |||
23 | } | 23 | } |
24 | 24 | ||
25 | /// Sends a buffer on UDP broadcast | 25 | /// Sends a buffer on UDP broadcast |
26 | pub fn send_packet(bind_addr: &SocketAddr, broadcast_addr: &SocketAddr, buffer: Vec<u8>) -> Result<usize, WebolError> { | 26 | pub fn send_packet(bind_addr: &SocketAddr, broadcast_addr: &SocketAddr, buffer: &[u8]) -> Result<usize, Error> { |
27 | let socket = UdpSocket::bind(bind_addr).map_err(WebolError::Broadcast)?; | 27 | let socket = UdpSocket::bind(bind_addr).map_err(Error::Broadcast)?; |
28 | socket.set_broadcast(true).map_err(WebolError::Broadcast)?; | 28 | socket.set_broadcast(true).map_err(Error::Broadcast)?; |
29 | socket.send_to(&buffer, broadcast_addr).map_err(WebolError::Broadcast) | 29 | socket.send_to(buffer, broadcast_addr).map_err(Error::Broadcast) |
30 | } | 30 | } |