commit a54ddfe59882553ea52753c79d6c7c6a85ce7f37
parent 5737be63081ea8258da93c9d7216d9761df92722
Author: Antoine A <>
Date: Fri, 28 Mar 2025 12:14:01 +0100
Update utils and use unix socket for postgresql connection
Diffstat:
15 files changed, 489 insertions(+), 465 deletions(-)
diff --git a/Cargo.lock b/Cargo.lock
@@ -94,23 +94,30 @@ dependencies = [
[[package]]
name = "anstyle-wincon"
-version = "3.0.6"
+version = "3.0.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2109dbce0e72be3ec00bed26e6a7479ca384ad226efdd66db8fa2e3a38c83125"
+checksum = "ca3534e77181a9cc07539ad51f2141fe32f6c3ffd4df76db8ad92346b003ae4e"
dependencies = [
"anstyle",
+ "once_cell",
"windows-sys 0.59.0",
]
[[package]]
+name = "anyhow"
+version = "1.0.97"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "dcfed56ad506cb2c684a14971b8861fdc3baaaae314b9e5f9bb532cbe3ba7a4f"
+
+[[package]]
name = "async-trait"
-version = "0.1.85"
+version = "0.1.88"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3f934833b4b7233644e5848f235df3f57ed8c80f1528a26c3dfa13d2147fa056"
+checksum = "e539d3fca749fcee5236ab05e93a52867dd549cc157c8cb7f99595f3cedffdb5"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -205,9 +212,9 @@ checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6"
[[package]]
name = "base64ct"
-version = "1.6.0"
+version = "1.7.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b"
+checksum = "89e25b6adfb930f02d1981565a6e5d9c547ac15a96606256d3b59040e5cd4ca3"
[[package]]
name = "bech32"
@@ -258,9 +265,9 @@ dependencies = [
[[package]]
name = "bitflags"
-version = "2.6.0"
+version = "2.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de"
+checksum = "5c8214115b7bf84099f1309324e63141d4c5d7cc26862f97a0a857dbefe165bd"
dependencies = [
"serde",
]
@@ -294,9 +301,9 @@ dependencies = [
[[package]]
name = "bumpalo"
-version = "3.16.0"
+version = "3.17.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c"
+checksum = "1628fb46dfa0b37568d12e5edd512553eccf6a22a78e8bde00bb4aed84d5bdbf"
[[package]]
name = "byteorder"
@@ -306,9 +313,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"
[[package]]
name = "bytes"
-version = "1.9.0"
+version = "1.10.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "325918d6fe32f23b19878fe4b34794ae41fc19ddbe53b10571a4874d44ffd39b"
+checksum = "d71b6127be86fdcfddb610f7182ac57211d4b18a3e9c82eb2d17662f2227ad6a"
[[package]]
name = "cast"
@@ -318,9 +325,9 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5"
[[package]]
name = "cc"
-version = "1.2.7"
+version = "1.2.17"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a012a0df96dd6d06ba9a1b29d6402d1a5d77c6befd2566afdc26e10603dc93d7"
+checksum = "1fcb57c740ae1daf453ae85f16e37396f672b039e00d9d866e07ddb24e328e3a"
dependencies = [
"shlex",
]
@@ -333,15 +340,15 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
[[package]]
name = "chrono"
-version = "0.4.39"
+version = "0.4.40"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7e36cc9d416881d2e24f9a963be5fb1cd90966419ac844274161d10488b3e825"
+checksum = "1a7964611d71df112cb1730f2ee67324fcf4d0fc6606acbbe9bfe06df124637c"
dependencies = [
"android-tzdata",
"iana-time-zone",
"num-traits",
"serde",
- "windows-targets 0.52.6",
+ "windows-link",
]
[[package]]
@@ -373,9 +380,9 @@ dependencies = [
[[package]]
name = "clap"
-version = "4.5.24"
+version = "4.5.34"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9560b07a799281c7e0958b9296854d6fafd4c5f31444a7e5bb1ad6dde5ccf1bd"
+checksum = "e958897981290da2a852763fe9cdb89cd36977a5d729023127095fa94d95e2ff"
dependencies = [
"clap_builder",
"clap_derive",
@@ -383,9 +390,9 @@ dependencies = [
[[package]]
name = "clap_builder"
-version = "4.5.24"
+version = "4.5.34"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "874e0dd3eb68bf99058751ac9712f622e61e6f393a94f7128fa26e3f02f5c7cd"
+checksum = "83b0f35019843db2160b5bb19ae09b4e6411ac33fc6a712003c33e03090e2489"
dependencies = [
"anstream",
"anstyle",
@@ -395,14 +402,14 @@ dependencies = [
[[package]]
name = "clap_derive"
-version = "4.5.24"
+version = "4.5.32"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "54b755194d6389280185988721fffba69495eed5ee9feeee9a599b53db80318c"
+checksum = "09176aae279615badda0765c0c0b3f6ed53f4709118af73cf4655d85d1530cd7"
dependencies = [
"heck",
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -413,9 +420,9 @@ checksum = "f46ad14479a25103f283c0f10005961cf086d8dc42205bb44c46ac563475dca6"
[[package]]
name = "clap_mangen"
-version = "0.2.25"
+version = "0.2.26"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "acbfe6ac42a2438d0968beba18e3c35cacf16b0c25310bc22b1f5f3cffff09f4"
+checksum = "724842fa9b144f9b89b3f3d371a89f3455eea660361d13a554f68f8ae5d6c13a"
dependencies = [
"clap",
"roff",
@@ -445,7 +452,7 @@ dependencies = [
"flexi_logger",
"log",
"postgres",
- "rand",
+ "rand 0.8.5",
"rust-ini",
"serde",
"serde_json",
@@ -470,9 +477,9 @@ dependencies = [
[[package]]
name = "console"
-version = "0.15.10"
+version = "0.15.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ea3c6ecd8059b57859df5c69830340ed3c41d30e3da0c1cbed90a96ac853041b"
+checksum = "054ccb5b10f9f2cbf51eb355ca1d05c2d279ce1804688d0db74b4733a5aeafd8"
dependencies = [
"encode_unicode",
"libc",
@@ -515,7 +522,7 @@ version = "0.1.16"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e"
dependencies = [
- "getrandom",
+ "getrandom 0.2.15",
"once_cell",
"tiny-keccak",
]
@@ -528,9 +535,9 @@ checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"
[[package]]
name = "cpufeatures"
-version = "0.2.16"
+version = "0.2.17"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "16b80225097f2e5ae4e7179dd2266824648f3e2f49d9134d584b76389d31c4c3"
+checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280"
dependencies = [
"libc",
]
@@ -631,9 +638,9 @@ checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28"
[[package]]
name = "crunchy"
-version = "0.2.2"
+version = "0.2.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7"
+checksum = "43da5946c66ffcc7745f48db692ffbb10a83bfe0afd96235c5c2a4fb23994929"
[[package]]
name = "crypto-common"
@@ -659,9 +666,9 @@ dependencies = [
[[package]]
name = "csv-core"
-version = "0.1.11"
+version = "0.1.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5efa2b3d7902f4b634a20cae3c9c4e6209dc4779feb6863329607560143efa70"
+checksum = "7d02f3b0da4c6504f86e9cd789d8dbafab48c2321be74e9987593de5a894d93d"
dependencies = [
"memchr",
]
@@ -689,7 +696,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -713,7 +720,7 @@ dependencies = [
"proc-macro2",
"quote",
"strsim",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -724,7 +731,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806"
dependencies = [
"darling_core",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -743,9 +750,9 @@ dependencies = [
[[package]]
name = "data-encoding"
-version = "2.6.0"
+version = "2.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e8566979429cf69b49a5c740c60791108e86440e8be149bbea4fe54d2c32d6e2"
+checksum = "575f75dfd25738df5b91b8e43e14d44bda14637a58fae779fd2b064f8bf3e010"
[[package]]
name = "der"
@@ -760,9 +767,9 @@ dependencies = [
[[package]]
name = "deranged"
-version = "0.3.11"
+version = "0.4.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4"
+checksum = "28cfac68e08048ae1883171632c2aef3ebc555621ae56fbccce1cbf22dd7f058"
dependencies = [
"powerfmt",
"serde",
@@ -788,7 +795,7 @@ checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -829,9 +836,9 @@ dependencies = [
[[package]]
name = "either"
-version = "1.13.0"
+version = "1.15.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0"
+checksum = "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719"
dependencies = [
"serde",
]
@@ -854,9 +861,9 @@ dependencies = [
[[package]]
name = "equivalent"
-version = "1.0.1"
+version = "1.0.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5"
+checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"
[[package]]
name = "errno"
@@ -920,9 +927,9 @@ dependencies = [
[[package]]
name = "event-listener"
-version = "5.3.1"
+version = "5.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6032be9bd27023a771701cc49f9f053c751055f71efb2e0ae5c15809093675ba"
+checksum = "3492acde4c3fc54c845eaab3eed8bd00c7a7d881f78bfc801e43a93dec1331ae"
dependencies = [
"concurrent-queue",
"parking",
@@ -969,9 +976,9 @@ dependencies = [
[[package]]
name = "flate2"
-version = "1.0.35"
+version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c936bfdafb507ebbf50b8074c54fa31c5be9a1e7e5f467dd659697041407d07c"
+checksum = "11faaf5a5236997af9848be0bef4db95824b1d534ebc64d0f0c6cf3e67bd38dc"
dependencies = [
"crc32fast",
"miniz_oxide",
@@ -1007,9 +1014,9 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
[[package]]
name = "foldhash"
-version = "0.1.4"
+version = "0.1.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a0d2fde1f7b3d48b8395d5f2de76c18a528bd6a9cdde438df747bfcba3e05d6f"
+checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2"
[[package]]
name = "form_urlencoded"
@@ -1072,7 +1079,7 @@ checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -1122,7 +1129,19 @@ checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7"
dependencies = [
"cfg-if",
"libc",
- "wasi",
+ "wasi 0.11.0+wasi-snapshot-preview1",
+]
+
+[[package]]
+name = "getrandom"
+version = "0.3.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "73fea8450eea4bac3940448fb7ae50d91f034f941199fcd9d909a5a07aa455f0"
+dependencies = [
+ "cfg-if",
+ "libc",
+ "r-efi",
+ "wasi 0.14.2+wasi-0.2.4",
]
[[package]]
@@ -1139,9 +1158,9 @@ checksum = "a8d1add55171497b4705a648c6b583acafb01d58050a51727785f0b2c8e0a2b2"
[[package]]
name = "half"
-version = "2.4.1"
+version = "2.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6dd08c532ae367adf81c312a4580bc67f1d0fe8bc9c460520283f4c0ff277888"
+checksum = "7db2ff139bba50379da6aa0766b52fdcb62cb5b263009b09ed58ba604e14bbd1"
dependencies = [
"cfg-if",
"crunchy",
@@ -1187,9 +1206,9 @@ checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"
[[package]]
name = "hermit-abi"
-version = "0.4.0"
+version = "0.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fbf6a919d6cf397374f7dfeeea91d974c7c0a7221d0d0f4f20d859d329e53fcc"
+checksum = "fbd780fe5cc30f81464441920d82ac8740e2e46b29a6fad543ddd075229ce37e"
[[package]]
name = "hex"
@@ -1238,9 +1257,9 @@ dependencies = [
[[package]]
name = "http"
-version = "1.2.0"
+version = "1.3.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f16ca2af56261c99fba8bac40a10251ce8188205a4c448fbb745a2e4daa76fea"
+checksum = "f4a85d31aea989eead29a3aaf9e1115a180df8282431156e533de47660892565"
dependencies = [
"bytes",
"fnv",
@@ -1259,12 +1278,12 @@ dependencies = [
[[package]]
name = "http-body-util"
-version = "0.1.2"
+version = "0.1.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f"
+checksum = "b021d93e26becf5dc7e1b75b1bed1fd93124b374ceb73f43d4d4eafec896a64a"
dependencies = [
"bytes",
- "futures-util",
+ "futures-core",
"http",
"http-body",
"pin-project-lite",
@@ -1272,9 +1291,9 @@ dependencies = [
[[package]]
name = "httparse"
-version = "1.9.5"
+version = "1.10.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7d71d3574edd2771538b901e6549113b4006ece66150fb69c0fb6d9a2adae946"
+checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87"
[[package]]
name = "httpdate"
@@ -1284,9 +1303,9 @@ checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9"
[[package]]
name = "hyper"
-version = "1.5.2"
+version = "1.6.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "256fb8d4bd6413123cc9d91832d78325c48ff41677595be797d90f42969beae0"
+checksum = "cc2b571658e38e0c01b1fdca3bbbe93c00d3d71693ff2770043f8c29bc7d6f80"
dependencies = [
"bytes",
"futures-channel",
@@ -1319,14 +1338,15 @@ dependencies = [
[[package]]
name = "iana-time-zone"
-version = "0.1.61"
+version = "0.1.62"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "235e081f3925a06703c2d0117ea8b91f042756fd6e7a6e5d901e8ca1a996b220"
+checksum = "b2fd658b06e56721792c5df4475705b6cda790e9298d19d2f8af083457bcd127"
dependencies = [
"android_system_properties",
"core-foundation-sys",
"iana-time-zone-haiku",
"js-sys",
+ "log",
"wasm-bindgen",
"windows-core",
]
@@ -1381,9 +1401,9 @@ dependencies = [
[[package]]
name = "icu_locid_transform_data"
-version = "1.5.0"
+version = "1.5.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fdc8ff3388f852bede6b579ad4e978ab004f139284d7b28715f773507b946f6e"
+checksum = "7515e6d781098bf9f7205ab3fc7e9709d34554ae0b21ddbcb5febfa4bc7df11d"
[[package]]
name = "icu_normalizer"
@@ -1405,9 +1425,9 @@ dependencies = [
[[package]]
name = "icu_normalizer_data"
-version = "1.5.0"
+version = "1.5.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f8cafbf7aa791e9b22bec55a167906f9e1215fd475cd22adfcf660e03e989516"
+checksum = "c5e8338228bdc8ab83303f16b797e177953730f601a96c25d10cb3ab0daa0cb7"
[[package]]
name = "icu_properties"
@@ -1426,9 +1446,9 @@ dependencies = [
[[package]]
name = "icu_properties_data"
-version = "1.5.0"
+version = "1.5.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "67a8effbc3dd3e4ba1afa8ad918d5684b8868b3b26500753effea8d2eed19569"
+checksum = "85fb8799753b75aee8d2a21d7c14d9f38921b54b3dbda10f5a3c7a7b82dba5e2"
[[package]]
name = "icu_provider"
@@ -1455,7 +1475,7 @@ checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -1507,9 +1527,9 @@ dependencies = [
[[package]]
name = "indexmap"
-version = "2.7.0"
+version = "2.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "62f822373a4fe84d4bb149bf54e584a7f4abec90e072ed49cda0edea5b95471f"
+checksum = "3954d50fe15b02142bf25d3b8bdadb634ec3948f103d04ffe3031bc8fe9d7058"
dependencies = [
"equivalent",
"hashbrown 0.15.2",
@@ -1518,9 +1538,9 @@ dependencies = [
[[package]]
name = "indicatif"
-version = "0.17.9"
+version = "0.17.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "cbf675b85ed934d3c67b5c5469701eec7db22689d0a2139d856e0925fa28b281"
+checksum = "183b3088984b400f4cfac3620d5e076c84da5364016b4f49473de574b2586235"
dependencies = [
"console",
"number_prefix",
@@ -1555,13 +1575,13 @@ dependencies = [
[[package]]
name = "is-terminal"
-version = "0.4.13"
+version = "0.4.16"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "261f68e344040fbd0edea105bef17c66edf46f984ddb1115b775ce31be948f4b"
+checksum = "e04d7f318608d35d4b61ddd75cbdaee86b023ebe2bd5a66ee0915f0bf93095a9"
dependencies = [
"hermit-abi",
"libc",
- "windows-sys 0.52.0",
+ "windows-sys 0.59.0",
]
[[package]]
@@ -1581,27 +1601,40 @@ dependencies = [
[[package]]
name = "itoa"
-version = "1.0.14"
+version = "1.0.15"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674"
+checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c"
[[package]]
name = "jiff"
-version = "0.1.21"
+version = "0.2.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ed0ce60560149333a8e41ca7dc78799c47c5fd435e2bc18faf6a054382eec037"
+checksum = "c102670231191d07d37a35af3eb77f1f0dbf7a71be51a962dcd57ea607be7260"
dependencies = [
+ "jiff-static",
"log",
"portable-atomic",
"portable-atomic-util",
"serde",
+ "windows-sys 0.59.0",
+]
+
+[[package]]
+name = "jiff-static"
+version = "0.2.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4cdde31a9d349f1b1f51a0b3714a5940ac022976f4b49485fc04be052b183b4c"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn 2.0.100",
]
[[package]]
name = "js-sys"
-version = "0.3.76"
+version = "0.3.77"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6717b6b5b077764fb5966237269cb3c64edddde4b14ce42647430a78ced9e7b7"
+checksum = "1cfaf33c695fc6e08064efbc1f72ec937429614f25eef83af942d0e227c3a28f"
dependencies = [
"once_cell",
"wasm-bindgen",
@@ -1618,24 +1651,24 @@ dependencies = [
[[package]]
name = "libc"
-version = "0.2.169"
+version = "0.2.171"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a"
+checksum = "c19937216e9d3aa9956d9bb8dfc0b0c8beb6058fc4f7a4dc4d850edf86a237d6"
[[package]]
name = "libdeflate-sys"
-version = "1.23.0"
+version = "1.23.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "413b667c8a795fcbe6287a75a8ce92b1dae928172c716fe95044cb2ec7877941"
+checksum = "38b72ad3fbf5ac78f2df7b36075e48adf2459b57c150b9e63937d0204d0f9cd7"
dependencies = [
"cc",
]
[[package]]
name = "libdeflater"
-version = "1.23.0"
+version = "1.23.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d78376c917eec0550b9c56c858de50e1b7ebf303116487562e624e63ce51453a"
+checksum = "013344b17f9dceddff4872559ae19378bd8ee0479eccdd266d2dd2e894b4792f"
dependencies = [
"libdeflate-sys",
]
@@ -1658,15 +1691,15 @@ dependencies = [
[[package]]
name = "linux-raw-sys"
-version = "0.4.14"
+version = "0.9.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89"
+checksum = "fe7db12097d22ec582439daf8618b8fdd1a7bef6270e9af3b1ebcd30893cf413"
[[package]]
name = "listenfd"
-version = "1.0.1"
+version = "1.0.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e0500463acd96259d219abb05dc57e5a076ef04b2db9a2112846929b5f174c96"
+checksum = "b87bc54a4629b4294d0b3ef041b64c40c611097a677d9dc07b2c67739fe39dba"
dependencies = [
"libc",
"uuid",
@@ -1675,9 +1708,9 @@ dependencies = [
[[package]]
name = "litemap"
-version = "0.7.4"
+version = "0.7.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4ee93343901ab17bd981295f2cf0026d4ad018c7c31ba84549a4ddbb47a45104"
+checksum = "23fb14cb19457329c82206317a5663005a4d404783dc74f4252769b0d5f42856"
[[package]]
name = "lock_api"
@@ -1691,18 +1724,9 @@ dependencies = [
[[package]]
name = "log"
-version = "0.4.22"
+version = "0.4.27"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24"
-
-[[package]]
-name = "matchers"
-version = "0.1.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558"
-dependencies = [
- "regex-automata 0.1.10",
-]
+checksum = "13dc2df351e3202783a1fe0d44375f7295ffb4049267b0f3018346dc122a1d94"
[[package]]
name = "matchit"
@@ -1734,9 +1758,9 @@ checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a"
[[package]]
name = "miniz_oxide"
-version = "0.8.2"
+version = "0.8.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4ffbe83022cedc1d264172192511ae958937694cd57ce297164951b8b3568394"
+checksum = "8e3e04debbb59698c15bacbb6d93584a8c0ca9cc3213cb423d31f760d8843ce5"
dependencies = [
"adler2",
]
@@ -1748,7 +1772,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2886843bf800fba2e3377cff24abf6379b4c4d5c6681eaf9ea5b0d15090450bd"
dependencies = [
"libc",
- "wasi",
+ "wasi 0.11.0+wasi-snapshot-preview1",
"windows-sys 0.52.0",
]
@@ -1774,7 +1798,7 @@ dependencies = [
"num-integer",
"num-iter",
"num-traits",
- "rand",
+ "rand 0.8.5",
"smallvec",
"zeroize",
]
@@ -1832,15 +1856,15 @@ dependencies = [
[[package]]
name = "once_cell"
-version = "1.20.2"
+version = "1.21.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775"
+checksum = "c2806eaa3524762875e21c3dcd057bc4b7bfa01ce4da8d46be1cd43649e1cc6b"
[[package]]
name = "oorandom"
-version = "11.1.4"
+version = "11.1.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b410bbe7e14ab526a0e86877eb47c6996a2bd7746f027ba551028c925390e4e9"
+checksum = "d6790f58c7ff633d8771f42965289203411a5e5c68388703c06e14f24770b41e"
[[package]]
name = "ordered-multimap"
@@ -1860,9 +1884,9 @@ checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39"
[[package]]
name = "owo-colors"
-version = "4.1.0"
+version = "4.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fb37767f6569cd834a413442455e0f066d0d522de8630436e2a1761d9726ba56"
+checksum = "1036865bb9422d3300cf723f657c2851d0e9ab12567854b1f4eba3d77decf564"
[[package]]
name = "parking"
@@ -1961,9 +1985,9 @@ dependencies = [
[[package]]
name = "pkg-config"
-version = "0.3.31"
+version = "0.3.32"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "953ec861398dccce10c670dfeaf3ec4911ca479e9c02154b3a215178c5f566f2"
+checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c"
[[package]]
name = "plotters"
@@ -1995,9 +2019,9 @@ dependencies = [
[[package]]
name = "portable-atomic"
-version = "1.10.0"
+version = "1.11.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "280dc24453071f1b63954171985a0b0d30058d287960968b9b2aca264c8d4ee6"
+checksum = "350e9b48cbc6b0e028b0473b114454c6316e57336ee184ceab6e53f72c178b3e"
[[package]]
name = "portable-atomic-util"
@@ -2010,9 +2034,9 @@ dependencies = [
[[package]]
name = "postgres"
-version = "0.19.9"
+version = "0.19.10"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "95c918733159f4d55d2ceb262950f00b0aebd6af4aa97b5a47bb0655120475ed"
+checksum = "363e6dfbdd780d3aa3597b6eb430db76bb315fa9bad7fae595bb8def808b8470"
dependencies = [
"bytes",
"fallible-iterator",
@@ -2024,9 +2048,9 @@ dependencies = [
[[package]]
name = "postgres-protocol"
-version = "0.6.7"
+version = "0.6.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "acda0ebdebc28befa84bee35e651e4c5f09073d668c7aed4cf7e23c3cda84b23"
+checksum = "76ff0abab4a9b844b93ef7b81f1efc0a366062aaef2cd702c76256b5dc075c54"
dependencies = [
"base64",
"byteorder",
@@ -2035,16 +2059,16 @@ dependencies = [
"hmac",
"md-5",
"memchr",
- "rand",
+ "rand 0.9.0",
"sha2",
"stringprep",
]
[[package]]
name = "postgres-types"
-version = "0.2.8"
+version = "0.2.9"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f66ea23a2d0e5734297357705193335e0a957696f34bed2f2faefacb2fec336f"
+checksum = "613283563cd90e1dfc3518d548caee47e0e725455ed619881f5cf21f36de4b48"
dependencies = [
"bytes",
"fallible-iterator",
@@ -2059,9 +2083,9 @@ checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391"
[[package]]
name = "ppv-lite86"
-version = "0.2.20"
+version = "0.2.21"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04"
+checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9"
dependencies = [
"zerocopy",
]
@@ -2079,9 +2103,9 @@ dependencies = [
[[package]]
name = "proc-macro2"
-version = "1.0.92"
+version = "1.0.94"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "37d3544b3f2748c54e147655edb5025752e2303145b5aefb3c3ea2c78b973bb0"
+checksum = "a31971752e70b8b2686d7e46ec17fb38dad4051d94024c88df49b667caea9c84"
dependencies = [
"unicode-ident",
]
@@ -2095,10 +2119,10 @@ dependencies = [
"bitflags",
"lazy_static",
"num-traits",
- "rand",
- "rand_chacha",
+ "rand 0.8.5",
+ "rand_chacha 0.3.1",
"rand_xorshift",
- "regex-syntax 0.8.5",
+ "regex-syntax",
"unarray",
]
@@ -2110,7 +2134,7 @@ checksum = "588f6378e4dd99458b60ec275b4477add41ce4fa9f64dcba6f15adccb19b50d6"
dependencies = [
"env_logger",
"log",
- "rand",
+ "rand 0.8.5",
]
[[package]]
@@ -2126,22 +2150,39 @@ dependencies = [
[[package]]
name = "quote"
-version = "1.0.38"
+version = "1.0.40"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0e4dccaaaf89514f546c693ddc140f729f958c247918a13380cccc6078391acc"
+checksum = "1885c039570dc00dcb4ff087a89e185fd56bae234ddc7f056a945bf36467248d"
dependencies = [
"proc-macro2",
]
[[package]]
+name = "r-efi"
+version = "5.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "74765f6d916ee2faa39bc8e68e4f3ed8949b48cccdac59983d287a7cb71ce9c5"
+
+[[package]]
name = "rand"
version = "0.8.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404"
dependencies = [
"libc",
- "rand_chacha",
- "rand_core",
+ "rand_chacha 0.3.1",
+ "rand_core 0.6.4",
+]
+
+[[package]]
+name = "rand"
+version = "0.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3779b94aeb87e8bd4e834cee3650289ee9e0d5677f976ecdb6d219e5f4f6cd94"
+dependencies = [
+ "rand_chacha 0.9.0",
+ "rand_core 0.9.3",
+ "zerocopy",
]
[[package]]
@@ -2151,7 +2192,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88"
dependencies = [
"ppv-lite86",
- "rand_core",
+ "rand_core 0.6.4",
+]
+
+[[package]]
+name = "rand_chacha"
+version = "0.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb"
+dependencies = [
+ "ppv-lite86",
+ "rand_core 0.9.3",
]
[[package]]
@@ -2160,7 +2211,16 @@ version = "0.6.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c"
dependencies = [
- "getrandom",
+ "getrandom 0.2.15",
+]
+
+[[package]]
+name = "rand_core"
+version = "0.9.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "99d9a13982dcf210057a8a78572b2217b667c3beacbf3a0d8b454f6f82837d38"
+dependencies = [
+ "getrandom 0.3.2",
]
[[package]]
@@ -2169,7 +2229,7 @@ version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f"
dependencies = [
- "rand_core",
+ "rand_core 0.6.4",
]
[[package]]
@@ -2194,9 +2254,9 @@ dependencies = [
[[package]]
name = "redox_syscall"
-version = "0.5.8"
+version = "0.5.10"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834"
+checksum = "0b8c0c260b63a8219631167be35e6a988e9554dbd323f8bd08439c8ed1302bd1"
dependencies = [
"bitflags",
]
@@ -2209,17 +2269,8 @@ checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191"
dependencies = [
"aho-corasick",
"memchr",
- "regex-automata 0.4.9",
- "regex-syntax 0.8.5",
-]
-
-[[package]]
-name = "regex-automata"
-version = "0.1.10"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132"
-dependencies = [
- "regex-syntax 0.6.29",
+ "regex-automata",
+ "regex-syntax",
]
[[package]]
@@ -2230,32 +2281,25 @@ checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908"
dependencies = [
"aho-corasick",
"memchr",
- "regex-syntax 0.8.5",
+ "regex-syntax",
]
[[package]]
name = "regex-syntax"
-version = "0.6.29"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1"
-
-[[package]]
-name = "regex-syntax"
version = "0.8.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c"
[[package]]
name = "ring"
-version = "0.17.8"
+version = "0.17.14"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d"
+checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7"
dependencies = [
"cc",
"cfg-if",
- "getrandom",
+ "getrandom 0.2.15",
"libc",
- "spin",
"untrusted",
"windows-sys 0.52.0",
]
@@ -2268,9 +2312,9 @@ checksum = "88f8660c1ff60292143c98d08fc6e2f654d722db50410e3f3797d40baaf9d8f3"
[[package]]
name = "rsa"
-version = "0.9.7"
+version = "0.9.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "47c75d7c5c6b673e58bf54d8544a9f432e3a925b0e80f7cd3602ab5c50c55519"
+checksum = "78928ac1ed176a5ca1d17e578a1825f3d81ca54cf41053a592584b020cfd691b"
dependencies = [
"const-oid",
"digest",
@@ -2279,7 +2323,7 @@ dependencies = [
"num-traits",
"pkcs1",
"pkcs8",
- "rand_core",
+ "rand_core 0.6.4",
"signature",
"spki",
"subtle",
@@ -2320,9 +2364,9 @@ dependencies = [
[[package]]
name = "rustix"
-version = "0.38.42"
+version = "1.0.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f93dc38ecbab2eb790ff964bb77fa94faf256fd3e73285fd7ba0903b76bedb85"
+checksum = "e56a18552996ac8d29ecc3b190b4fdbb2d91ca4ec396de7bbffaf43f3d637e96"
dependencies = [
"bitflags",
"errno",
@@ -2333,9 +2377,9 @@ dependencies = [
[[package]]
name = "rustls"
-version = "0.23.20"
+version = "0.23.25"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5065c3f250cbd332cd894be57c40fa52387247659b14a2d6041d121547903b1b"
+checksum = "822ee9188ac4ec04a2f0531e55d035fb2de73f18b41a63c70c2712503b6fb13c"
dependencies = [
"log",
"once_cell",
@@ -2357,15 +2401,15 @@ dependencies = [
[[package]]
name = "rustls-pki-types"
-version = "1.10.1"
+version = "1.11.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d2bf47e6ff922db3825eb750c4e2ff784c6ff8fb9e13046ef6a1d1c5401b0b37"
+checksum = "917ce264624a4b4db1c364dcc35bfca9ded014d0a958cd47ad3e960e988ea51c"
[[package]]
name = "rustls-webpki"
-version = "0.102.8"
+version = "0.103.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "64ca1bc8749bd4cf37b5ce386cc146580777b4e8572c7b97baf22c83f444bee9"
+checksum = "fef8b8769aaccf73098557a87cd1816b4f9c7c16811c9c77142aa695c16f2c03"
dependencies = [
"ring",
"rustls-pki-types",
@@ -2374,15 +2418,15 @@ dependencies = [
[[package]]
name = "rustversion"
-version = "1.0.19"
+version = "1.0.20"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f7c45b9784283f1b2e7fb61b42047c2fd678ef0960d4f6f1eba131594cc369d4"
+checksum = "eded382c5f5f786b989652c49544c4877d9f015cc22e145a5ea8ea66c2921cd2"
[[package]]
name = "ryu"
-version = "1.0.18"
+version = "1.0.20"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f"
+checksum = "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f"
[[package]]
name = "same-file"
@@ -2421,35 +2465,35 @@ dependencies = [
[[package]]
name = "semver"
-version = "1.0.24"
+version = "1.0.26"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3cb6eb87a131f756572d7fb904f6e7b68633f09cca868c5df1c4b8d1a694bbba"
+checksum = "56e6fa9c48d24d85fb3de5ad847117517440f6beceb7798af16b4a87d616b8d0"
[[package]]
name = "serde"
-version = "1.0.217"
+version = "1.0.219"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70"
+checksum = "5f0e2c6ed6606019b4e29e69dbaba95b11854410e5347d525002456dbbb786b6"
dependencies = [
"serde_derive",
]
[[package]]
name = "serde_derive"
-version = "1.0.217"
+version = "1.0.219"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0"
+checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
name = "serde_json"
-version = "1.0.135"
+version = "1.0.140"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2b0d7ba2887406110130a978386c4e1befb98c674b4fba677954e4db976630d9"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
dependencies = [
"itoa",
"memchr",
@@ -2459,9 +2503,9 @@ dependencies = [
[[package]]
name = "serde_path_to_error"
-version = "0.1.16"
+version = "0.1.17"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "af99884400da37c88f5e9146b7f1fd0fbcae8f6eec4e9da38b67d05486f814a6"
+checksum = "59fab13f937fa393d08645bf3a84bdfe86e296747b506ada67bb15f10f218b2a"
dependencies = [
"itoa",
"serde",
@@ -2469,13 +2513,13 @@ dependencies = [
[[package]]
name = "serde_repr"
-version = "0.1.19"
+version = "0.1.20"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9"
+checksum = "175ee3e80ae9982737ca543e96133087cbd9a485eecc3bc4de9c1a37b47ea59c"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -2500,7 +2544,7 @@ dependencies = [
"chrono",
"hex",
"indexmap 1.9.3",
- "indexmap 2.7.0",
+ "indexmap 2.8.0",
"serde",
"serde_derive",
"serde_json",
@@ -2517,7 +2561,7 @@ dependencies = [
"darling",
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -2579,7 +2623,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de"
dependencies = [
"digest",
- "rand_core",
+ "rand_core 0.6.4",
]
[[package]]
@@ -2599,9 +2643,9 @@ dependencies = [
[[package]]
name = "smallvec"
-version = "1.13.2"
+version = "1.14.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67"
+checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd"
dependencies = [
"serde",
]
@@ -2665,7 +2709,7 @@ dependencies = [
"futures-util",
"hashbrown 0.15.2",
"hashlink",
- "indexmap 2.7.0",
+ "indexmap 2.8.0",
"log",
"memchr",
"once_cell",
@@ -2695,7 +2739,7 @@ dependencies = [
"quote",
"sqlx-core",
"sqlx-macros-core",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -2718,7 +2762,7 @@ dependencies = [
"sqlx-mysql",
"sqlx-postgres",
"sqlx-sqlite",
- "syn 2.0.95",
+ "syn 2.0.100",
"tempfile",
"tokio",
"url",
@@ -2753,7 +2797,7 @@ dependencies = [
"memchr",
"once_cell",
"percent-encoding",
- "rand",
+ "rand 0.8.5",
"rsa",
"serde",
"sha1",
@@ -2792,7 +2836,7 @@ dependencies = [
"md-5",
"memchr",
"once_cell",
- "rand",
+ "rand 0.8.5",
"serde",
"serde_json",
"sha2",
@@ -2877,9 +2921,9 @@ dependencies = [
[[package]]
name = "syn"
-version = "2.0.95"
+version = "2.0.100"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "46f71c0377baf4ef1cc3e3402ded576dccc315800fbc62dfc7fe04b009773b4a"
+checksum = "b09a44accad81e1ba1cd74a32461ba89dee89095ba17b32f5d03683b1b1fc2a0"
dependencies = [
"proc-macro2",
"quote",
@@ -2900,13 +2944,13 @@ checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
name = "taler-api"
-version = "0.1.0"
-source = "git+https://git.taler.net/taler-rust.git/#88fad287f9047d4ab097253f39bc44e82729a623"
+version = "0.0.0"
+source = "git+https://git.taler.net/taler-rust.git/#972b180ea70eb4cb129abb293379ab590ba3c2da"
dependencies = [
"axum",
"dashmap",
@@ -2916,46 +2960,48 @@ dependencies = [
"listenfd",
"serde",
"serde_json",
+ "serde_path_to_error",
"sqlx",
"taler-common",
"thiserror",
"tokio",
"tracing",
- "tracing-subscriber",
- "tracing-test",
"url",
]
[[package]]
name = "taler-common"
-version = "0.1.0"
-source = "git+https://git.taler.net/taler-rust.git/#88fad287f9047d4ab097253f39bc44e82729a623"
+version = "0.0.0"
+source = "git+https://git.taler.net/taler-rust.git/#972b180ea70eb4cb129abb293379ab590ba3c2da"
dependencies = [
+ "anyhow",
+ "clap",
"fastrand",
"glob",
- "indexmap 2.7.0",
+ "indexmap 2.8.0",
"jiff",
- "rand",
"serde",
"serde_json",
+ "serde_path_to_error",
"serde_urlencoded",
"serde_with",
"sqlx",
"tempfile",
"thiserror",
+ "tokio",
"tracing",
+ "tracing-subscriber",
"url",
]
[[package]]
name = "tempfile"
-version = "3.15.0"
+version = "3.19.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9a8a559c81686f576e8cd0290cd2a24a2a9ad80c98b3478856500fcbd7acd704"
+checksum = "7437ac7763b9b123ccf33c338a5cc1bac6f69b45a136c19bdd8a65e3916435bf"
dependencies = [
- "cfg-if",
"fastrand",
- "getrandom",
+ "getrandom 0.3.2",
"once_cell",
"rustix",
"windows-sys 0.59.0",
@@ -2972,22 +3018,22 @@ dependencies = [
[[package]]
name = "thiserror"
-version = "2.0.9"
+version = "2.0.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f072643fd0190df67a8bab670c20ef5d8737177d6ac6b2e9a236cb096206b2cc"
+checksum = "567b8a2dae586314f7be2a752ec7474332959c6460e02bde30d702a66d488708"
dependencies = [
"thiserror-impl",
]
[[package]]
name = "thiserror-impl"
-version = "2.0.9"
+version = "2.0.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7b50fa271071aae2e6ee85f842e2e28ba8cd2c5fb67f11fcb1fd70b276f9e7d4"
+checksum = "7f7cf42b4507d8ea322120659672cf1b9dbb93f8f2d4ecfd6e51350ff5b17a1d"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -3008,9 +3054,9 @@ dependencies = [
[[package]]
name = "time"
-version = "0.3.37"
+version = "0.3.41"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "35e7868883861bd0e56d9ac6efcaaca0d6d5d82a2a7ec8209ff492c07cf37b21"
+checksum = "8a7619e19bc266e0f9c5e6686659d394bc57973859340060a69221e57dbc0c40"
dependencies = [
"deranged",
"itoa",
@@ -3023,15 +3069,15 @@ dependencies = [
[[package]]
name = "time-core"
-version = "0.1.2"
+version = "0.1.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3"
+checksum = "c9e9a38711f559d9e3ce1cdb06dd7c5b8ea546bc90052da6d06bb76da74bb07c"
[[package]]
name = "time-macros"
-version = "0.2.19"
+version = "0.2.22"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2834e6017e3e5e4b9834939793b282bc03b37a3336245fa820e35e233e2a85de"
+checksum = "3526739392ec93fd8b359c8e98514cb3e8e021beb4e5f597b00a0221f8ed8a49"
dependencies = [
"num-conv",
"time-core",
@@ -3068,9 +3114,9 @@ dependencies = [
[[package]]
name = "tinyvec"
-version = "1.8.1"
+version = "1.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "022db8904dfa342efe721985167e9fcd16c29b226db4397ed752a761cfce81e8"
+checksum = "09b3661f17e86524eccd4371ab0429194e0d7c008abb45f7a7495b1719463c71"
dependencies = [
"tinyvec_macros",
]
@@ -3083,9 +3129,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"
[[package]]
name = "tokio"
-version = "1.42.0"
+version = "1.44.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5cec9b21b0450273377fc97bd4c33a8acffc8c996c987a7c5b319a0083707551"
+checksum = "f382da615b842244d4b8738c82ed1275e6c5dd90c459a30941cd07080b06c91a"
dependencies = [
"backtrace",
"bytes",
@@ -3100,20 +3146,20 @@ dependencies = [
[[package]]
name = "tokio-macros"
-version = "2.4.0"
+version = "2.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752"
+checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
name = "tokio-postgres"
-version = "0.7.12"
+version = "0.7.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3b5d3742945bc7d7f210693b0c58ae542c6fd47b17adbbda0885f3dcb34a6bdb"
+checksum = "6c95d533c83082bb6490e0189acaa0bbeef9084e60471b696ca6988cd0541fb0"
dependencies = [
"async-trait",
"byteorder",
@@ -3128,7 +3174,7 @@ dependencies = [
"pin-project-lite",
"postgres-protocol",
"postgres-types",
- "rand",
+ "rand 0.9.0",
"socket2",
"tokio",
"tokio-util",
@@ -3148,9 +3194,9 @@ dependencies = [
[[package]]
name = "tokio-util"
-version = "0.7.13"
+version = "0.7.14"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d7fcaa8d55a2bdd6b83ace262b016eca0d79ee02818c5c1bcdf0305114081078"
+checksum = "6b9590b93e6fcc1739458317cccd391ad3955e2bde8913edf6f95f9e65a8f034"
dependencies = [
"bytes",
"futures-core",
@@ -3207,7 +3253,7 @@ checksum = "395ae124c09f9e6918a2310af6038fba074bcf474ac352496d5910dd59a2226d"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
@@ -3237,40 +3283,15 @@ version = "0.3.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008"
dependencies = [
- "matchers",
"nu-ansi-term",
- "once_cell",
- "regex",
"sharded-slab",
"smallvec",
"thread_local",
- "tracing",
"tracing-core",
"tracing-log",
]
[[package]]
-name = "tracing-test"
-version = "0.2.5"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "557b891436fe0d5e0e363427fc7f217abf9ccd510d5136549847bdcbcd011d68"
-dependencies = [
- "tracing-core",
- "tracing-subscriber",
- "tracing-test-macro",
-]
-
-[[package]]
-name = "tracing-test-macro"
-version = "0.2.5"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "04659ddb06c87d233c566112c1c9c5b9e98256d9af50ec3bc9c8327f873a7568"
-dependencies = [
- "quote",
- "syn 2.0.95",
-]
-
-[[package]]
name = "trim-in-place"
version = "0.1.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -3278,9 +3299,9 @@ checksum = "343e926fc669bc8cde4fa3129ab681c63671bae288b1f1081ceee6d9d37904fc"
[[package]]
name = "typenum"
-version = "1.17.0"
+version = "1.18.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825"
+checksum = "1dccffe3ce07af9386bfd29e80c0ab1a8205a2fc34e4bcd40364df902cfa8f3f"
[[package]]
name = "uint"
@@ -3308,9 +3329,9 @@ checksum = "5c1cb5db39152898a79168971543b1cb5020dff7fe43c8dc468b0885f5e29df5"
[[package]]
name = "unicode-ident"
-version = "1.0.14"
+version = "1.0.18"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83"
+checksum = "5a5f39404a5da50712a4c1eecf25e90dd62b613502b7e925fd4e4d19b5c96512"
[[package]]
name = "unicode-normalization"
@@ -3403,15 +3424,15 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821"
[[package]]
name = "uuid"
-version = "1.11.0"
+version = "1.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f8c5f0a0af699448548ad1a2fbf920fb4bee257eae39953ba95cb84891a0446a"
+checksum = "458f7a779bf54acc9f347480ac654f68407d3aab21269a6e3c9f922acd9e2da9"
[[package]]
name = "valuable"
-version = "0.1.0"
+version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d"
+checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65"
[[package]]
name = "vcpkg"
@@ -3442,6 +3463,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423"
[[package]]
+name = "wasi"
+version = "0.14.2+wasi-0.2.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9683f9a5a998d873c0d21fcbe3c083009670149a8fab228644b8bd36b2c48cb3"
+dependencies = [
+ "wit-bindgen-rt",
+]
+
+[[package]]
name = "wasite"
version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -3449,34 +3479,35 @@ checksum = "b8dad83b4f25e74f184f64c43b150b91efe7647395b42289f38e50566d82855b"
[[package]]
name = "wasm-bindgen"
-version = "0.2.99"
+version = "0.2.100"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a474f6281d1d70c17ae7aa6a613c87fce69a127e2624002df63dcb39d6cf6396"
+checksum = "1edc8929d7499fc4e8f0be2262a241556cfc54a0bea223790e71446f2aab1ef5"
dependencies = [
"cfg-if",
"once_cell",
+ "rustversion",
"wasm-bindgen-macro",
]
[[package]]
name = "wasm-bindgen-backend"
-version = "0.2.99"
+version = "0.2.100"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5f89bb38646b4f81674e8f5c3fb81b562be1fd936d84320f3264486418519c79"
+checksum = "2f0a0651a5c2bc21487bde11ee802ccaf4c51935d0d3d42a6101f98161700bc6"
dependencies = [
"bumpalo",
"log",
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
"wasm-bindgen-shared",
]
[[package]]
name = "wasm-bindgen-macro"
-version = "0.2.99"
+version = "0.2.100"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2cc6181fd9a7492eef6fef1f33961e3695e4579b9872a6f7c83aee556666d4fe"
+checksum = "7fe63fc6d09ed3792bd0897b314f53de8e16568c2b3f7982f468c0bf9bd0b407"
dependencies = [
"quote",
"wasm-bindgen-macro-support",
@@ -3484,28 +3515,31 @@ dependencies = [
[[package]]
name = "wasm-bindgen-macro-support"
-version = "0.2.99"
+version = "0.2.100"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "30d7a95b763d3c45903ed6c81f156801839e5ee968bb07e534c44df0fcd330c2"
+checksum = "8ae87ea40c9f689fc23f209965b6fb8a99ad69aeeb0231408be24920604395de"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
"wasm-bindgen-backend",
"wasm-bindgen-shared",
]
[[package]]
name = "wasm-bindgen-shared"
-version = "0.2.99"
+version = "0.2.100"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "943aab3fdaaa029a6e0271b35ea10b72b943135afe9bffca82384098ad0e06a6"
+checksum = "1a05d73b933a847d6cccdda8f838a22ff101ad9bf93e33684f39c1f5f0eece3d"
+dependencies = [
+ "unicode-ident",
+]
[[package]]
name = "web-sys"
-version = "0.3.76"
+version = "0.3.77"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "04dd7223427d52553d3702c004d3b2fe07c148165faa56313cb00211e31c12bc"
+checksum = "33b6dd2ef9186f1f2072e409e99cd22a975331a6b3591b12c764e0e55c60d5d2"
dependencies = [
"js-sys",
"wasm-bindgen",
@@ -3523,18 +3557,18 @@ dependencies = [
[[package]]
name = "webpki-roots"
-version = "0.26.7"
+version = "0.26.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5d642ff16b7e79272ae451b7322067cdc17cadf68c23264be9d94a32319efe7e"
+checksum = "2210b291f7ea53617fbafcc4939f10914214ec15aace5ba62293a668f322c5c9"
dependencies = [
"rustls-pki-types",
]
[[package]]
name = "whoami"
-version = "1.5.2"
+version = "1.6.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "372d5b87f58ec45c384ba03563b03544dc5fadc3983e434b286913f5b4a9bb6d"
+checksum = "6994d13118ab492c3c80c1f81928718159254c53c472bf9ce36f8dae4add02a7"
dependencies = [
"redox_syscall",
"wasite",
@@ -3582,6 +3616,12 @@ dependencies = [
]
[[package]]
+name = "windows-link"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "76840935b766e1b0a05c0066835fb9ec80071d4c09a16f6bd5f7e655e3c14c38"
+
+[[package]]
name = "windows-sys"
version = "0.48.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -3738,7 +3778,6 @@ dependencies = [
"clap",
"common",
"ethereum-types",
- "listenfd",
"sqlx",
"taler-api",
"taler-common",
@@ -3748,6 +3787,15 @@ dependencies = [
]
[[package]]
+name = "wit-bindgen-rt"
+version = "0.39.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6f42320e61fe2cfd34354ecb597f86f413484a798ba44a8ca1165c58d42da6c1"
+dependencies = [
+ "bitflags",
+]
+
+[[package]]
name = "write16"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -3779,49 +3827,48 @@ checksum = "2380878cad4ac9aac1e2435f3eb4020e8374b5f13c296cb75b4620ff8e229154"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
"synstructure",
]
[[package]]
name = "zerocopy"
-version = "0.7.35"
+version = "0.8.24"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0"
+checksum = "2586fea28e186957ef732a5f8b3be2da217d65c5969d4b1e17f973ebbe876879"
dependencies = [
- "byteorder",
"zerocopy-derive",
]
[[package]]
name = "zerocopy-derive"
-version = "0.7.35"
+version = "0.8.24"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e"
+checksum = "a996a8f63c5c4448cd959ac1bab0aaa3306ccfd060472f85943ee0750f0169be"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
[[package]]
name = "zerofrom"
-version = "0.1.5"
+version = "0.1.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "cff3ee08c995dee1859d998dea82f7374f2826091dd9cd47def953cae446cd2e"
+checksum = "50cc42e0333e05660c3587f3bf9d0478688e15d870fab3346451ce7f8c9fbea5"
dependencies = [
"zerofrom-derive",
]
[[package]]
name = "zerofrom-derive"
-version = "0.1.5"
+version = "0.1.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "595eed982f7d355beb85837f651fa22e90b3c044842dc7f2c2842c086f295808"
+checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
"synstructure",
]
@@ -3850,5 +3897,5 @@ checksum = "6eafa6dfb17584ea3e2bd6e76e0cc15ad7af12b09abdd1ca55961bed9b1063c6"
dependencies = [
"proc-macro2",
"quote",
- "syn 2.0.95",
+ "syn 2.0.100",
]
diff --git a/btc-wire/src/taler_utils.rs b/btc-wire/src/taler_utils.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -20,15 +20,15 @@ use common::{
currency::CurrencyBtc,
taler_common::types::{
amount::{Amount, FRAC_BASE},
- payto::Payto,
+ payto::PaytoURI,
},
url::Url,
};
use std::str::FromStr;
/// Generate a payto uri from a btc address
-pub fn btc_payto_url(addr: &Address) -> Payto {
- Payto::from_str(&format!("payto://bitcoin/{}", addr)).unwrap()
+pub fn btc_payto_url(addr: &Address) -> PaytoURI {
+ PaytoURI::from_str(&format!("payto://bitcoin/{}", addr)).unwrap()
}
/// Extract a btc address from a payto uri
diff --git a/common/Cargo.toml b/common/Cargo.toml
@@ -35,4 +35,4 @@ uri-pack = { path = "../uri-pack" }
exponential-backoff = "1.2.0"
taler-common.workspace = true
taler-api.workspace = true
-sqlx.workspace = true
+sqlx.workspace = true
+\ No newline at end of file
diff --git a/common/src/config.rs b/common/src/config.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -15,14 +15,17 @@
*/
use sqlx::postgres::PgConnectOptions;
use std::{
+ fs::Permissions,
+ net::SocketAddr,
+ os::unix::fs::PermissionsExt,
path::{Path, PathBuf},
process::Command,
str::FromStr,
};
-use taler_api::auth::AuthMethod;
+use taler_api::{auth::AuthMethod, Serve};
use taler_common::{
config::{parser::ConfigErr, Config, Section},
- types::payto::Payto,
+ types::payto::PaytoURI,
};
use url::Url;
@@ -40,8 +43,8 @@ pub struct TalerConfig {
impl TalerConfig {
pub fn load(file: Option<&Path>) -> Self {
- // Load config using taler-config
- let mut cmd = Command::new("taler-config");
+ // Load config using taler-exchange-config
+ let mut cmd = Command::new("taler-exchange-config");
cmd.arg("-d");
if let Some(path) = file {
cmd.arg("-c");
@@ -49,10 +52,10 @@ impl TalerConfig {
}
let output = cmd
.output()
- .or_fail(|e| format!("Failed to execute taler-config: {}", e));
+ .or_fail(|e| format!("Failed to execute taler-exchange-config: {}", e));
if !output.status.success() {
fail(format_args!(
- "taler-config failure:\n{}",
+ "taler-exchange-config failure:\n{}",
String::from_utf8_lossy(&output.stderr)
));
}
@@ -84,7 +87,7 @@ impl TalerConfig {
.number::<u32>(name)
.opt()
.unwrap()
- .filter(|it| *it == 0)
+ .filter(|it| *it != 0)
}
}
@@ -108,7 +111,7 @@ impl TalerConfig {
/* ----- Wire Gateway ----- */
- pub fn payto(&self) -> Payto {
+ pub fn payto(&self) -> PaytoURI {
self.section().payto("PAYTO").require().unwrap()
}
@@ -175,10 +178,9 @@ pub struct WireGatewayCfg {
pub auth: AuthMethod,
pub http_lifetime: Option<u32>,
pub db: PgConnectOptions,
- pub payto: Payto,
+ pub payto: PaytoURI,
pub currency: Currency,
- pub unix: Option<String>,
- pub port: u16,
+ pub serve: Serve,
}
impl WireGatewayCfg {
@@ -200,14 +202,23 @@ impl WireGatewayCfg {
_ => unreachable!(),
}
};
+ let serve = if let Some(path) = sect.path("UNIXPATH").opt()? {
+ Serve::Unix {
+ path,
+ permission: Permissions::from_mode(0o660),
+ }
+ } else {
+ let port = sect.number("PORT").default(8080)?;
+ Serve::Tcp(SocketAddr::from(([0, 0, 0, 0], port)))
+ };
+
Ok(Self {
auth,
http_lifetime: tmp.non_zero_option("HTTP_LIFETIME"),
db: sect.postgres("DB_URL").require()?,
payto: sect.payto("PAYTO").require()?,
currency: tmp.currency,
- unix: sect.path("UNIXPATH").opt()?,
- port: sect.number("PORT").default(8080)?,
+ serve,
})
}
}
diff --git a/common/src/sql.rs b/common/src/sql.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -19,7 +19,7 @@ use std::str::FromStr;
use postgres::Row;
use taler_common::{
api_common::SafeU64,
- types::{amount::Amount, payto::Payto},
+ types::{amount::Amount, payto::PaytoURI},
};
use url::Url;
@@ -32,9 +32,9 @@ pub fn sql_url(row: &Row, idx: usize) -> Url {
}
/// Payto from sql
-pub fn sql_payto(row: &Row, idx: usize) -> Payto {
+pub fn sql_payto(row: &Row, idx: usize) -> PaytoURI {
let str: &str = row.get(idx);
- Payto::from_str(str).or_fail(|_| format!("Database invariant: expected a payto got {}", str))
+ PaytoURI::from_str(str).or_fail(|_| format!("Database invariant: expected a payto got {}", str))
}
/// Ethereum amount from sql
diff --git a/eth-wire/src/lib.rs b/eth-wire/src/lib.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -26,7 +26,7 @@ use common::{
log::{fail, OrFail},
metadata::{InMetadata, OutMetadata},
postgres,
- taler_common::types::{amount::Amount, payto::Payto},
+ taler_common::types::{amount::Amount, payto::PaytoURI},
url::Url,
};
use ethereum_types::{Address, H160, H256, U256, U64};
@@ -232,7 +232,7 @@ pub struct WireState {
pub lifetime: Option<u32>,
pub bump_delay: Option<u32>,
pub base_url: Url,
- pub payto: Payto,
+ pub payto: PaytoURI,
pub db_config: postgres::Config,
pub currency: CurrencyEth,
}
diff --git a/eth-wire/src/loops/worker.rs b/eth-wire/src/loops/worker.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -151,7 +151,7 @@ fn sync_chain(
let mut tx = db.transaction()?;
tx.execute(
"UPDATE state SET value=$1 WHERE name='status'",
- &[&[new_status as u8].as_ref()],
+ &[&[new_status as u8].as_slice()],
)?;
tx.execute("NOTIFY status", &[])?;
tx.commit()?;
@@ -175,7 +175,7 @@ fn sync_chain(
db.execute(
"UPDATE state SET value=$1 WHERE name='sync'",
- &[&list.state.to_bytes().as_ref()],
+ &[&list.state.to_bytes().as_slice()],
)?;
Ok(true)
}
@@ -216,7 +216,7 @@ fn sync_chain_removed(
if db
.query_opt(
"SELECT 1 FROM tx_in WHERE reserve_pub=$1",
- &[&reserve_pub.as_ref()],
+ &[&reserve_pub.as_slice()],
)?
.is_some()
{
@@ -279,7 +279,7 @@ fn sync_chain_incoming_confirmed(
let amount = eth_to_taler(&tx.value, state.currency);
let credit_addr = tx.from.expect("Not coinbase");
let nb = db.execute("INSERT INTO tx_in (received, amount, reserve_pub, debit_acc, credit_acc) VALUES ($1, ($2, $3)::taler_amount, $4, $5, $6) ON CONFLICT (reserve_pub) DO NOTHING ", &[
- &Timestamp::now().as_sql_micros(), &(amount.val as i64), &(amount.frac as i32), &reserve_pub.as_ref(), ð_payto_url(&credit_addr).raw(), &state.payto.raw()
+ &Timestamp::now().as_sql_micros(), &(amount.val as i64), &(amount.frac as i32), &reserve_pub.as_slice(), ð_payto_url(&credit_addr).raw(), &state.payto.raw()
])?;
if nb > 0 {
info!(
@@ -314,7 +314,7 @@ fn sync_chain_outgoing(tx: &SyncTransaction, db: &mut Client, state: &WireState)
// Get previous out tx
let row = db.query_opt(
"SELECT id, status, sent FROM tx_out WHERE wtid=$1 FOR UPDATE",
- &[&wtid.as_ref()],
+ &[&wtid.as_slice()],
)?;
if let Some(row) = row {
// If already in database, sync status
@@ -353,7 +353,7 @@ fn sync_chain_outgoing(tx: &SyncTransaction, db: &mut Client, state: &WireState)
// Else add to database
let nb = db.execute(
"INSERT INTO tx_out (created, amount, wtid, debit_acc, credit_acc, exchange_url, status, txid, request_uid) VALUES ($1, ($2, $3)::taler_amount, $4, $5, $6, $7, $8, $9, $10) ON CONFLICT (wtid) DO NOTHING",
- &[&Timestamp::now().as_sql_micros(), &(amount.val as i64), &(amount.frac as i32), &wtid.as_ref(), ð_payto_url(&state.address).raw(), ð_payto_url(&credit_addr).raw(), &state.base_url.as_ref(), &(DebitStatus::Sent as i16), &tx.hash.as_ref(), &None::<&[u8]>],
+ &[&Timestamp::now().as_sql_micros(), &(amount.val as i64), &(amount.frac as i32), &wtid.as_slice(), ð_payto_url(&state.address).raw(), ð_payto_url(&credit_addr).raw(), &state.base_url.as_ref(), &(DebitStatus::Sent as i16), &tx.hash.as_ref(), &None::<&[u8]>],
)?;
if nb > 0 {
warn!(
diff --git a/eth-wire/src/main.rs b/eth-wire/src/main.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -80,7 +80,7 @@ fn init(config: Option<PathBuf>, init: Init) -> LoopResult<()> {
tx
.execute(
"INSERT INTO state (name, value) VALUES ('status', $1) ON CONFLICT (name) DO NOTHING",
- &[&[1u8].as_ref()],
+ &[&[1u8].as_slice()],
)?;
// Init sync if not already set
let block = rpc.earliest_block()?;
@@ -91,7 +91,7 @@ fn init(config: Option<PathBuf>, init: Init) -> LoopResult<()> {
};
tx.execute(
"INSERT INTO state (name, value) VALUES ('sync', $1) ON CONFLICT (name) DO NOTHING",
- &[&state.to_bytes().as_ref()],
+ &[&state.to_bytes().as_slice()],
)?;
tx.commit()?;
println!("Database initialised");
@@ -117,7 +117,7 @@ fn init(config: Option<PathBuf>, init: Init) -> LoopResult<()> {
)?;
let nb_row = db.execute(
"UPDATE state SET value=$1 WHERE name='sync'",
- &[&state.to_bytes().as_ref()],
+ &[&state.to_bytes().as_slice()],
)?;
if nb_row > 0 {
println!("Skipped {} previous block", state.conf_height);
diff --git a/eth-wire/src/taler_util.rs b/eth-wire/src/taler_util.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -19,7 +19,7 @@ use common::{
currency::CurrencyEth,
taler_common::types::{
amount::{Amount, FRAC_BASE},
- payto::Payto,
+ payto::PaytoURI,
},
};
use ethereum_types::{Address, U256};
@@ -28,8 +28,8 @@ pub const WEI: u64 = 1_000_000_000_000_000_000;
pub const TRUNC: u64 = WEI / FRAC_BASE as u64;
/// Generate a payto uri from an eth address
-pub fn eth_payto_url(addr: &Address) -> Payto {
- Payto::from_str(&format!(
+pub fn eth_payto_url(addr: &Address) -> PaytoURI {
+ PaytoURI::from_str(&format!(
"payto://ethereum/{}",
hex::encode(addr.as_bytes())
))
@@ -37,7 +37,7 @@ pub fn eth_payto_url(addr: &Address) -> Payto {
}
/// Extract an eth address from a payto uri
-pub fn eth_payto_addr(payto: &Payto) -> Result<Address, String> {
+pub fn eth_payto_addr(payto: &PaytoURI) -> Result<Address, String> {
let url = payto.as_ref();
if url.domain() != Some("ethereum") {
return Err(format!(
diff --git a/instrumentation/src/gateway.rs b/instrumentation/src/gateway.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022-2024 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -17,15 +17,12 @@
use std::str::FromStr;
use btc_wire::taler_utils::btc_payto_url;
-use common::{
- rand_slice,
- taler_common::{
- api_wire::TransferRequest,
- types::{
- amount::Amount as TalerAmount,
- base32::Base32,
- payto::{payto, Payto},
- },
+use common::taler_common::{
+ api_wire::TransferRequest,
+ types::{
+ amount::Amount,
+ base32::Base32,
+ payto::{payto, PaytoURI},
},
};
use libdeflater::{CompressionLvl, Compressor};
@@ -36,7 +33,7 @@ use crate::{
utils::{cmd_out, cmd_redirect_ok, gateway_error, TestCtx},
};
-fn client_transfer(gateway_url: &str, payto_url: &Payto, amount: &str) -> String {
+fn client_transfer(gateway_url: &str, payto_url: &PaytoURI, amount: &str) -> String {
cmd_out(
"taler-exchange-wire-gateway-client",
&["-b", gateway_url, "-C", payto_url.raw(), "-a", amount],
@@ -120,7 +117,7 @@ pub fn api(ctx: TestCtx) {
{
// Bad payto_url
for url in [
- "http://bitcoin/$CLIENT",
+ //"http://bitcoin/$CLIENT",
"payto://btc/$CLIENT",
"payto://bitcoin/$CLIENT?id=admin",
"payto://bitcoin/$CLIENT#admin",
@@ -151,10 +148,10 @@ pub fn api(ctx: TestCtx) {
ctx.step("Transfer idempotence");
{
let mut request = TransferRequest {
- request_uid: Base32::from(rand_slice()),
- amount: TalerAmount::from_str(amount).unwrap(),
+ request_uid: Base32::rand(),
+ amount: Amount::from_str(amount).unwrap(),
exchange_base_url: ctx.taler_conf.base_url(),
- wtid: Base32::from(rand_slice()),
+ wtid: Base32::rand(),
credit_account: btc_payto,
};
// Same
diff --git a/instrumentation/src/utils.rs b/instrumentation/src/utils.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022-2024 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -29,10 +29,9 @@ use std::{
use common::{
config::TalerConfig,
- rand_slice,
taler_common::{
api_wire::{IncomingBankTransaction, IncomingHistory, OutgoingHistory, TransferRequest},
- types::{amount::Amount, base32::Base32, payto::Payto},
+ types::{amount::Amount, base32::Base32, payto::PaytoURI},
},
url::Url,
};
@@ -111,12 +110,12 @@ pub fn transfer(
base_url: &str,
wtid: &[u8; 32],
url: &Url,
- credit_account: Payto,
+ credit_account: PaytoURI,
amount: &Amount,
) {
ureq::post(&format!("{}transfer", base_url))
.send_json(TransferRequest {
- request_uid: Base32::from(rand_slice()),
+ request_uid: Base32::rand(),
amount: amount.clone(),
exchange_base_url: url.clone(),
wtid: Base32::from(*wtid),
@@ -324,13 +323,7 @@ impl TalerCtx {
.with_section(section)
.set("CONF_PATH", wire_dir.to_string_lossy())
.set("IPC_PATH", wire_dir.to_string_lossy())
- .set(
- "DB_URL",
- format!(
- "postgres://localhost:{}/{}?user=postgres&password=password",
- ctx.db.port, ctx.name
- ),
- )
+ .set("DB_URL", ctx.db.postgres_uri(&ctx.name))
.set("PORT", gateway_port.to_string());
config.write_to_file(&conf).unwrap();
@@ -462,14 +455,12 @@ pub fn unused_port() -> u16 {
pub struct TestDb {
pub dir: TempDir,
- pub port: u16,
_db: ChildGuard,
}
impl TestDb {
pub fn new() -> Self {
let dir = TempDir::new().unwrap();
- let port = unused_port();
let log = "log/postgres.log";
// Init databases files
@@ -484,7 +475,7 @@ impl TestDb {
dir.path().join("postgresql.conf"),
format!(
"
- port={port}
+ listen_addresses=''
unix_socket_directories='{}'
fsync=off
synchronous_commit=off
@@ -499,20 +490,23 @@ impl TestDb {
&["-D", dir.path().to_string_lossy().as_ref()],
log,
);
- retry(|| {
- Self::execute_sql(
- port,
- "CREATE ROLE postgres LOGIN SUPERUSER PASSWORD 'password'",
- )
- });
+ let tmp = Self { dir, _db: db };
+ // Wait for postgres to start
+ retry(|| tmp.execute_sql("SELECT true"));
+ tmp
+ }
- Self { dir, port, _db: db }
+ pub fn postgres_uri(&self, database: &str) -> String {
+ format!(
+ "postgres:///{database}?host={}",
+ self.dir.path().to_string_lossy().as_ref()
+ )
}
- fn execute_sql(port: u16, sql: &str) -> bool {
+ fn execute_sql(&self, sql: &str) -> bool {
let mut psql = ChildGuard(
Command::new("psql")
- .arg(format!("postgres://localhost:{}/postgres", port))
+ .arg(self.postgres_uri("postgres"))
.stderr(Stdio::null())
.stdout(
std::fs::File::options()
@@ -535,34 +529,27 @@ impl TestDb {
}
pub fn create_db(&self, name: &str) {
- Self::execute_sql(
- self.port,
- &format!(
- "
+ self.execute_sql(&format!(
+ "
DROP DATABASE IF EXISTS {name};
CREATE DATABASE {name};
"
- ),
- );
+ ));
}
pub fn stop_db(&self, name: &str) {
- Self::execute_sql(
- self.port,
- &format!(
- "
+ self.execute_sql(&format!(
+ "
UPDATE pg_database SET datallowconn=false WHERE datname='{name}';
SELECT pg_terminate_backend(pid)
FROM pg_stat_activity
WHERE datname='{name}' AND pid <> pg_backend_pid();
"
- ),
- );
+ ));
}
pub fn resume_db(&self, name: &str) {
- Self::execute_sql(
- self.port,
- &format!("UPDATE pg_database SET datallowconn=true WHERE datname='{name}';"),
- );
+ self.execute_sql(&format!(
+ "UPDATE pg_database SET datallowconn=true WHERE datname='{name}';"
+ ));
}
}
diff --git a/uri-pack/src/lib.rs b/uri-pack/src/lib.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -93,7 +93,7 @@ pub enum DecodeErr {
/// Pack an uri string into an optimized binary format
pub fn pack_uri(uri: &str) -> Result<Vec<u8>, EncodeErr> {
- let len = uri.as_bytes().len();
+ let len = uri.len();
let mut vec = Vec::with_capacity(len);
if let Some(char) = uri.as_bytes().iter().find(|c| !supported_ascii(c)) {
diff --git a/uri-pack/src/main.rs b/uri-pack/src/main.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -32,7 +32,7 @@ fn main() {
for ascii in domain.as_bytes() {
ascii_counter[*ascii as usize] += 1;
}
- let before = domain.as_bytes().len();
+ let before = domain.len();
let after = pack_uri(domain).unwrap().len();
before_len += before;
after_len += after;
diff --git a/wire-gateway/Cargo.toml b/wire-gateway/Cargo.toml
@@ -15,8 +15,6 @@ tokio = { workspace = true, features = ["net", "macros", "rt-multi-thread"] }
thiserror.workspace = true
# Async postgres client
sqlx.workspace = true
-# Socket activation
-listenfd = "1.0.0"
# Common lib
common = { path = "../common" }
# Bitcoin types
diff --git a/wire-gateway/src/main.rs b/wire-gateway/src/main.rs
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- Copyright (C) 2022 Taler Systems SA
+ Copyright (C) 2022-2025 Taler Systems SA
TALER is free software; you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License as published by the Free Software
@@ -24,28 +24,28 @@ use common::{
config::WireGatewayCfg,
currency::Currency,
log::{
- fail,
log::{error, info},
OrFail,
},
};
-use listenfd::ListenFd;
use sqlx::Row;
use sqlx::{postgres::PgListener, PgPool, QueryBuilder};
use std::{
- net::SocketAddr,
path::PathBuf,
- str::FromStr,
+ str::FromStr as _,
sync::{
- atomic::{AtomicBool, AtomicU32, Ordering},
+ atomic::{AtomicBool, Ordering},
Arc,
},
time::Duration,
};
use taler_api::{
+ api::{
+ wire::{self, WireGateway},
+ TalerApi, TalerRouter,
+ },
db::{page, BindHelper, TypeHelper},
error::{failure, failure_status, ApiResult},
- wire_gateway_api, WireGatewayImpl,
};
use taler_common::{
api_params::{History, Page},
@@ -55,18 +55,18 @@ use taler_common::{
TransferList, TransferRequest, TransferResponse, TransferState, TransferStatus,
},
error_code::ErrorCode,
- types::{payto::Payto, timestamp::Timestamp},
+ types::{payto::PaytoURI, timestamp::Timestamp},
};
use tokio::time::sleep;
struct ServerState {
pool: PgPool,
- payto: Payto,
+ payto: PaytoURI,
currency: Currency,
status: AtomicBool,
}
-impl WireGatewayImpl for ServerState {
+impl TalerApi for ServerState {
fn currency(&self) -> &str {
self.currency.to_str()
}
@@ -74,7 +74,9 @@ impl WireGatewayImpl for ServerState {
fn implementation(&self) -> Option<&str> {
None
}
+}
+impl WireGateway for ServerState {
async fn transfer(&self, req: TransferRequest) -> ApiResult<TransferResponse> {
if !check_payto(&req.credit_account, self.currency) {
return Err(failure(ErrorCode::GENERIC_PAYTO_URI_MALFORMED, "bad payto"));
@@ -207,6 +209,10 @@ impl WireGatewayImpl for ServerState {
async fn add_incoming_kyc(&self, _req: AddKycauthRequest) -> ApiResult<AddKycauthResponse> {
unimplemented!("depolymerization does not supports KYC")
}
+
+ fn support_account_check(&self) -> bool {
+ false
+ }
}
async fn status_middleware(
@@ -253,45 +259,22 @@ async fn main() {
payto: config.payto,
currency: config.currency,
});
- let lifetime = config.http_lifetime.map(AtomicU32::new);
-
- let router = wire_gateway_api(state.clone()).layer(middleware::from_fn_with_state(
- state.clone(),
- status_middleware,
- ));
- tokio::spawn(status_watcher(state));
-
- let mut listenfd = ListenFd::from_env();
-
- let listener = if let Some(listener) = listenfd.take_tcp_listener(0).unwrap() {
- info!(
- "Server listening on activated socket {}",
- listener.local_addr().unwrap()
- );
- tokio::net::TcpListener::from_std(listener).unwrap()
- } else if let Some(path) = config.unix {
- info!("Server listening on unix domain socket {:?}", path);
- if let Err(err) = std::fs::remove_file(&path) {
- if err.kind() != std::io::ErrorKind::NotFound {
- fail(format_args!("{}", err));
- }
- }
- //Listener::Unix(tokio::net::UnixListener::bind(path).unwrap())
- unimplemented!("UNIX domain socket TODO")
- } else {
- let addr: SocketAddr = ([0, 0, 0, 0], config.port).into();
- info!("Server listening on http://{}", &addr);
- tokio::net::TcpListener::bind(addr).await.unwrap()
- };
- taler_api::server(listener, router, config.auth, lifetime)
+ tokio::spawn(status_watcher(state.clone()));
+ wire::router(state.clone())
+ .auth(config.auth)
+ .layer(middleware::from_fn_with_state(
+ state.clone(),
+ status_middleware,
+ ))
+ .serve(config.serve, config.http_lifetime)
.await
.unwrap();
info!("wire-gateway stopped");
}
/// Check if a payto is valid the configured currency
-fn check_payto(payto: &Payto, currency: Currency) -> bool {
+fn check_payto(payto: &PaytoURI, currency: Currency) -> bool {
match currency {
Currency::ETH(_) => check_pay_to_eth(payto),
Currency::BTC(_) => check_pay_to_btc(payto),
@@ -299,7 +282,7 @@ fn check_payto(payto: &Payto, currency: Currency) -> bool {
}
/// Check if an url is a valid bitcoin payto url
-fn check_pay_to_btc(payto: &Payto) -> bool {
+fn check_pay_to_btc(payto: &PaytoURI) -> bool {
let url = payto.as_ref();
url.domain() == Some("bitcoin")
&& url.username() == ""
@@ -310,7 +293,7 @@ fn check_pay_to_btc(payto: &Payto) -> bool {
}
/// Check if an url is a valid ethereum payto url
-fn check_pay_to_eth(payto: &Payto) -> bool {
+fn check_pay_to_eth(payto: &PaytoURI) -> bool {
let url = payto.as_ref();
url.domain() == Some("ethereum")
&& url.username() == ""