diff --git a/.github/workflows/prerelease.yml b/.github/workflows/prerelease.yml index 2e3bc071..24a6593a 100644 --- a/.github/workflows/prerelease.yml +++ b/.github/workflows/prerelease.yml @@ -1,6 +1,9 @@ name: Pre-release Build on: + push: + branches: + - develop workflow_dispatch: inputs: version: diff --git a/Cargo.lock b/Cargo.lock index c29b3388..f5019f8b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -14,7 +14,7 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d122413f284cf2d62fb1b7db97e02edb8cda96d769b16e443a4f6195e35662b0" dependencies = [ - "crypto-common", + "crypto-common 0.1.7", "generic-array", ] @@ -25,8 +25,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" dependencies = [ "cfg-if", - "cipher", - "cpufeatures", + "cipher 0.4.4", + "cpufeatures 0.2.17", ] [[package]] @@ -37,7 +37,7 @@ checksum = "831010a0f742e1209b3bcea8fab6a8e149051ba6099432c8cb2cc117dec3ead1" dependencies = [ "aead", "aes", - "cipher", + "cipher 0.4.4", "ctr", "ghash", "subtle", @@ -167,15 +167,15 @@ dependencies = [ "async-trait", "axum", "axum-server", - "base64 0.22.1", + "base64", "bcrypt", "chrono", "cookie", "dotenvy", "entity", "etcd-client", - "http 1.4.0", - "hyper 1.8.1", + "http", + "hyper", "hyper-util", "image", "jsonwebtoken", @@ -186,22 +186,23 @@ dependencies = [ "opentelemetry_sdk", "prometheus", "qrcode", - "rand 0.8.5", + "rand 0.10.1", "rcgen", - "reqwest 0.11.27", + "reqwest", + "ring", "rsa", - "rustls 0.23.37", + "rustls", "sea-orm", "serde", "serde_json", - "sha1", - "sha2", + "sha1 0.11.0", + "sha2 0.11.0", "shared", "sysinfo", "thiserror 2.0.18", "tokio", "totp-rs", - "tower-http 0.5.2", + "tower-http 0.7.0", "tower_governor", "tracing", "tracing-opentelemetry", @@ -237,7 +238,7 @@ checksum = "0ae92a5119aa49cdbcf6b9f893fe4e1d98b04ccbf82ee0584ad948a44a734dea" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -257,27 +258,11 @@ dependencies = [ [[package]] name = "asn1-rs" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5493c3bedbacf7fd7382c6346bbd66687d12bbaad3a89a2d2c303ee6cf20b048" -dependencies = [ - "asn1-rs-derive 0.5.1", - "asn1-rs-impl", - "displaydoc", - "nom 7.1.3", - "num-traits", - "rusticata-macros", - "thiserror 1.0.69", - "time", -] - -[[package]] -name = "asn1-rs" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56624a96882bb8c26d61312ae18cb45868e5a9992ea73c58e45c3101e56a1e60" +checksum = "b7f43a50ac4fdca5df8e885c21b835997f0a1cdee65494a6847694a98652d9d8" dependencies = [ - "asn1-rs-derive 0.6.0", + "asn1-rs-derive", "asn1-rs-impl", "displaydoc", "nom 7.1.3", @@ -287,18 +272,6 @@ dependencies = [ "time", ] -[[package]] -name = "asn1-rs-derive" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "965c2d33e53cb6b267e148a4cb0760bc01f4904c1cd4bb4002a085bb016d1490" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.117", - "synstructure", -] - [[package]] name = "asn1-rs-derive" version = "0.6.0" @@ -307,7 +280,7 @@ checksum = "3109e49b1e4909e9db6515a30c633684d68cdeaa252f215214cb4fa1a5bfee2c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", "synstructure", ] @@ -319,7 +292,7 @@ checksum = "7b18050c2cd6fe86c3a76584ef5e0baf286d038cda203eb6223df2cc413565f7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -460,7 +433,7 @@ checksum = "c7c24de15d275a1ecfd47a380fb4d5ec9bfe0933f309ed5e705b775596a3574d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -477,7 +450,7 @@ checksum = "9035ad2d096bed7955a320ee7e2230574d28fd3c3a0f186cbea1ff3c7eed5dbb" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -497,9 +470,9 @@ checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" [[package]] name = "autocfg" -version = "1.5.0" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8" +checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53" [[package]] name = "av-scenechange" @@ -537,113 +510,42 @@ dependencies = [ [[package]] name = "avif-serialize" -version = "0.8.8" +version = "0.8.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "375082f007bd67184fb9c0374614b29f9aaa604ec301635f72338bb65386a53d" +checksum = "e7178fe5f7d460b13895ebb9dcb28a3a6216d2df2574a0806cb51b555d297f38" dependencies = [ "arrayvec", ] -[[package]] -name = "aws-lc-rs" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ec2f1fc3ec205783a5da9a7e6c1509cc69dedf09a1949e412c1e18469326d00" -dependencies = [ - "aws-lc-sys", - "zeroize", -] - -[[package]] -name = "aws-lc-sys" -version = "0.41.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a2f9779ce85b93ab6170dd940ad0169b5766ff848247aff13bb788b832fe3f4" -dependencies = [ - "cc", - "cmake", - "dunce", - "fs_extra", -] - [[package]] name = "axum" -version = "0.7.9" +version = "0.8.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edca88bc138befd0323b20752846e6587272d3b03b0343c8ea28a6f819e6e71f" +checksum = "31b698c5f9a010f6573133b09e0de5408834d0c82f8d7475a89fc1867a71cd90" dependencies = [ - "async-trait", - "axum-core 0.4.5", + "axum-core", "axum-macros", "bytes", + "form_urlencoded", "futures-util", - "http 1.4.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", - "hyper 1.8.1", + "hyper", "hyper-util", "itoa", - "matchit 0.7.3", + "matchit", "memchr", "mime", "percent-encoding", "pin-project-lite", - "rustversion", - "serde", + "serde_core", "serde_json", "serde_path_to_error", "serde_urlencoded", - "sync_wrapper 1.0.2", + "sync_wrapper", "tokio", - "tower 0.5.3", - "tower-layer", - "tower-service", - "tracing", -] - -[[package]] -name = "axum" -version = "0.8.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31b698c5f9a010f6573133b09e0de5408834d0c82f8d7475a89fc1867a71cd90" -dependencies = [ - "axum-core 0.5.6", - "bytes", - "futures-util", - "http 1.4.0", - "http-body 1.0.1", - "http-body-util", - "itoa", - "matchit 0.8.4", - "memchr", - "mime", - "percent-encoding", - "pin-project-lite", - "serde_core", - "serde_json", - "serde_path_to_error", - "sync_wrapper 1.0.2", - "tower 0.5.3", - "tower-layer", - "tower-service", -] - -[[package]] -name = "axum-core" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09f2bd6146b97ae3359fa0cc6d6b376d9539582c7b4220f041a33ec24c226199" -dependencies = [ - "async-trait", - "bytes", - "futures-util", - "http 1.4.0", - "http-body 1.0.1", - "http-body-util", - "mime", - "pin-project-lite", - "rustversion", - "sync_wrapper 1.0.2", + "tower", "tower-layer", "tower-service", "tracing", @@ -657,25 +559,26 @@ checksum = "08c78f31d7b1291f7ee735c1c6780ccde7785daae9a9206026862dab7d8792d1" dependencies = [ "bytes", "futures-core", - "http 1.4.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", "mime", "pin-project-lite", - "sync_wrapper 1.0.2", + "sync_wrapper", "tower-layer", "tower-service", + "tracing", ] [[package]] name = "axum-macros" -version = "0.4.2" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57d123550fa8d071b7255cb0cc04dc302baa6c8c4a79f55701552684d8399bce" +checksum = "7aa268c23bfbbd2c4363b9cd302a4f504fb2a9dfe7e3451d66f35dd392e20aca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -687,16 +590,16 @@ dependencies = [ "arc-swap", "bytes", "fs-err", - "http 1.4.0", - "http-body 1.0.1", - "hyper 1.8.1", + "http", + "http-body", + "hyper", "hyper-util", "pin-project-lite", - "rustls 0.23.37", - "rustls-pemfile 2.2.0", + "rustls", + "rustls-pemfile", "rustls-pki-types", "tokio", - "tokio-rustls 0.26.4", + "tokio-rustls", "tower-service", ] @@ -706,12 +609,6 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "022dfe9eb35f19ebbcb51e0b40a5ab759f46ad60cadf7297e0bd085afb50e076" -[[package]] -name = "base64" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" - [[package]] name = "base64" version = "0.22.1" @@ -726,13 +623,13 @@ checksum = "2af50177e190e07a26ab74f8b1efbfe2ef87da2116221318cb1c2e82baf7de06" [[package]] name = "bcrypt" -version = "0.15.1" +version = "0.19.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e65938ed058ef47d92cf8b346cc76ef48984572ade631927e9937b5ffc7662c7" +checksum = "7f3c067aa24dd4ed5c79cf222a38f260c8f23d3b82a062fba3f28c6fe563b753" dependencies = [ - "base64 0.22.1", + "base64", "blowfish", - "getrandom 0.2.17", + "getrandom 0.4.3", "subtle", "zeroize", ] @@ -752,33 +649,36 @@ dependencies = [ ] [[package]] -name = "bit_field" -version = "0.10.3" +name = "bit-vec" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e4b40c7323adcfc0a41c4b88143ed58346ff65a288fc144329c5c45e05d70c6" +checksum = "b71798fca2c1fe1086445a7258a4bc81e6e49dcd24c8d0dd9a1e57395b603f51" +dependencies = [ + "serde", +] [[package]] -name = "bitflags" -version = "1.3.2" +name = "bit_field" +version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" +checksum = "1e4b40c7323adcfc0a41c4b88143ed58346ff65a288fc144329c5c45e05d70c6" [[package]] name = "bitflags" -version = "2.11.0" +version = "2.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "843867be96c8daad0d758b57df9392b6d8d271134fce549de6ce169ff98a92af" +checksum = "b4388bee8683e3d04af747c73422af53102d2bd24d9eadb6cbc100baef4b43f8" dependencies = [ "serde_core", ] [[package]] name = "bitstream-io" -version = "4.9.0" +version = "4.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60d4bd9d1db2c6bdf285e223a7fa369d5ce98ec767dec949c6ca62863ce61757" +checksum = "7eff00be299a18769011411c9def0d827e8f2d7bf0c3dbf53633147a8867fd1f" dependencies = [ - "core2", + "no_std_io2", ] [[package]] @@ -802,6 +702,15 @@ dependencies = [ "generic-array", ] +[[package]] +name = "block-buffer" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2f6c7dbe95a6ed67ad9f18e57daf93a2f034c524b99fd2b76d18fdfeb6660aa" +dependencies = [ + "hybrid-array", +] + [[package]] name = "blocking" version = "1.6.2" @@ -817,29 +726,29 @@ dependencies = [ [[package]] name = "blowfish" -version = "0.9.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e412e2cd0f2b2d93e02543ceae7917b3c70331573df19ee046bcbc35e45e87d7" +checksum = "62ce3946557b35e71d1bbe07ec385073ce9eda05043f95de134eb578fcf1a298" dependencies = [ "byteorder", - "cipher", + "cipher 0.5.2", ] [[package]] name = "bollard" -version = "0.17.1" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d41711ad46fda47cd701f6908e59d1bd6b9a2b7464c0d0aeab95c6d37096ff8a" +checksum = "c9d0a013e3d3ee4edd61e779adf117944c08902d375f18630a0c5b8f95659734" dependencies = [ - "base64 0.22.1", + "base64", "bollard-stubs", "bytes", "futures-core", "futures-util", "hex", - "http 1.4.0", + "http", "http-body-util", - "hyper 1.8.1", + "hyper", "hyper-named-pipe", "hyper-util", "hyperlocal", @@ -848,9 +757,8 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_repr", "serde_urlencoded", - "thiserror 1.0.69", + "thiserror 2.0.18", "tokio", "tokio-util", "tower-service", @@ -860,49 +768,50 @@ dependencies = [ [[package]] name = "bollard-stubs" -version = "1.45.0-rc.26.0.1" +version = "1.53.1-rc.29.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d7c5415e3a6bc6d3e99eff6268e488fd4ee25e7b28c10f08fa6760bd9de16e4" +checksum = "ce412eb6f7096743011dc3cb5c674caeb24ced61d8c498fe07cf7998a4fea889" dependencies = [ "serde", + "serde_json", "serde_repr", - "serde_with", ] [[package]] name = "borsh" -version = "1.6.0" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1da5ab77c1437701eeff7c88d968729e7766172279eab0676857b3d63af7a6f" +checksum = "cfd1e3f8955a5d7de9fab72fc8373fade9fb8a703968cb200ae3dc6cf08e185a" dependencies = [ "borsh-derive", + "bytes", "cfg_aliases", ] [[package]] name = "borsh-derive" -version = "1.6.0" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0686c856aa6aac0c4498f936d7d6a02df690f614c03e4d906d1018062b5c5e2c" +checksum = "bfcfdc083699101d5a7965e49925975f2f55060f94f9a05e7187be95d530ca59" dependencies = [ "once_cell", "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "built" -version = "0.8.0" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4ad8f11f288f48ca24471bbd51ac257aaeaaa07adae295591266b792902ae64" +checksum = "5c0e531d93d39c34eef561e929e8a7f86d77a5af08aac4f6d6e39976c51858e9" [[package]] name = "bumpalo" -version = "3.20.2" +version = "3.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d20789868f4b01b2f2caec9f5c4e0213b41e3e5702a50157d699ae31ced2fcb" +checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649" [[package]] name = "bytecheck" @@ -952,9 +861,9 @@ checksum = "1e748733b7cbc798e1434b6ac524f0c1ff2ab456fe201501e6497c8417a4fc33" [[package]] name = "cc" -version = "1.2.57" +version = "1.2.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a0dd1ca384932ff3641c8718a02769f1698e7563dc6974ffd03346116310423" +checksum = "dad887fd958be91b5098c0248def011f4523ab786cd411be668777e55063501f" dependencies = [ "find-msvc-tools", "jobserver", @@ -962,6 +871,12 @@ dependencies = [ "shlex", ] +[[package]] +name = "cesu8" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" + [[package]] name = "cfg-if" version = "1.0.4" @@ -974,11 +889,22 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" +[[package]] +name = "chacha20" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f8d983286843e49675a4b7a2d174efe136dc93a18d69130dd18198a6c167601" +dependencies = [ + "cfg-if", + "cpufeatures 0.3.0", + "rand_core 0.10.1", +] + [[package]] name = "chrono" -version = "0.4.44" +version = "0.4.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c673075a2e0e5f4a1dde27ce9dee1ea4558c7ffe648f576438a20ca1d2acc4b0" +checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327" dependencies = [ "iana-time-zone", "js-sys", @@ -994,15 +920,25 @@ version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad" dependencies = [ - "crypto-common", - "inout", + "crypto-common 0.1.7", + "inout 0.1.4", +] + +[[package]] +name = "cipher" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8cf2a2c93cd704877c0858356ed03480ff301ee950b43f1cbe4573b088bfa6c" +dependencies = [ + "crypto-common 0.2.2", + "inout 0.2.2", ] [[package]] name = "clap" -version = "4.6.0" +version = "4.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b193af5b67834b676abd72466a96c1024e6a6ad978a1f484bd90b85c94041351" +checksum = "1ddb117e43bbf7dacf0a4190fef4d345b9bad68dfc649cb349e7d17d28428e51" dependencies = [ "clap_builder", "clap_derive", @@ -1022,14 +958,14 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.6.0" +version = "4.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1110bd8a634a1ab8cb04345d8d878267d57c3cf1b38d91b71af6686408bbca6a" +checksum = "f2ce8604710f6733aa641a2b3731eaa1e8b3d9973d5e3565da11800813f997a9" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -1038,15 +974,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c8d4a3bb8b1e0c1050499d1815f5ab16d04f0959b233085fb31653fbfc9d98f9" -[[package]] -name = "cmake" -version = "0.1.58" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0f78a02292a74a88ac736019ab962ece0bc380e3f977bf72e376c5d78ff0678" -dependencies = [ - "cc", -] - [[package]] name = "color_quant" version = "1.1.0" @@ -1059,6 +986,16 @@ version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1d07550c9036bf2ae0c684c4297d503f838287c83c53686d05370d0e139ae570" +[[package]] +name = "combine" +version = "4.6.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba5a308b75df32fe02788e748662718f03fde005016435c444eea572398219fd" +dependencies = [ + "bytes", + "memchr", +] + [[package]] name = "concurrent-queue" version = "2.5.0" @@ -1074,6 +1011,12 @@ version = "0.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" +[[package]] +name = "const-oid" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a6ef517f0926dd24a1582492c791b6a4818a4d94e789a334894aa15b0d12f55c" + [[package]] name = "constant_time_eq" version = "0.3.1" @@ -1091,16 +1034,6 @@ dependencies = [ "version_check", ] -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - [[package]] name = "core-foundation" version = "0.10.1" @@ -1118,19 +1051,19 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" [[package]] -name = "core2" -version = "0.4.0" +name = "cpufeatures" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b49ba7ef1ad6107f8824dbe97de947cbaac53c44e7f9756a1fba0d37c1eec505" +checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" dependencies = [ - "memchr", + "libc", ] [[package]] name = "cpufeatures" -version = "0.2.17" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" +checksum = "8b2a41393f66f16b0823bb79094d54ac5fbd34ab292ddafb9a0456ac9f87d201" dependencies = [ "libc", ] @@ -1146,9 +1079,9 @@ dependencies = [ [[package]] name = "crc-catalog" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" +checksum = "217698eaf96b4a3f0bc4f3662aaa55bdf913cd54d7204591faa790070c6d0853" [[package]] name = "crc32fast" @@ -1210,6 +1143,15 @@ dependencies = [ "typenum", ] +[[package]] +name = "crypto-common" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce6e4c961d6cd6c9a86db418387425e8bdeaf05b3c8bc1411e6dca4c252f1453" +dependencies = [ + "hybrid-array", +] + [[package]] name = "csfx-agent" version = "0.2.2" @@ -1219,7 +1161,9 @@ dependencies = [ "chrono", "futures-util", "rcgen", - "reqwest 0.12.28", + "reqwest", + "ring", + "rustls", "serde", "serde_json", "sysinfo", @@ -1249,7 +1193,9 @@ dependencies = [ "anyhow", "dotenvy", "etcd-client", - "reqwest 0.11.27", + "reqwest", + "ring", + "rustls", "serde", "serde_json", "tokio", @@ -1263,7 +1209,7 @@ version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" dependencies = [ - "cipher", + "cipher 0.4.4", ] [[package]] @@ -1286,7 +1232,7 @@ dependencies = [ "ident_case", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -1297,16 +1243,17 @@ checksum = "fc34b93ccb385b40dc71c6fceac4b2ad23662c7eeb248cf10d529b7e055b6ead" dependencies = [ "darling_core", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "dashmap" -version = "5.5.3" +version = "6.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" +checksum = "e6361d5c062261c78a176addb82d4c821ae42bed6089de0e12603cd25de2059c" dependencies = [ "cfg-if", + "crossbeam-utils", "hashbrown 0.14.5", "lock_api", "once_cell", @@ -1315,9 +1262,9 @@ dependencies = [ [[package]] name = "data-encoding" -version = "2.10.0" +version = "2.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7a1e2f27636f116493b8b860f5546edb47c8d8f8ea73e1d2a20be88e28d1fea" +checksum = "a4ae5f15dda3c708c0ade84bfee31ccab44a3da4f88015ed22f63732abe300c8" [[package]] name = "der" @@ -1325,32 +1272,18 @@ version = "0.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e7c1832837b905bbfb5101e07cc24c8deddf52f93225eee6ead5f4d63d53ddcb" dependencies = [ - "const-oid", + "const-oid 0.9.6", "pem-rfc7468", "zeroize", ] -[[package]] -name = "der-parser" -version = "9.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cd0a5c643689626bec213c4d8bd4d96acc8ffdb4ad4bb6bc16abf27d5f4b553" -dependencies = [ - "asn1-rs 0.6.2", - "displaydoc", - "nom 7.1.3", - "num-bigint", - "num-traits", - "rusticata-macros", -] - [[package]] name = "der-parser" version = "10.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "07da5016415d5a3c4dd39b11ed26f915f52fc4e0dc197d87908bc916e51bc1a6" dependencies = [ - "asn1-rs 0.7.1", + "asn1-rs", "displaydoc", "nom 7.1.3", "num-bigint", @@ -1364,7 +1297,6 @@ version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7cd812cc2bc1d69d4764bd80df88b4317eaef9e773c75226407d9bc0876b211c" dependencies = [ - "powerfmt", "serde_core", ] @@ -1376,7 +1308,7 @@ checksum = "1e567bd82dcff979e4b03460c307b3cdc9e96fde3d73bed1496d2bc75d9dd62a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -1397,7 +1329,7 @@ dependencies = [ "proc-macro2", "quote", "rustc_version", - "syn 2.0.117", + "syn 2.0.118", "unicode-xid", ] @@ -1407,21 +1339,32 @@ version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "block-buffer", - "const-oid", - "crypto-common", + "block-buffer 0.10.4", + "const-oid 0.9.6", + "crypto-common 0.1.7", "subtle", ] +[[package]] +name = "digest" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2" +dependencies = [ + "block-buffer 0.12.1", + "const-oid 0.10.2", + "crypto-common 0.2.2", +] + [[package]] name = "displaydoc" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +checksum = "1ac70aa55017e108007fbaf5aa0f54b021c98f92ff8af59d42eda9da96e3dd4f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -1430,36 +1373,15 @@ version = "0.15.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" -[[package]] -name = "dunce" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" - -[[package]] -name = "dyn-clone" -version = "1.0.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555" - [[package]] name = "either" -version = "1.15.0" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719" +checksum = "91622ff5e7162018101f2fea40d6ebf4a78bbe5a49736a2020649edf9693679e" dependencies = [ "serde", ] -[[package]] -name = "encoding_rs" -version = "0.8.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3" -dependencies = [ - "cfg-if", -] - [[package]] name = "entity" version = "0.2.2" @@ -1489,7 +1411,7 @@ checksum = "44f23cf4b44bfce11a86ace86f8a73ffdec849c9fd00a386a53d278bd9e81fb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -1510,17 +1432,19 @@ dependencies = [ [[package]] name = "etcd-client" -version = "0.14.1" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc0452bcc559431b16f472b7ab86e2f9ccd5f3c2da3795afbd6b773665e047fe" +checksum = "ef5da6e9a6ae89f4a91f80ba1caae45a5a924397a19947e18f5121a43285e9bc" dependencies = [ - "http 1.4.0", - "prost 0.13.5", + "http", + "prost", "tokio", "tokio-stream", - "tonic 0.12.3", + "tonic", "tonic-build", - "tower 0.4.13", + "tonic-prost", + "tonic-prost-build", + "tower", "tower-service", ] @@ -1582,7 +1506,7 @@ name = "failover-controller" version = "0.2.2" dependencies = [ "anyhow", - "axum 0.7.9", + "axum", "chrono", "dotenvy", "entity", @@ -1592,7 +1516,9 @@ dependencies = [ "opentelemetry-semantic-conventions", "opentelemetry_sdk", "prometheus", - "reqwest 0.11.27", + "reqwest", + "ring", + "rustls", "sea-orm", "serde", "serde_json", @@ -1606,29 +1532,15 @@ dependencies = [ [[package]] name = "fastrand" -version = "2.3.0" +version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" +checksum = "9f1f227452a390804cdb637b74a86990f2a7d7ba4b7d5693aac9b4dd6defd8d6" [[package]] name = "fax" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f05de7d48f37cd6730705cbca900770cab77a89f413d23e100ad7fad7795a0ab" -dependencies = [ - "fax_derive", -] - -[[package]] -name = "fax_derive" -version = "0.2.0" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0aca10fb742cb43f9e7bb8467c91aa9bcb8e3ffbc6a6f7389bb93ffc920577d" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.117", -] +checksum = "caf1079563223d5d59d83c85886a56e586cfd5c1a26292e971a0fa266531ac5a" [[package]] name = "fdeflate" @@ -1685,6 +1597,12 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" +[[package]] +name = "foldhash" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" + [[package]] name = "form_urlencoded" version = "1.2.2" @@ -1714,12 +1632,6 @@ dependencies = [ "tokio", ] -[[package]] -name = "fs_extra" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42703706b716c37f96a77aea830392ad231f44c9e9a67872fa5548707e11b11c" - [[package]] name = "funty" version = "2.0.0" @@ -1734,7 +1646,6 @@ checksum = "8b147ee9d1f6d097cef9ce628cd2ee62288d963e16fb287bd9286455b241382d" dependencies = [ "futures-channel", "futures-core", - "futures-executor", "futures-io", "futures-sink", "futures-task", @@ -1806,7 +1717,7 @@ checksum = "e835b70203e41293343137df5c0664546da5745f82ec9b84d40be8336958447b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -1823,9 +1734,9 @@ checksum = "037711b3d59c33004d3856fbdc83b99d4ff37a24768fa1be9ce3538a1cde4393" [[package]] name = "futures-timer" -version = "3.0.3" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f288b0a4f20f9a56b5d1da57e2227c661b7b16168e2f72365f57b63326e29b24" +checksum = "af43fadb8a98512d547e37b4e92e0ced13e205c061b87b4623eff01d918d6968" [[package]] name = "futures-util" @@ -1833,7 +1744,6 @@ version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "389ca41296e6190b48053de0321d02a77f32f8a5d2461dd38762c0593805c6d6" dependencies = [ - "futures-channel", "futures-core", "futures-io", "futures-macro", @@ -1861,10 +1771,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0" dependencies = [ "cfg-if", - "js-sys", "libc", "wasi", - "wasm-bindgen", ] [[package]] @@ -1883,15 +1791,14 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0de51e6874e94e7bf76d726fc5d13ba782deca734ff60d5bb2fb2607c7406555" +checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099" dependencies = [ "cfg-if", "libc", "r-efi 6.0.0", - "wasip2", - "wasip3", + "rand_core 0.10.1", ] [[package]] @@ -1906,9 +1813,9 @@ dependencies = [ [[package]] name = "gif" -version = "0.14.1" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5df2ba84018d80c213569363bdcd0c64e6933c67fe4c1d60ecf822971a3c35e" +checksum = "ee8cfcc411d9adbbaba82fb72661cc1bcca13e8bba98b364e62b2dba8f960159" dependencies = [ "color_quant", "weezl", @@ -1934,56 +1841,40 @@ dependencies = [ [[package]] name = "governor" -version = "0.6.3" +version = "0.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68a7f542ee6b35af73b06abc0dad1c1bae89964e4e253bc4b587b91c9637867b" +checksum = "9efcab3c1958580ff1f25a2a41be1668f7603d849bb63af523b208a3cc1223b8" dependencies = [ "cfg-if", "dashmap", - "futures", + "futures-sink", "futures-timer", - "no-std-compat", + "futures-util", + "getrandom 0.3.4", + "hashbrown 0.16.1", "nonzero_ext", "parking_lot", "portable-atomic", "quanta", - "rand 0.8.5", + "rand 0.9.4", "smallvec", "spinning_top", + "web-time", ] [[package]] name = "h2" -version = "0.3.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0beca50380b1fc32983fc1cb4587bfa4bb9e78fc259aad4a0032d2080309222d" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http 0.2.12", - "indexmap 2.13.0", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "h2" -version = "0.4.13" +version = "0.4.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f44da3a8150a6703ed5d34e164b875fd14c2cdab9af1252a9a1020bde2bdc54" +checksum = "6cb093c84e8bd9b188d4c4a8cb6579fc016968d14c99882163cd3ff402a4f155" dependencies = [ "atomic-waker", "bytes", "fnv", "futures-core", "futures-sink", - "http 1.4.0", - "indexmap 2.13.0", + "http", + "indexmap", "slab", "tokio", "tokio-util", @@ -2024,7 +1915,7 @@ checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1" dependencies = [ "allocator-api2", "equivalent", - "foldhash", + "foldhash 0.1.5", ] [[package]] @@ -2032,6 +1923,17 @@ name = "hashbrown" version = "0.16.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" +dependencies = [ + "allocator-api2", + "equivalent", + "foldhash 0.2.0", +] + +[[package]] +name = "hashbrown" +version = "0.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" [[package]] name = "hashlink" @@ -2081,7 +1983,7 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest", + "digest 0.10.7", ] [[package]] @@ -2095,36 +1997,14 @@ dependencies = [ [[package]] name = "http" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "601cbb57e577e2f5ef5be8e7b83f0f63994f25aa94d673e54a92d5c516d101f1" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http" -version = "1.4.0" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3ba2a386d7f85a81f119ad7498ebe444d2e22c2af0b86b069416ace48b3311a" +checksum = "6970f50e31d6fc17d3fa27329444bfa74e196cf62e95052a3f6fee181dba6425" dependencies = [ "bytes", "itoa", ] -[[package]] -name = "http-body" -version = "0.4.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" -dependencies = [ - "bytes", - "http 0.2.12", - "pin-project-lite", -] - [[package]] name = "http-body" version = "1.0.1" @@ -2132,7 +2012,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", - "http 1.4.0", + "http", ] [[package]] @@ -2143,8 +2023,8 @@ checksum = "b021d93e26becf5dc7e1b75b1bed1fd93124b374ceb73f43d4d4eafec896a64a" dependencies = [ "bytes", "futures-core", - "http 1.4.0", - "http-body 1.0.1", + "http", + "http-body", "pin-project-lite", ] @@ -2167,47 +2047,31 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" [[package]] -name = "hyper" -version = "0.14.32" +name = "hybrid-array" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41dfc780fdec9373c01bae43289ea34c972e40ee3c9f6b3c8801a35f35586ce7" +checksum = "9155a582abd142abc056962c29e3ce5ff2ad5469f4246b537ed42c5deba857da" dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2 0.3.27", - "http 0.2.12", - "http-body 0.4.6", - "httparse", - "httpdate", - "itoa", - "pin-project-lite", - "socket2 0.5.10", - "tokio", - "tower-service", - "tracing", - "want", + "typenum", ] [[package]] name = "hyper" -version = "1.8.1" +version = "1.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ab2d4f250c3d7b1c9fcdff1cece94ea4e2dfbec68614f7b87cb205f24ca9d11" +checksum = "55281c53a1894c864990125767da440a4e630446785086f52523b20033b74498" dependencies = [ "atomic-waker", "bytes", "futures-channel", "futures-core", - "h2 0.4.13", - "http 1.4.0", - "http-body 1.0.1", + "h2", + "http", + "http-body", "httparse", "httpdate", "itoa", "pin-project-lite", - "pin-utils", "smallvec", "tokio", "want", @@ -2220,7 +2084,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "73b7d8abf35697b81a825e386fc151e0d503e8cb5fcb93cc8669c376dfd6f278" dependencies = [ "hex", - "hyper 1.8.1", + "hyper", "hyper-util", "pin-project-lite", "tokio", @@ -2230,33 +2094,17 @@ dependencies = [ [[package]] name = "hyper-rustls" -version = "0.24.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590" -dependencies = [ - "futures-util", - "http 0.2.12", - "hyper 0.14.32", - "rustls 0.21.12", - "tokio", - "tokio-rustls 0.24.1", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.7" +version = "0.27.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3c93eb611681b207e1fe55d5a71ecf91572ec8a6705cdb6857f7d8d5242cf58" +checksum = "33ca68d021ef39cf6463ab54c1d0f5daf03377b70561305bb89a8f83aab66e0f" dependencies = [ - "http 1.4.0", - "hyper 1.8.1", + "http", + "hyper", "hyper-util", - "rustls 0.23.37", - "rustls-pki-types", + "rustls", "tokio", - "tokio-rustls 0.26.4", + "tokio-rustls", "tower-service", - "webpki-roots 1.0.6", ] [[package]] @@ -2265,7 +2113,7 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2b90d566bffbce6a75bd8b09a05aa8c2cb1fabb6cb348f8840c9e4c90a0d83b0" dependencies = [ - "hyper 1.8.1", + "hyper", "hyper-util", "pin-project-lite", "tokio", @@ -2278,18 +2126,18 @@ version = "0.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96547c2556ec9d12fb1578c4eaf448b04993e7fb79cbaad930a656880a6bdfa0" dependencies = [ - "base64 0.22.1", + "base64", "bytes", "futures-channel", "futures-util", - "http 1.4.0", - "http-body 1.0.1", - "hyper 1.8.1", + "http", + "http-body", + "hyper", "ipnet", "libc", "percent-encoding", "pin-project-lite", - "socket2 0.6.3", + "socket2", "tokio", "tower-service", "tracing", @@ -2303,7 +2151,7 @@ checksum = "986c5ce3b994526b3cd75578e62554abd09f0899d6206de48b3e96ab34ccc8c7" dependencies = [ "hex", "http-body-util", - "hyper 1.8.1", + "hyper", "hyper-util", "pin-project-lite", "tokio", @@ -2336,12 +2184,13 @@ dependencies = [ [[package]] name = "icu_collections" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c6b649701667bbe825c3b7e6388cb521c23d88644678e83c0c4d0a621a34b43" +checksum = "2984d1cd16c883d7935b9e07e44071dca8d917fd52ecc02c04d5fa0b5a3f191c" dependencies = [ "displaydoc", "potential_utf", + "utf8_iter", "yoke", "zerofrom", "zerovec", @@ -2349,9 +2198,9 @@ dependencies = [ [[package]] name = "icu_locale_core" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edba7861004dd3714265b4db54a3c390e880ab658fec5f7db895fae2046b5bb6" +checksum = "92219b62b3e2b4d88ac5119f8904c10f8f61bf7e95b640d25ba3075e6cac2c29" dependencies = [ "displaydoc", "litemap", @@ -2362,9 +2211,9 @@ dependencies = [ [[package]] name = "icu_normalizer" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f6c8828b67bf8908d82127b2054ea1b4427ff0230ee9141c54251934ab1b599" +checksum = "c56e5ee99d6e3d33bd91c5d85458b6005a22140021cc324cea84dd0e72cff3b4" dependencies = [ "icu_collections", "icu_normalizer_data", @@ -2376,15 +2225,15 @@ dependencies = [ [[package]] name = "icu_normalizer_data" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7aedcccd01fc5fe81e6b489c15b247b8b0690feb23304303a9e560f37efc560a" +checksum = "da3be0ae77ea334f4da67c12f149704f19f81d1adf7c51cf482943e84a2bad38" [[package]] name = "icu_properties" -version = "2.1.2" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "020bfc02fe870ec3a66d93e677ccca0562506e5872c650f893269e08615d74ec" +checksum = "bee3b67d0ea5c2cca5003417989af8996f8604e34fb9ddf96208a033901e70de" dependencies = [ "icu_collections", "icu_locale_core", @@ -2396,15 +2245,15 @@ dependencies = [ [[package]] name = "icu_properties_data" -version = "2.1.2" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "616c294cf8d725c6afcd8f55abc17c56464ef6211f9ed59cccffe534129c77af" +checksum = "8e2bbb201e0c04f7b4b3e14382af113e17ba4f63e2c9d2ee626b720cbce54a14" [[package]] name = "icu_provider" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85962cf0ce02e1e0a629cc34e7ca3e373ce20dda4c4d7294bbd0bf1fdb59e614" +checksum = "139c4cf31c8b5f33d7e199446eff9c1e02decfc2f0eec2c8d71f65befa45b421" dependencies = [ "displaydoc", "icu_locale_core", @@ -2415,12 +2264,6 @@ dependencies = [ "zerovec", ] -[[package]] -name = "id-arena" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d3067d79b975e8844ca9eb072e16b31c3c1c36928edf9c6789548c524d0d954" - [[package]] name = "ident_case" version = "1.0.1" @@ -2440,9 +2283,9 @@ dependencies = [ [[package]] name = "idna_adapter" -version = "1.2.1" +version = "1.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acae9609540aa318d1bc588455225fb2085b9ed0c4f6bd0d9d5bcd86f1a0344" +checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714" dependencies = [ "icu_normalizer", "icu_properties", @@ -2484,29 +2327,18 @@ dependencies = [ [[package]] name = "imgref" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7c5cedc30da3a610cac6b4ba17597bdf7152cf974e8aab3afb3d54455e371c8" - -[[package]] -name = "indexmap" -version = "1.9.3" +version = "1.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown 0.12.3", - "serde", -] +checksum = "89194689a993ab15268672e99e7b0e19da2da3268ac682e8f02d29d4d1434cd7" [[package]] name = "indexmap" -version = "2.13.0" +version = "2.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7714e70437a7dc3ac8eb7e6f8df75fd8eb422675fc7678aff7364301092b1017" +checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9" dependencies = [ "equivalent", - "hashbrown 0.16.1", + "hashbrown 0.17.1", "serde", "serde_core", ] @@ -2519,7 +2351,7 @@ checksum = "c727f80bfa4a6c6e2508d2f05b6f4bfce242030bd88ed15ae5331c5b5d30fba7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -2531,6 +2363,15 @@ dependencies = [ "generic-array", ] +[[package]] +name = "inout" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4250ce6452e92010fdf7268ccc5d14faa80bb12fc741938534c58f16804e03c7" +dependencies = [ + "hybrid-array", +] + [[package]] name = "interpolate_name" version = "0.2.4" @@ -2539,7 +2380,7 @@ checksum = "c34819042dc3d3971c46c2190835914dfbe0c3c13f61449b2997f4e9722dfa60" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -2548,16 +2389,6 @@ version = "2.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d98f6fed1fde3f8c21bc40a1abb88dd75e67924f9cffc3ef95607bad8017f8e2" -[[package]] -name = "iri-string" -version = "0.7.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c91338f0783edbd6195decb37bae672fd3b165faffb89bf7b9e6942f8b1a731a" -dependencies = [ - "memchr", - "serde", -] - [[package]] name = "is_terminal_polyfill" version = "1.70.2" @@ -2575,9 +2406,53 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.17" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682" + +[[package]] +name = "jni" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a87aa2bb7d2af34197c04845522473242e1aa17c12f4935d5856491a7fb8c97" +dependencies = [ + "cesu8", + "cfg-if", + "combine", + "jni-sys 0.3.1", + "log", + "thiserror 1.0.69", + "walkdir", + "windows-sys 0.45.0", +] + +[[package]] +name = "jni-sys" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258" +dependencies = [ + "jni-sys 0.4.1", +] + +[[package]] +name = "jni-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2" +dependencies = [ + "jni-sys-macros", +] + +[[package]] +name = "jni-sys-macros" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92ecc6618181def0457392ccd0ee51198e065e016d1d527a7ac1b6dc7c1f09d2" +checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264" +dependencies = [ + "quote", + "syn 2.0.118", +] [[package]] name = "jobserver" @@ -2591,11 +2466,12 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.91" +version = "0.3.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b49715b7073f385ba4bc528e5747d02e66cb39c6146efb66b781f131f0fb399c" +checksum = "03d04c30968dffe80775bd4d7fb676131cd04a1fb46d2686dbffbaec2d9dfd31" dependencies = [ - "once_cell", + "cfg-if", + "futures-util", "wasm-bindgen", ] @@ -2605,7 +2481,7 @@ version = "10.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eba32bfb4ffdeaca3e34431072faf01745c9b26d25504aa7a6cf5684334fc4fc" dependencies = [ - "base64 0.22.1", + "base64", "getrandom 0.2.17", "js-sys", "pem", @@ -2634,12 +2510,6 @@ dependencies = [ "spin", ] -[[package]] -name = "leb128fmt" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09edd9e8b54e49e587e4f6295a7d29c3ea94d469cb40ab8ca70b288248a81db2" - [[package]] name = "lebe" version = "0.5.3" @@ -2648,15 +2518,15 @@ checksum = "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8" [[package]] name = "libc" -version = "0.2.183" +version = "0.2.186" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5b646652bf6661599e1da8901b3b9522896f01e736bad5f723fe7a3a27f899d" +checksum = "68ab91017fe16c622486840e4c83c9a37afeff978bd239b5293d61ece587de66" [[package]] name = "libfuzzer-sys" -version = "0.4.12" +version = "0.4.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f12a681b7dd8ce12bff52488013ba614b869148d54dd79836ab85aafdd53f08d" +checksum = "a9fd2f41a1cba099f79a0b6b6c35656cf7c03351a7bae8ff0f28f25270f929d2" dependencies = [ "arbitrary", "cc", @@ -2670,14 +2540,14 @@ checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981" [[package]] name = "libredox" -version = "0.1.14" +version = "0.1.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1744e39d1d6a9948f4f388969627434e31128196de472883b39f148769bfe30a" +checksum = "f02ab6bace2054fb888a3c16f990117b579d14a3088e472d63c6011fa185c9d3" dependencies = [ - "bitflags 2.11.0", + "bitflags", "libc", "plain", - "redox_syscall 0.7.3", + "redox_syscall 0.8.1", ] [[package]] @@ -2704,9 +2574,9 @@ checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53" [[package]] name = "litemap" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6373607a59f0be73a39b6fe456b8192fcc3585f602af20751600e974dd455e77" +checksum = "92daf443525c4cce67b150400bc2316076100ce0b3686209eb8cf3c31612e6f0" [[package]] name = "lock_api" @@ -2719,9 +2589,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.29" +version = "0.4.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e5032e24019045c762d3c0f28f5b6b8bbf38563a65908389bf7978758920897" +checksum = "953f07c43838f8e6f9758cab68bf5bed85465e7587ebe0b823f1bcd81978ad3a" dependencies = [ "value-bag", ] @@ -2736,10 +2606,15 @@ dependencies = [ ] [[package]] -name = "lru-slab" -version = "0.1.2" +name = "mac_address" +version = "1.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154" +checksum = "c0aeb26bf5e836cc1c341c8106051b573f1766dfa05aa87f0b98be5e51b02303" +dependencies = [ + "nix", + "serde", + "winapi", +] [[package]] name = "matchers" @@ -2750,12 +2625,6 @@ dependencies = [ "regex-automata", ] -[[package]] -name = "matchit" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e7465ac9959cc2b1404e8e2367b43684a6d13790fe23056cc8c6c5a6b7bcb94" - [[package]] name = "matchit" version = "0.8.4" @@ -2779,14 +2648,23 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" dependencies = [ "cfg-if", - "digest", + "digest 0.10.7", ] [[package]] name = "memchr" -version = "2.8.0" +version = "2.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79" +checksum = "88904434abc2901f197fe8cc55f0445e7ded921dba5911dad2e2b39b48e663c4" + +[[package]] +name = "memoffset" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" +dependencies = [ + "autocfg", +] [[package]] name = "migration" @@ -2830,9 +2708,9 @@ dependencies = [ [[package]] name = "mio" -version = "1.1.1" +version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a69bcab0ad47271a0234d9422b131806bf3968021e5dc9328caf2d4cd58557fc" +checksum = "02bd0af71c67b473010cbbc60715ee815645a4dc942899111f494b4b737d6fda" dependencies = [ "libc", "wasi", @@ -2862,10 +2740,26 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" [[package]] -name = "no-std-compat" -version = "0.4.1" +name = "nix" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46" +dependencies = [ + "bitflags", + "cfg-if", + "cfg_aliases", + "libc", + "memoffset", +] + +[[package]] +name = "no_std_io2" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b93853da6d84c2e3c7d730d6473e8817692dd89be387eb01b94d7f108ecb5b8c" +checksum = "418abd1b6d34fbf6cae440dc874771b0525a604428704c76e48b29a5e67b8003" +dependencies = [ + "memchr", +] [[package]] name = "nom" @@ -2943,16 +2837,16 @@ dependencies = [ "num-integer", "num-iter", "num-traits", - "rand 0.8.5", + "rand 0.8.6", "smallvec", "zeroize", ] [[package]] name = "num-conv" -version = "0.2.0" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf97ec579c3c42f953ef76dbf8d55ac91fb219dde70e49aa4a6b7d74e9919050" +checksum = "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441" [[package]] name = "num-derive" @@ -2962,7 +2856,7 @@ checksum = "ed3955f1a9c7c0c15e092f9c887db08b1fc683305fdf6eb6684f22555355e202" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -3006,22 +2900,13 @@ dependencies = [ "libm", ] -[[package]] -name = "oid-registry" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8d8034d9489cdaf79228eb9f6a3b8d7bb32ba00d6645ebd48eef4077ceb5bd9" -dependencies = [ - "asn1-rs 0.6.2", -] - [[package]] name = "oid-registry" version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "12f40cff3dde1b6087cc5d5f5d4d65712f34016a03ed60e9c08dcc392736b5b7" dependencies = [ - "asn1-rs 0.7.1", + "asn1-rs", ] [[package]] @@ -3050,9 +2935,9 @@ checksum = "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe" [[package]] name = "opentelemetry" -version = "0.31.0" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b84bcd6ae87133e903af7ef497404dda70c60d0ea14895fc8a5e6722754fc2a0" +checksum = "b0142c63252a9e054e68a4c61a5778f7b14f576274d593f8ce883d191a099682" dependencies = [ "futures-core", "futures-sink", @@ -3062,69 +2947,55 @@ dependencies = [ "tracing", ] -[[package]] -name = "opentelemetry-http" -version = "0.31.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7a6d09a73194e6b66df7c8f1b680f156d916a1a942abf2de06823dd02b7855d" -dependencies = [ - "async-trait", - "bytes", - "http 1.4.0", - "opentelemetry", - "reqwest 0.12.28", -] - [[package]] name = "opentelemetry-otlp" -version = "0.31.0" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a2366db2dca4d2ad033cad11e6ee42844fd727007af5ad04a1730f4cb8163bf" +checksum = "9966929966d17620d7c316c643ba62631826e10021409357772d5eea84f62c35" dependencies = [ - "http 1.4.0", + "http", "opentelemetry", - "opentelemetry-http", "opentelemetry-proto", "opentelemetry_sdk", - "prost 0.14.3", - "reqwest 0.12.28", + "prost", "thiserror 2.0.18", "tokio", - "tonic 0.14.5", - "tracing", + "tonic", + "tonic-types", ] [[package]] name = "opentelemetry-proto" -version = "0.31.0" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7175df06de5eaee9909d4805a3d07e28bb752c34cab57fa9cff549da596b30f" +checksum = "56d658ba1faf63f7b9c492cfbe6e0ec365440a16132d3270c1065f7b33f1b638" dependencies = [ "opentelemetry", "opentelemetry_sdk", - "prost 0.14.3", - "tonic 0.14.5", + "prost", + "tonic", "tonic-prost", ] [[package]] name = "opentelemetry-semantic-conventions" -version = "0.31.0" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e62e29dfe041afb8ed2a6c9737ab57db4907285d999ef8ad3a59092a36bdc846" +checksum = "6ca2f98a0437b427b4b08f19f1caa3c44db885a202bc12cfea13d6c702243d68" [[package]] name = "opentelemetry_sdk" -version = "0.31.0" +version = "0.32.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ae4f5991976fd48df6d843de219ca6d31b01daaab2dad5af2badeded372bd" +checksum = "9b59f80e1ac4d5ff7a2db8fb6c80badb7f0f3f858211fba08dd9aaec750894f9" dependencies = [ "futures-channel", "futures-executor", "futures-util", "opentelemetry", "percent-encoding", - "rand 0.9.2", + "portable-atomic", + "rand 0.9.4", "thiserror 2.0.18", "tokio", "tokio-stream", @@ -3160,7 +3031,7 @@ dependencies = [ "proc-macro2", "proc-macro2-diagnostics", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -3210,7 +3081,7 @@ version = "3.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1d30c53c26bc5b31a98cd02d20f25a7c8567146caf63ed593a9d87b2775291be" dependencies = [ - "base64 0.22.1", + "base64", "serde_core", ] @@ -3231,41 +3102,42 @@ checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" [[package]] name = "petgraph" -version = "0.7.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3672b37090dbd86368a4145bc067582552b29c27377cad4e0a306c97f9bd7772" +checksum = "8701b58ea97060d5e5b155d383a69952a60943f0e6dfe30b04c287beb0b27455" dependencies = [ "fixedbitset", - "indexmap 2.13.0", + "hashbrown 0.15.5", + "indexmap", ] [[package]] name = "pgvector" -version = "0.4.1" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc58e2d255979a31caa7cabfa7aac654af0354220719ab7a68520ae7a91e8c0b" +checksum = "3673cba5b9a124916096a423b806a9f29620972c6c97b08db5f2053e9428b481" dependencies = [ "serde", ] [[package]] name = "pin-project" -version = "1.1.11" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1749c7ed4bcaf4c3d0a3efc28538844fb29bcdd7d2b67b2be7e20ba861ff517" +checksum = "2466b2336ed02bcdca6b294417127b90ec92038d1d5c4fbeac971a922e0e0924" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.11" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b20ed30f105399776b9c883e68e536ef602a16ae6f596d2c473591d6ad64c6" +checksum = "c96395f0a926bc13b1c17622aaddda1ecb55d49c8f1bf9777e4d877800a43f8b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -3314,9 +3186,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.32" +version = "0.3.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c" +checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e" [[package]] name = "plain" @@ -3330,7 +3202,7 @@ version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" dependencies = [ - "bitflags 2.11.0", + "bitflags", "crc32fast", "fdeflate", "flate2", @@ -3358,7 +3230,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9d1fe60d06143b2430aa532c94cfe9e29783047f06c0d7fd359a9a51b729fa25" dependencies = [ "cfg-if", - "cpufeatures", + "cpufeatures 0.2.17", "opaque-debug", "universal-hash", ] @@ -3371,9 +3243,9 @@ checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49" [[package]] name = "potential_utf" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b73949432f5e2a09657003c25bca5e19a0e9c84f8058ca374f49e0ebe605af77" +checksum = "0103b1cef7ec0cf76490e969665504990193874ea05c85ff9bab8b911d0a0564" dependencies = [ "zerovec", ] @@ -3400,7 +3272,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "479ca8adacdd7ce8f1fb39ce9ecccbfe93a3f1344b3d0d97f20bc0196208f62b" dependencies = [ "proc-macro2", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -3431,7 +3303,7 @@ dependencies = [ "proc-macro-error-attr2", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -3451,58 +3323,57 @@ checksum = "af066a9c399a26e020ada66a034357a868728e72cd426f3adcd35f80d88d88c8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", "version_check", "yansi", ] [[package]] name = "procfs" -version = "0.16.0" +version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "731e0d9356b0c25f16f33b5be79b1c57b562f141ebfcdb0ad8ac2c13a24293b4" +checksum = "cc5b72d8145275d844d4b5f6d4e1eef00c8cd889edb6035c21675d1bb1f45c9f" dependencies = [ - "bitflags 2.11.0", + "bitflags", "hex", - "lazy_static", "procfs-core", "rustix 0.38.44", ] [[package]] name = "procfs-core" -version = "0.16.0" +version = "0.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3554923a69f4ce04c4a754260c338f505ce22642d3830e049a399fc2059a29" +checksum = "239df02d8349b06fc07398a3a1697b06418223b1c7725085e801e7c0fc6a12ec" dependencies = [ - "bitflags 2.11.0", + "bitflags", "hex", ] [[package]] name = "profiling" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eb8486b569e12e2c32ad3e204dbaba5e4b5b216e9367044f25f1dba42341773" +checksum = "3d595e54a326bc53c1c197b32d295e14b169e3cfeaa8dc82b529f947fba6bcf5" dependencies = [ "profiling-procmacros", ] [[package]] name = "profiling-procmacros" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52717f9a02b6965224f95ca2a81e2e0c5c43baacd28ca057577988930b6c3d5b" +checksum = "4488a4a36b9a4ba6b9334a32a39971f77c1436ec82c38707bce707699cc3bbcb" dependencies = [ "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "prometheus" -version = "0.13.4" +version = "0.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d33c28a30771f7f96db69893f78b857f7450d7e0237e9c8fc6427a81bae7ed1" +checksum = "3ca5326d8d0b950a9acd87e6a3f94745394f62e4dae1b1ee22b2bc0c394af43a" dependencies = [ "cfg-if", "fnv", @@ -3512,89 +3383,81 @@ dependencies = [ "parking_lot", "procfs", "protobuf", - "thiserror 1.0.69", -] - -[[package]] -name = "prost" -version = "0.13.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2796faa41db3ec313a31f7624d9286acf277b52de526150b7e69f3debf891ee5" -dependencies = [ - "bytes", - "prost-derive 0.13.5", + "thiserror 2.0.18", ] [[package]] name = "prost" -version = "0.14.3" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2ea70524a2f82d518bce41317d0fae74151505651af45faf1ffbd6fd33f0568" +checksum = "528ac67416ff8646872a3c02cad9cc4ee5dc9f9540c9b10771855c95cb2e5ae1" dependencies = [ "bytes", - "prost-derive 0.14.3", + "prost-derive", ] [[package]] name = "prost-build" -version = "0.13.5" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be769465445e8c1474e9c5dac2018218498557af32d9ed057325ec9a41ae81bf" +checksum = "03da047801ff44bb6a4d407d4860c05fd70bb81714e6b2f3812603d5b145b042" dependencies = [ "heck 0.5.0", "itertools", "log", "multimap", - "once_cell", "petgraph", "prettyplease", - "prost 0.13.5", + "prost", "prost-types", + "pulldown-cmark", + "pulldown-cmark-to-cmark", "regex", - "syn 2.0.117", + "syn 2.0.118", "tempfile", ] [[package]] name = "prost-derive" -version = "0.13.5" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a56d757972c98b346a9b766e3f02746cde6dd1cd1d1d563472929fdd74bec4d" +checksum = "b570b25f7617e43d59005d0990ccb79e950a423952cea19671b7a876da390adf" dependencies = [ "anyhow", "itertools", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] -name = "prost-derive" -version = "0.14.3" +name = "prost-types" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27c6023962132f4b30eb4c172c91ce92d933da334c59c23cddee82358ddafb0b" +checksum = "f94967dc7688f3054c7fac87473ffae4cc4c3904800e2d9f5b857246d8963b0a" dependencies = [ - "anyhow", - "itertools", - "proc-macro2", - "quote", - "syn 2.0.117", + "prost", ] [[package]] -name = "prost-types" -version = "0.13.5" +name = "protobuf" +version = "3.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52c2c1bf36ddb1a1c396b3601a3cec27c2462e45f07c386894ec3ccf5332bd16" +checksum = "d65a1d4ddae7d8b5de68153b48f6aa3bba8cb002b243dbdbc55a5afbc98f99f4" dependencies = [ - "prost 0.13.5", + "once_cell", + "protobuf-support", + "thiserror 1.0.69", ] [[package]] -name = "protobuf" -version = "2.28.0" +name = "protobuf-support" +version = "3.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "106dd99e98437432fed6519dedecfade6a06a73bb7b2a1e019fdd2bee5778d94" +checksum = "3e36c2f31e0a47f9280fb347ef5e461ffcd2c52dd520d8e216b52f93b0b0d7d6" +dependencies = [ + "thiserror 1.0.69", +] [[package]] name = "ptr_meta" @@ -3617,12 +3480,32 @@ dependencies = [ ] [[package]] -name = "pxfm" -version = "0.1.28" +name = "pulldown-cmark" +version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5a041e753da8b807c9255f28de81879c78c876392ff2469cde94799b2896b9d" - -[[package]] +checksum = "e9f068eba8e7071c5f9511831b44f32c740d5adf574e990f946ddb53db2f314e" +dependencies = [ + "bitflags", + "memchr", + "unicase", +] + +[[package]] +name = "pulldown-cmark-to-cmark" +version = "22.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50793def1b900256624a709439404384204a5dc3a6ec580281bfaac35e882e90" +dependencies = [ + "pulldown-cmark", +] + +[[package]] +name = "pxfm" +version = "0.1.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e0c5ccf5294c6ccd63a74f1565028353830a9c2f5eb0c682c355c471726a6e3f" + +[[package]] name = "qoi" version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -3652,7 +3535,7 @@ version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "99530e45ded4640c0eab5420fc60f9a0ec1be51a22e49cc8578b9a0d8be70712" dependencies = [ - "base64 0.22.1", + "base64", "image", "qrcodegen", ] @@ -3678,61 +3561,6 @@ version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" -[[package]] -name = "quinn" -version = "0.11.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e20a958963c291dc322d98411f541009df2ced7b5a4f2bd52337638cfccf20" -dependencies = [ - "bytes", - "cfg_aliases", - "pin-project-lite", - "quinn-proto", - "quinn-udp", - "rustc-hash", - "rustls 0.23.37", - "socket2 0.6.3", - "thiserror 2.0.18", - "tokio", - "tracing", - "web-time", -] - -[[package]] -name = "quinn-proto" -version = "0.11.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "434b42fec591c96ef50e21e886936e66d3cc3f737104fdb9b737c40ffb94c098" -dependencies = [ - "bytes", - "getrandom 0.3.4", - "lru-slab", - "rand 0.9.2", - "ring", - "rustc-hash", - "rustls 0.23.37", - "rustls-pki-types", - "slab", - "thiserror 2.0.18", - "tinyvec", - "tracing", - "web-time", -] - -[[package]] -name = "quinn-udp" -version = "0.5.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "addec6a0dcad8a8d96a771f815f0eaf55f9d1805756410b39f5fa81332574cbd" -dependencies = [ - "cfg_aliases", - "libc", - "once_cell", - "socket2 0.6.3", - "tracing", - "windows-sys 0.60.2", -] - [[package]] name = "quote" version = "1.0.45" @@ -3762,9 +3590,9 @@ checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" [[package]] name = "rand" -version = "0.8.5" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +checksum = "5ca0ecfa931c29007047d1bc58e623ab12e5590e8c7cc53200d5202b69266d8a" dependencies = [ "libc", "rand_chacha 0.3.1", @@ -3773,14 +3601,25 @@ dependencies = [ [[package]] name = "rand" -version = "0.9.2" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6db2770f06117d490610c7488547d543617b21bfa07796d7a12f6f1bd53850d1" +checksum = "44c5af06bb1b7d3216d91932aed5265164bf384dc89cd6ba05cf59a35f5f76ea" dependencies = [ "rand_chacha 0.9.0", "rand_core 0.9.5", ] +[[package]] +name = "rand" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2e8e8bcc7961af1fdac401278c6a831614941f6164ee3bf4ce61b7edb162207" +dependencies = [ + "chacha20", + "getrandom 0.4.3", + "rand_core 0.10.1", +] + [[package]] name = "rand_chacha" version = "0.3.1" @@ -3819,6 +3658,12 @@ dependencies = [ "getrandom 0.3.4", ] +[[package]] +name = "rand_core" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69" + [[package]] name = "rav1e" version = "0.8.1" @@ -3846,7 +3691,7 @@ dependencies = [ "num-traits", "paste", "profiling", - "rand 0.9.2", + "rand 0.9.4", "rand_chacha 0.9.0", "simd_helpers", "thiserror 2.0.18", @@ -3875,14 +3720,14 @@ version = "11.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "498cd0dc59d73224351ee52a95fee0f1a617a2eae0e7d9d720cc622c73a54186" dependencies = [ - "bitflags 2.11.0", + "bitflags", ] [[package]] name = "rayon" -version = "1.11.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "368f01d005bf8fd9b1206fb6fa653e6c4a81ceb1466406b81792d87c5677a58f" +checksum = "fb39b166781f92d482534ef4b4b1b2568f42613b53e5b6c160e24cfbfa30926d" dependencies = [ "either", "rayon-core", @@ -3900,15 +3745,15 @@ dependencies = [ [[package]] name = "rcgen" -version = "0.14.7" +version = "0.14.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10b99e0098aa4082912d4c649628623db6aba77335e4f4569ff5083a6448b32e" +checksum = "57f6d249aad744e274e682777a50283a225a32705394ee6d5fcc01efa25e4055" dependencies = [ "pem", "ring", "rustls-pki-types", "time", - "x509-parser 0.18.1", + "x509-parser", "yasna", ] @@ -3918,43 +3763,23 @@ version = "0.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" dependencies = [ - "bitflags 2.11.0", + "bitflags", ] [[package]] name = "redox_syscall" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce70a74e890531977d37e532c34d45e9055d2409ed08ddba14529471ed0be16" -dependencies = [ - "bitflags 2.11.0", -] - -[[package]] -name = "ref-cast" -version = "1.0.25" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f354300ae66f76f1c85c5f84693f0ce81d747e2c3f21a45fef496d89c960bf7d" +checksum = "5b44b894f2a6e36457d665d1e08c3866add6ed5e70050c1b4ba8a8ddedb02ce7" dependencies = [ - "ref-cast-impl", -] - -[[package]] -name = "ref-cast-impl" -version = "1.0.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7186006dcb21920990093f30e3dea63b7d6e977bf1256be20c3563a5db070da" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.117", + "bitflags", ] [[package]] name = "regex" -version = "1.12.3" +version = "1.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e10754a14b9137dd7b1e3e5b0493cc9171fdd105e0ab477f51b72e7f3ac0e276" +checksum = "f1292b7759ae1cb9ec195452d1390a074f0cd8541ab7a5a8c31cd6db45d4a6ba" dependencies = [ "aho-corasick", "memchr", @@ -3975,16 +3800,16 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.8.10" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc897dd8d9e8bd1ed8cdad82b5966c3e0ecae09fb1907d58efaa013543185d0a" +checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4" [[package]] name = "registry" version = "0.2.2" dependencies = [ "anyhow", - "axum 0.7.9", + "axum", "chrono", "dotenvy", "entity", @@ -3996,18 +3821,20 @@ dependencies = [ "opentelemetry_sdk", "prometheus", "rcgen", - "reqwest 0.11.27", + "reqwest", + "ring", + "rustls", "sea-orm", "serde", "serde_json", - "sha2", + "sha2 0.11.0", "shared", "tokio", "tracing", "tracing-opentelemetry", "tracing-subscriber", "uuid", - "x509-parser 0.16.0", + "x509-parser", ] [[package]] @@ -4021,83 +3848,39 @@ dependencies = [ [[package]] name = "reqwest" -version = "0.11.27" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd67538700a17451e7cba03ac727fb961abb7607553461627b97de0b89cf4a62" +checksum = "04e9018c9d814e5f30cc16a0f03271aeab3571e609612d9fe78c1aa8d11c2f62" dependencies = [ - "base64 0.21.7", + "base64", "bytes", - "encoding_rs", "futures-core", - "futures-util", - "h2 0.3.27", - "http 0.2.12", - "http-body 0.4.6", - "hyper 0.14.32", - "hyper-rustls 0.24.2", - "ipnet", - "js-sys", - "log", - "mime", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls 0.21.12", - "rustls-pemfile 1.0.4", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper 0.1.2", - "system-configuration", - "tokio", - "tokio-rustls 0.24.1", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "webpki-roots 0.25.4", - "winreg", -] - -[[package]] -name = "reqwest" -version = "0.12.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eddd3ca559203180a307f12d114c268abf583f59b03cb906fd0b3ff8646c1147" -dependencies = [ - "base64 0.22.1", - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "http 1.4.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", - "hyper 1.8.1", - "hyper-rustls 0.27.7", + "hyper", + "hyper-rustls", "hyper-util", "js-sys", "log", "percent-encoding", "pin-project-lite", - "quinn", - "rustls 0.23.37", + "rustls", "rustls-pki-types", + "rustls-platform-verifier", "serde", "serde_json", - "serde_urlencoded", - "sync_wrapper 1.0.2", + "sync_wrapper", "tokio", - "tokio-rustls 0.26.4", - "tower 0.5.3", - "tower-http 0.6.8", + "tokio-rustls", + "tower", + "tower-http 0.6.11", "tower-service", "url", "wasm-bindgen", "wasm-bindgen-futures", "web-sys", - "webpki-roots 1.0.6", + "webpki-roots 1.0.8", ] [[package]] @@ -4155,15 +3938,15 @@ version = "0.9.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b8573f03f5883dcaebdfcf4725caa1ecb9c15b2ef50c43a07b816e06799bb12d" dependencies = [ - "const-oid", - "digest", + "const-oid 0.9.6", + "digest 0.10.7", "num-bigint-dig", "num-integer", "num-traits", "pkcs1", "pkcs8", "rand_core 0.6.4", - "sha2", + "sha2 0.10.9", "signature", "spki", "subtle", @@ -4190,7 +3973,7 @@ dependencies = [ "proc-macro2", "quote", "rust-embed-utils", - "syn 2.0.117", + "syn 2.0.118", "walkdir", ] @@ -4200,32 +3983,27 @@ version = "8.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5bcdef0be6fe7f6fa333b1073c949729274b05f123a0ad7efcb8efd878e5c3b1" dependencies = [ - "sha2", + "sha2 0.10.9", "walkdir", ] [[package]] name = "rust_decimal" -version = "1.40.0" +version = "1.42.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61f703d19852dbf87cbc513643fa81428361eb6940f1ac14fd58155d295a3eb0" +checksum = "be2a24f50780bc85f09cc6ac299bdf1424302742d77221106859c9d8b102126a" dependencies = [ "arrayvec", "borsh", "bytes", "num-traits", - "rand 0.8.5", + "rand 0.8.6", "rkyv", "serde", "serde_json", + "wasm-bindgen", ] -[[package]] -name = "rustc-hash" -version = "2.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d" - [[package]] name = "rustc_version" version = "0.4.1" @@ -4250,7 +4028,7 @@ version = "0.38.44" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" dependencies = [ - "bitflags 2.11.0", + "bitflags", "errno", "libc", "linux-raw-sys 0.4.15", @@ -4263,7 +4041,7 @@ version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6fe4565b9518b83ef4f91bb47ce29620ca828bd32cb7e408f0062e9930ba190" dependencies = [ - "bitflags 2.11.0", + "bitflags", "errno", "libc", "linux-raw-sys 0.12.1", @@ -4272,37 +4050,24 @@ dependencies = [ [[package]] name = "rustls" -version = "0.21.12" +version = "0.23.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f56a14d1f48b391359b22f731fd4bd7e43c97f3c50eee276f3aa09c94784d3e" +checksum = "ef86cd5876211988985292b91c96a8f2d298df24e75989a43a3c73f2d4d8168b" dependencies = [ - "log", - "ring", - "rustls-webpki 0.101.7", - "sct", -] - -[[package]] -name = "rustls" -version = "0.23.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "758025cb5fccfd3bc2fd74708fd4682be41d99e5dff73c377c0646c6012c73a4" -dependencies = [ - "aws-lc-rs", "log", "once_cell", "ring", "rustls-pki-types", - "rustls-webpki 0.103.9", + "rustls-webpki", "subtle", "zeroize", ] [[package]] name = "rustls-native-certs" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "612460d5f7bea540c490b2b6395d8e34a953e52b491accd6c86c8164c5932a63" +checksum = "dab5152771c58876a2146916e53e35057e1a4dfa2b9df0f0305b07f611fdea4d" dependencies = [ "openssl-probe", "rustls-pki-types", @@ -4310,15 +4075,6 @@ dependencies = [ "security-framework", ] -[[package]] -name = "rustls-pemfile" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" -dependencies = [ - "base64 0.21.7", -] - [[package]] name = "rustls-pemfile" version = "2.2.0" @@ -4330,31 +4086,46 @@ dependencies = [ [[package]] name = "rustls-pki-types" -version = "1.14.0" +version = "1.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be040f8b0a225e40375822a563fa9524378b9d63112f53e19ffff34df5d33fdd" +checksum = "30a7197ae7eb376e574fe940d068c30fe0462554a3ddbe4eca7838e049c937a9" dependencies = [ - "web-time", "zeroize", ] [[package]] -name = "rustls-webpki" -version = "0.101.7" +name = "rustls-platform-verifier" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b6275d1ee7a1cd780b64aca7726599a1dbc893b1e64144529e55c3c2f745765" +checksum = "1d99feebc72bae7ab76ba994bb5e121b8d83d910ca40b36e0921f53becc41784" dependencies = [ - "ring", - "untrusted", + "core-foundation", + "core-foundation-sys", + "jni", + "log", + "once_cell", + "rustls", + "rustls-native-certs", + "rustls-platform-verifier-android", + "rustls-webpki", + "security-framework", + "security-framework-sys", + "webpki-root-certs", + "windows-sys 0.61.2", ] +[[package]] +name = "rustls-platform-verifier-android" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f87165f0995f63a9fbeea62b64d10b4d9d8e78ec6d7d51fb2125fda7bb36788f" + [[package]] name = "rustls-webpki" -version = "0.103.9" +version = "0.103.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7df23109aa6c1567d1c575b9952556388da57401e4ace1d15f79eedad0d8f53" +checksum = "61c429a8649f110dddef65e2a5ad240f747e85f7758a6bccc7e5777bd33f756e" dependencies = [ - "aws-lc-rs", "ring", "rustls-pki-types", "untrusted", @@ -4395,7 +4166,7 @@ name = "scheduler" version = "0.2.2" dependencies = [ "anyhow", - "axum 0.7.9", + "axum", "chrono", "dotenvy", "entity", @@ -4416,52 +4187,18 @@ dependencies = [ "uuid", ] -[[package]] -name = "schemars" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4cd191f9397d57d581cddd31014772520aa448f65ef991055d7f61582c65165f" -dependencies = [ - "dyn-clone", - "ref-cast", - "serde", - "serde_json", -] - -[[package]] -name = "schemars" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2b42f36aa1cd011945615b92222f6bf73c599a102a300334cd7f8dbeec726cc" -dependencies = [ - "dyn-clone", - "ref-cast", - "serde", - "serde_json", -] - [[package]] name = "scopeguard" version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" -[[package]] -name = "sct" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da046153aa2352493d6cb7da4b6e5c0c057d8a1d0a9aa8560baffdd945acd414" -dependencies = [ - "ring", - "untrusted", -] - [[package]] name = "sdn-controller" version = "0.2.2" dependencies = [ "anyhow", - "axum 0.7.9", + "axum", "chrono", "dotenvy", "entity", @@ -4471,7 +4208,9 @@ dependencies = [ "opentelemetry-semantic-conventions", "opentelemetry_sdk", "prometheus", - "reqwest 0.11.27", + "reqwest", + "ring", + "rustls", "sea-orm", "serde", "serde_json", @@ -4493,14 +4232,14 @@ dependencies = [ "proc-macro-error2", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "sea-orm" -version = "1.1.19" +version = "1.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d945f62558fac19e5988680d2fdf747b734c2dbc6ce2cb81ba33ed8dde5b103" +checksum = "2dc312fedd460a47ea563911761d254a84e7b51d8cc73ec92c929e78f33fa957" dependencies = [ "async-stream", "async-trait", @@ -4509,6 +4248,7 @@ dependencies = [ "derive_more", "futures-util", "log", + "mac_address", "ouroboros", "pgvector", "rust_decimal", @@ -4528,9 +4268,9 @@ dependencies = [ [[package]] name = "sea-orm-cli" -version = "1.1.19" +version = "1.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c94492e2ab6c045b4cc38013809ce255d14c3d352c9f0d11e6b920e2adc948ad" +checksum = "da80ebcdb44571e86f03a2bdcb5532136a87397f366f38bbce64673fc5e6a450" dependencies = [ "chrono", "clap", @@ -4547,23 +4287,23 @@ dependencies = [ [[package]] name = "sea-orm-macros" -version = "1.1.19" +version = "1.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84c2e64a50a9cc8339f10a27577e10062c7f995488e469f2c95762c5ee847832" +checksum = "9b9a3f90e336ec74803e8eb98c61bc98754c1adfba3b4f84d946237b752b1c88" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", "sea-bae", - "syn 2.0.117", + "syn 2.0.118", "unicode-ident", ] [[package]] name = "sea-orm-migration" -version = "1.1.19" +version = "1.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7315c0cadb7e60fb17ee2bb282aa27d01911fc2a7e5836ec1d4ac37d19250bb4" +checksum = "07c577f2959277e936c1d08109acd1e08fc36a95ef29ec028190ba82cad8f96e" dependencies = [ "async-trait", "clap", @@ -4618,7 +4358,7 @@ dependencies = [ "heck 0.4.1", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", "thiserror 2.0.18", ] @@ -4644,7 +4384,7 @@ dependencies = [ "heck 0.4.1", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -4659,8 +4399,8 @@ version = "3.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d" dependencies = [ - "bitflags 2.11.0", - "core-foundation 0.10.1", + "bitflags", + "core-foundation", "core-foundation-sys", "libc", "security-framework-sys", @@ -4678,9 +4418,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.27" +version = "1.0.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2" +checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd" [[package]] name = "serde" @@ -4709,14 +4449,14 @@ checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "serde_json" -version = "1.0.149" +version = "1.0.150" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86" +checksum = "e8014e44b4736ed0538adeecded0fce2a272f22dc9578a7eb6b2d9993c74cfb9" dependencies = [ "itoa", "memchr", @@ -4744,7 +4484,7 @@ checksum = "175ee3e80ae9982737ca543e96133087cbd9a485eecc3bc4de9c1a37b47ea59c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -4760,32 +4500,25 @@ dependencies = [ ] [[package]] -name = "serde_with" -version = "3.18.0" +name = "sha1" +version = "0.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd5414fad8e6907dbdd5bc441a50ae8d6e26151a03b1de04d89a5576de61d01f" +checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" dependencies = [ - "base64 0.22.1", - "chrono", - "hex", - "indexmap 1.9.3", - "indexmap 2.13.0", - "schemars 0.9.0", - "schemars 1.2.1", - "serde_core", - "serde_json", - "time", + "cfg-if", + "cpufeatures 0.2.17", + "digest 0.10.7", ] [[package]] name = "sha1" -version = "0.10.6" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" +checksum = "aacc4cc499359472b4abe1bf11d0b12e688af9a805fa5e3016f9a386dc2d0214" dependencies = [ "cfg-if", - "cpufeatures", - "digest", + "cpufeatures 0.3.0", + "digest 0.11.3", ] [[package]] @@ -4795,8 +4528,19 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283" dependencies = [ "cfg-if", - "cpufeatures", - "digest", + "cpufeatures 0.2.17", + "digest 0.10.7", +] + +[[package]] +name = "sha2" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "446ba717509524cb3f22f17ecc096f10f4822d76ab5c0b9822c5f9c284e825f4" +dependencies = [ + "cfg-if", + "cpufeatures 0.3.0", + "digest 0.11.3", ] [[package]] @@ -4825,9 +4569,9 @@ dependencies = [ [[package]] name = "shlex" -version = "1.3.0" +version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" +checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba" [[package]] name = "signal-hook-registry" @@ -4845,15 +4589,15 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" dependencies = [ - "digest", + "digest 0.10.7", "rand_core 0.6.4", ] [[package]] name = "simd-adler32" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e320a6c5ad31d271ad523dcf3ad13e2767ad8b1cb8f047f75a8aeaf8da139da2" +checksum = "703d5c7ef118737c72f1af64ad2f6f8c5e1921f818cdcb97b8fe6fc69bf66214" [[package]] name = "simd_helpers" @@ -4890,28 +4634,18 @@ checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5" [[package]] name = "smallvec" -version = "1.15.1" +version = "1.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03" +checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90" dependencies = [ "serde", ] [[package]] name = "socket2" -version = "0.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e22376abed350d73dd1cd119b57ffccad95b4e585a7cda43e286245ce23c0678" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "socket2" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a766e1110788c36f4fa1c2b71b387a7815aa65f88ce0229841826633d93723e" +checksum = "52d1cfed4120b4d927bf7c0f86d2087a4a7d6027c906d9f9d525a80573b9be51" dependencies = [ "libc", "windows-sys 0.61.2", @@ -4964,7 +4698,7 @@ version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ee6798b1838b6a0f69c007c133b8df5866302197e404e8b6ee8ed3e3a5e68dc6" dependencies = [ - "base64 0.22.1", + "base64", "bigdecimal", "bytes", "chrono", @@ -4978,16 +4712,16 @@ dependencies = [ "futures-util", "hashbrown 0.15.5", "hashlink", - "indexmap 2.13.0", + "indexmap", "log", "memchr", "once_cell", "percent-encoding", "rust_decimal", - "rustls 0.23.37", + "rustls", "serde", "serde_json", - "sha2", + "sha2 0.10.9", "smallvec", "thiserror 2.0.18", "time", @@ -5009,7 +4743,7 @@ dependencies = [ "quote", "sqlx-core", "sqlx-macros-core", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -5027,12 +4761,12 @@ dependencies = [ "quote", "serde", "serde_json", - "sha2", + "sha2 0.10.9", "sqlx-core", "sqlx-mysql", "sqlx-postgres", "sqlx-sqlite", - "syn 2.0.117", + "syn 2.0.118", "tokio", "url", ] @@ -5044,14 +4778,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "aa003f0038df784eb8fecbbac13affe3da23b45194bd57dba231c8f48199c526" dependencies = [ "atoi", - "base64 0.22.1", + "base64", "bigdecimal", - "bitflags 2.11.0", + "bitflags", "byteorder", "bytes", "chrono", "crc", - "digest", + "digest 0.10.7", "dotenvy", "either", "futures-channel", @@ -5068,12 +4802,12 @@ dependencies = [ "memchr", "once_cell", "percent-encoding", - "rand 0.8.5", + "rand 0.8.6", "rsa", "rust_decimal", "serde", - "sha1", - "sha2", + "sha1 0.10.6", + "sha2 0.10.9", "smallvec", "sqlx-core", "stringprep", @@ -5091,9 +4825,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "db58fcd5a53cf07c184b154801ff91347e4c30d17a3562a635ff028ad5deda46" dependencies = [ "atoi", - "base64 0.22.1", + "base64", "bigdecimal", - "bitflags 2.11.0", + "bitflags", "byteorder", "chrono", "crc", @@ -5112,11 +4846,11 @@ dependencies = [ "memchr", "num-bigint", "once_cell", - "rand 0.8.5", + "rand 0.8.6", "rust_decimal", "serde", "serde_json", - "sha2", + "sha2 0.10.9", "smallvec", "sqlx-core", "stringprep", @@ -5208,21 +4942,15 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.117" +version = "2.0.118" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99" +checksum = "1b9ae57f904213ebb649ce6895b8a66c66f0203b9319718f69a5612a065b1422" dependencies = [ "proc-macro2", "quote", "unicode-ident", ] -[[package]] -name = "sync_wrapper" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" - [[package]] name = "sync_wrapper" version = "1.0.2" @@ -5240,7 +4968,7 @@ checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -5257,27 +4985,6 @@ dependencies = [ "windows", ] -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation 0.9.4", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - [[package]] name = "tap" version = "1.0.1" @@ -5291,7 +4998,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd" dependencies = [ "fastrand", - "getrandom 0.4.2", + "getrandom 0.4.3", "once_cell", "rustix 1.1.4", "windows-sys 0.61.2", @@ -5323,7 +5030,7 @@ checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -5334,7 +5041,7 @@ checksum = "ebc4ee7f67670e9b64d05fa4253e753e016c6c95ff35b89b7941d6b856dec1d5" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -5362,12 +5069,11 @@ dependencies = [ [[package]] name = "time" -version = "0.3.47" +version = "0.3.49" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "743bd48c283afc0388f9b8827b976905fb217ad9e647fae3a379a9283c4def2c" +checksum = "711a53c2d47bbd818258c498c8dbfe186a2526c631495cfe7e078567f86b8469" dependencies = [ "deranged", - "itoa", "num-conv", "powerfmt", "serde_core", @@ -5377,15 +5083,15 @@ dependencies = [ [[package]] name = "time-core" -version = "0.1.8" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7694e1cfe791f8d31026952abf09c69ca6f6fa4e1a1229e18988f06a04a12dca" +checksum = "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109" [[package]] name = "time-macros" -version = "0.2.27" +version = "0.2.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e70e4c5a0e0a8a4823ad65dfe1a6930e4f4d756dcd9dd7939022b5e8c501215" +checksum = "71c652a3727a9cbb9a02f707f530b618ce00d0ccd762009c8c23bd191df3c17d" dependencies = [ "num-conv", "time-core", @@ -5393,9 +5099,9 @@ dependencies = [ [[package]] name = "tinystr" -version = "0.8.2" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42d3e9c45c09de15d06dd8acf5f4e0e399e85927b7f00711024eb7ae10fa4869" +checksum = "c8323304221c2a851516f22236c5722a72eaa19749016521d6dff0824447d96d" dependencies = [ "displaydoc", "zerovec", @@ -5418,9 +5124,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.50.0" +version = "1.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27ad5e34374e03cfffefc301becb44e9dc3c17584f414349ebe29ed26661822d" +checksum = "8fc7f01b389ac15039e4dc9531aa973a135d7a4135281b12d7c1bc79fd57fffe" dependencies = [ "bytes", "libc", @@ -5428,30 +5134,20 @@ dependencies = [ "parking_lot", "pin-project-lite", "signal-hook-registry", - "socket2 0.6.3", + "socket2", "tokio-macros", "windows-sys 0.61.2", ] [[package]] name = "tokio-macros" -version = "2.6.1" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c55a2eff8b69ce66c84f85e1da1c233edc36ceb85a2058d11b0d6a3c7e7569c" +checksum = "385a6cb71ab9ab790c5fe8d67f1645e6c450a7ce006a33de03daa956cf70a496" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", -] - -[[package]] -name = "tokio-rustls" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" -dependencies = [ - "rustls 0.21.12", - "tokio", + "syn 2.0.118", ] [[package]] @@ -5460,7 +5156,7 @@ version = "0.26.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1729aa945f29d91ba541258c8df89027d5792d85a8841fb65e8bf0f4ede4ef61" dependencies = [ - "rustls 0.23.37", + "rustls", "tokio", ] @@ -5490,20 +5186,20 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "1.0.0+spec-1.1.0" +version = "1.1.1+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32c2555c699578a4f59f0cc68e5116c8d7cabbd45e1409b989d4be085b53f13e" +checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7" dependencies = [ "serde_core", ] [[package]] name = "toml_edit" -version = "0.25.4+spec-1.1.0" +version = "0.25.12+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7193cbd0ce53dc966037f54351dbbcf0d5a642c7f0038c382ef9e677ce8c13f2" +checksum = "d2153edc6955a6c354fad8f5efd38b6a8769bdccf9fe50f8e1329f81b0baa5d7" dependencies = [ - "indexmap 2.13.0", + "indexmap", "toml_datetime", "toml_parser", "winnow", @@ -5511,95 +5207,92 @@ dependencies = [ [[package]] name = "toml_parser" -version = "1.0.9+spec-1.1.0" +version = "1.1.2+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "702d4415e08923e7e1ef96cd5727c0dfed80b4d2fa25db9647fe5eb6f7c5a4c4" +checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" dependencies = [ "winnow", ] [[package]] name = "tonic" -version = "0.12.3" +version = "0.14.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "877c5b330756d856ffcc4553ab34a5684481ade925ecc54bcd1bf02b1d0d4d52" +checksum = "ac2a5518c70fa84342385732db33fb3f44bc4cc748936eb5833d2df34d6445ef" dependencies = [ - "async-stream", "async-trait", - "axum 0.7.9", - "base64 0.22.1", + "axum", + "base64", "bytes", - "h2 0.4.13", - "http 1.4.0", - "http-body 1.0.1", + "h2", + "http", + "http-body", "http-body-util", - "hyper 1.8.1", + "hyper", "hyper-timeout", "hyper-util", "percent-encoding", "pin-project", - "prost 0.13.5", "rustls-native-certs", - "rustls-pemfile 2.2.0", - "socket2 0.5.10", + "socket2", + "sync_wrapper", "tokio", - "tokio-rustls 0.26.4", + "tokio-rustls", "tokio-stream", - "tower 0.4.13", + "tower", "tower-layer", "tower-service", "tracing", ] [[package]] -name = "tonic" -version = "0.14.5" +name = "tonic-build" +version = "0.14.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fec7c61a0695dc1887c1b53952990f3ad2e3a31453e1f49f10e75424943a93ec" +checksum = "c68f61875ac5293cf72e6c8cf0158086428c82c37229e98c840878f1706b0322" +dependencies = [ + "prettyplease", + "proc-macro2", + "quote", + "syn 2.0.118", +] + +[[package]] +name = "tonic-prost" +version = "0.14.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50849f68853be452acf590cde0b146665b8d507b3b8af17261df47e02c209ea0" dependencies = [ - "async-trait", - "base64 0.22.1", "bytes", - "http 1.4.0", - "http-body 1.0.1", - "http-body-util", - "hyper 1.8.1", - "hyper-timeout", - "hyper-util", - "percent-encoding", - "pin-project", - "sync_wrapper 1.0.2", - "tokio", - "tokio-stream", - "tower 0.5.3", - "tower-layer", - "tower-service", - "tracing", + "prost", + "tonic", ] [[package]] -name = "tonic-build" -version = "0.12.3" +name = "tonic-prost-build" +version = "0.14.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9557ce109ea773b399c9b9e5dca39294110b74f1f342cb347a80d1fce8c26a11" +checksum = "654e5643eff75d7f8c99197ce1440ed19a3474eada74c12bbac488b2cafdae27" dependencies = [ "prettyplease", "proc-macro2", "prost-build", "prost-types", "quote", - "syn 2.0.117", + "syn 2.0.118", + "tempfile", + "tonic-build", ] [[package]] -name = "tonic-prost" -version = "0.14.5" +name = "tonic-types" +version = "0.14.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a55376a0bbaa4975a3f10d009ad763d8f4108f067c7c2e74f3001fb49778d309" +checksum = "73ab1b02061f83d519bba3caa167f88f261ef05720ab8ebc954ade70de3348e8" dependencies = [ - "bytes", - "prost 0.14.3", - "tonic 0.14.5", + "prost", + "prost-types", + "tonic", ] [[package]] @@ -5612,25 +5305,24 @@ dependencies = [ "constant_time_eq", "hmac", "qrcodegen-image", - "sha1", - "sha2", + "sha1 0.10.6", + "sha2 0.10.9", "url", "urlencoding", ] [[package]] name = "tower" -version = "0.4.13" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4" dependencies = [ "futures-core", "futures-util", - "indexmap 1.9.3", - "pin-project", + "indexmap", "pin-project-lite", - "rand 0.8.5", "slab", + "sync_wrapper", "tokio", "tokio-util", "tower-layer", @@ -5639,35 +5331,35 @@ dependencies = [ ] [[package]] -name = "tower" -version = "0.5.3" +name = "tower-http" +version = "0.6.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4" +checksum = "4cfcf7e2740e6fc6d4d688b4ef00650406bb94adf4731e43c096c3a19fe40840" dependencies = [ - "futures-core", + "bitflags", + "bytes", "futures-util", - "indexmap 2.13.0", + "http", + "http-body", "pin-project-lite", - "slab", - "sync_wrapper 1.0.2", - "tokio", - "tokio-util", + "tower", "tower-layer", "tower-service", - "tracing", + "url", ] [[package]] name = "tower-http" -version = "0.5.2" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e9cd434a998747dd2c4276bc96ee2e0c7a2eadf3cae88e52be55a05fa9053f5" +checksum = "b11f75e912b0c2be01b63d8cf8057b8c3f97cf34abb3d431a3a4c8675498e233" dependencies = [ - "bitflags 2.11.0", + "bitflags", "bytes", + "futures-core", "futures-util", - "http 1.4.0", - "http-body 1.0.1", + "http", + "http-body", "http-body-util", "http-range-header", "httpdate", @@ -5682,24 +5374,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "tower-http" -version = "0.6.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4e6559d53cc268e5031cd8429d05415bc4cb4aefc4aa5d6cc35fbf5b924a1f8" -dependencies = [ - "bitflags 2.11.0", - "bytes", - "futures-util", - "http 1.4.0", - "http-body 1.0.1", - "iri-string", - "pin-project-lite", - "tower 0.5.3", - "tower-layer", - "tower-service", -] - [[package]] name = "tower-layer" version = "0.3.3" @@ -5714,17 +5388,18 @@ checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" [[package]] name = "tower_governor" -version = "0.4.3" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aea939ea6cfa7c4880f3e7422616624f97a567c16df67b53b11f0d03917a8e46" +checksum = "44de9b94d849d3c46e06a883d72d408c2de6403367b39df2b1c9d9e7b6736fe6" dependencies = [ - "axum 0.7.9", + "axum", "forwarded-header-value", "governor", - "http 1.4.0", + "http", "pin-project", - "thiserror 1.0.69", - "tower 0.5.3", + "thiserror 2.0.18", + "tonic", + "tower", "tracing", ] @@ -5748,7 +5423,7 @@ checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -5774,9 +5449,9 @@ dependencies = [ [[package]] name = "tracing-opentelemetry" -version = "0.32.1" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ac28f2d093c6c477eaa76b23525478f38de514fa9aeb1285738d4b97a9552fc" +checksum = "adbc64cba7137545b8044cb1fe9814f7aacf3c6b5f9b45be8bb5db538befdb26" dependencies = [ "js-sys", "opentelemetry", @@ -5814,9 +5489,9 @@ checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" [[package]] name = "typenum" -version = "1.19.0" +version = "1.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "562d481066bde0658276a35467c4af00bdc6ee726305698a55b86e61d7ad82bb" +checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20" [[package]] name = "unicase" @@ -5863,7 +5538,7 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc1de2c688dc15305988b563c3854064043356019f97a4b46276fe734c4f07ea" dependencies = [ - "crypto-common", + "crypto-common 0.1.7", "subtle", ] @@ -5909,7 +5584,7 @@ version = "5.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8bde15df68e80b16c7d16b9616e80770ad158988daa56a27dccd1e55558b0160" dependencies = [ - "indexmap 2.13.0", + "indexmap", "serde", "serde_json", "utoipa-gen", @@ -5924,7 +5599,7 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.117", + "syn 2.0.118", "uuid", ] @@ -5934,8 +5609,8 @@ version = "9.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d047458f1b5b65237c2f6dc6db136945667f40a7668627b3490b9513a3d43a55" dependencies = [ - "axum 0.8.9", - "base64 0.22.1", + "axum", + "base64", "mime_guess", "regex", "rust-embed", @@ -5948,11 +5623,11 @@ dependencies = [ [[package]] name = "uuid" -version = "1.22.0" +version = "1.23.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a68d3c8f01c0cfa54a75291d83601161799e4a89a39e0929f4b0354d88757a37" +checksum = "144d6b123cef80b301b8f72a9e2ca4370ddec21950d0a103dd22c437006d2db7" dependencies = [ - "getrandom 0.4.2", + "getrandom 0.4.3", "js-sys", "serde_core", "wasm-bindgen", @@ -5999,7 +5674,7 @@ version = "0.2.2" dependencies = [ "anyhow", "async-trait", - "axum 0.7.9", + "axum", "chrono", "dotenvy", "entity", @@ -6009,7 +5684,9 @@ dependencies = [ "opentelemetry-semantic-conventions", "opentelemetry_sdk", "prometheus", - "reqwest 0.11.27", + "reqwest", + "ring", + "rustls", "sea-orm", "serde", "serde_json", @@ -6049,18 +5726,9 @@ checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" [[package]] name = "wasip2" -version = "1.0.2+wasi-0.2.9" +version = "1.0.4+wasi-0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9517f9239f02c069db75e65f174b3da828fe5f5b945c4dd26bd25d89c03ebcf5" -dependencies = [ - "wit-bindgen", -] - -[[package]] -name = "wasip3" -version = "0.4.0+wasi-0.3.0-rc-2026-01-06" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5428f8bf88ea5ddc08faddef2ac4a67e390b88186c703ce6dbd955e1c145aca5" +checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487" dependencies = [ "wit-bindgen", ] @@ -6073,36 +5741,33 @@ checksum = "b8dad83b4f25e74f184f64c43b150b91efe7647395b42289f38e50566d82855b" [[package]] name = "wasm-bindgen" -version = "0.2.114" +version = "0.2.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6532f9a5c1ece3798cb1c2cfdba640b9b3ba884f5db45973a6f442510a87d38e" +checksum = "8ddb3f79143bced6de84270411622a2699cee572fc0875aeaf1e7867cf9fca1a" dependencies = [ "cfg-if", "once_cell", "rustversion", + "serde", "wasm-bindgen-macro", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.64" +version = "0.4.75" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9c5522b3a28661442748e09d40924dfb9ca614b21c00d3fd135720e48b67db8" +checksum = "503b14d284f2c8dac03b819967e155ea753f573586193b2b2c95990cb5d69280" dependencies = [ - "cfg-if", - "futures-util", "js-sys", - "once_cell", "wasm-bindgen", - "web-sys", ] [[package]] name = "wasm-bindgen-macro" -version = "0.2.114" +version = "0.2.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18a2d50fcf105fb33bb15f00e7a77b772945a2ee45dcf454961fd843e74c18e6" +checksum = "4e21a184b13fb19e157296e2c46056aec9092264fab83e4ba59e68c61b323c3d" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -6110,65 +5775,31 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.114" +version = "0.2.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03ce4caeaac547cdf713d280eda22a730824dd11e6b8c3ca9e42247b25c631e3" +checksum = "fecefd9c35bd935a20fc3fc344b5f29138961e4f47fb03297d88f2587afb5ebd" dependencies = [ "bumpalo", "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.114" +version = "0.2.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75a326b8c223ee17883a4251907455a2431acc2791c98c26279376490c378c16" +checksum = "23939e44bb9a5d7576fa2b563dc2e136628f1224e88a8deed09e04858b77871f" dependencies = [ "unicode-ident", ] -[[package]] -name = "wasm-encoder" -version = "0.244.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "990065f2fe63003fe337b932cfb5e3b80e0b4d0f5ff650e6985b1048f62c8319" -dependencies = [ - "leb128fmt", - "wasmparser", -] - -[[package]] -name = "wasm-metadata" -version = "0.244.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb0e353e6a2fbdc176932bbaab493762eb1255a7900fe0fea1a2f96c296cc909" -dependencies = [ - "anyhow", - "indexmap 2.13.0", - "wasm-encoder", - "wasmparser", -] - -[[package]] -name = "wasmparser" -version = "0.244.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47b807c72e1bac69382b3a6fb3dbe8ea4c0ed87ff5629b8685ae6b9a611028fe" -dependencies = [ - "bitflags 2.11.0", - "hashbrown 0.15.5", - "indexmap 2.13.0", - "semver", -] - [[package]] name = "web-sys" -version = "0.3.91" +version = "0.3.102" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "854ba17bb104abfb26ba36da9729addc7ce7f06f5c0f90f3c391f8461cca21f9" +checksum = "a6430a72df5eb332242960fe84b3002a241163998241eb596d4f739b9757061d" dependencies = [ "js-sys", "wasm-bindgen", @@ -6185,10 +5816,13 @@ dependencies = [ ] [[package]] -name = "webpki-roots" -version = "0.25.4" +name = "webpki-root-certs" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f20c57d8d7db6d3b86154206ae5d8fba62dd39573114de97c2cb0578251f8e1" +checksum = "0d46a5a140e6f7afeccd8eae97eff335163939eac8b929834875168b29b3d267" +dependencies = [ + "rustls-pki-types", +] [[package]] name = "webpki-roots" @@ -6196,14 +5830,14 @@ version = "0.26.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "521bc38abb08001b01866da9f51eb7c5d647a19260e00054a8c7fd5f9e57f7a9" dependencies = [ - "webpki-roots 1.0.6", + "webpki-roots 1.0.8", ] [[package]] name = "webpki-roots" -version = "1.0.6" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22cfaf3c063993ff62e73cb4311efde4db1efb31ab78a3e5c457939ad5cc0bed" +checksum = "bf85cb06032201fa7c6f829d7db5a7e5aa45bcc0655327713065f6f0576731bf" dependencies = [ "rustls-pki-types", ] @@ -6298,7 +5932,7 @@ checksum = "9107ddc059d5b6fbfbffdfa7a7fe3e22a226def0b2608f72e9d552763d3e1ad7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -6309,7 +5943,7 @@ checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -6320,7 +5954,7 @@ checksum = "29bee4b38ea3cde66011baa44dba677c432a78593e202392d1e9070cf2a7fca7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -6331,7 +5965,7 @@ checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -6367,6 +6001,15 @@ dependencies = [ "windows-link", ] +[[package]] +name = "windows-sys" +version = "0.45.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" +dependencies = [ + "windows-targets 0.42.2", +] + [[package]] name = "windows-sys" version = "0.48.0" @@ -6396,20 +6039,26 @@ dependencies = [ [[package]] name = "windows-sys" -version = "0.60.2" +version = "0.61.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb" +checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" dependencies = [ - "windows-targets 0.53.5", + "windows-link", ] [[package]] -name = "windows-sys" -version = "0.61.2" +name = "windows-targets" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" +checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" dependencies = [ - "windows-link", + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", ] [[package]] @@ -6436,7 +6085,7 @@ dependencies = [ "windows_aarch64_gnullvm 0.52.6", "windows_aarch64_msvc 0.52.6", "windows_i686_gnu 0.52.6", - "windows_i686_gnullvm 0.52.6", + "windows_i686_gnullvm", "windows_i686_msvc 0.52.6", "windows_x86_64_gnu 0.52.6", "windows_x86_64_gnullvm 0.52.6", @@ -6444,21 +6093,10 @@ dependencies = [ ] [[package]] -name = "windows-targets" -version = "0.53.5" +name = "windows_aarch64_gnullvm" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3" -dependencies = [ - "windows-link", - "windows_aarch64_gnullvm 0.53.1", - "windows_aarch64_msvc 0.53.1", - "windows_i686_gnu 0.53.1", - "windows_i686_gnullvm 0.53.1", - "windows_i686_msvc 0.53.1", - "windows_x86_64_gnu 0.53.1", - "windows_x86_64_gnullvm 0.53.1", - "windows_x86_64_msvc 0.53.1", -] +checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" [[package]] name = "windows_aarch64_gnullvm" @@ -6473,10 +6111,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] -name = "windows_aarch64_gnullvm" -version = "0.53.1" +name = "windows_aarch64_msvc" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53" +checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" [[package]] name = "windows_aarch64_msvc" @@ -6491,10 +6129,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] -name = "windows_aarch64_msvc" -version = "0.53.1" +name = "windows_i686_gnu" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006" +checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" [[package]] name = "windows_i686_gnu" @@ -6508,12 +6146,6 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" -[[package]] -name = "windows_i686_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3" - [[package]] name = "windows_i686_gnullvm" version = "0.52.6" @@ -6521,10 +6153,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] -name = "windows_i686_gnullvm" -version = "0.53.1" +name = "windows_i686_msvc" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c" +checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" [[package]] name = "windows_i686_msvc" @@ -6539,10 +6171,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] -name = "windows_i686_msvc" -version = "0.53.1" +name = "windows_x86_64_gnu" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2" +checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" [[package]] name = "windows_x86_64_gnu" @@ -6557,10 +6189,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] -name = "windows_x86_64_gnu" -version = "0.53.1" +name = "windows_x86_64_gnullvm" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499" +checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" [[package]] name = "windows_x86_64_gnullvm" @@ -6575,10 +6207,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] -name = "windows_x86_64_gnullvm" -version = "0.53.1" +name = "windows_x86_64_msvc" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1" +checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" [[package]] name = "windows_x86_64_msvc" @@ -6592,124 +6224,26 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" -[[package]] -name = "windows_x86_64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650" - [[package]] name = "winnow" -version = "0.7.15" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945" +checksum = "0592e1c9d151f854e6fd382574c3a0855250e1d9b2f99d9281c6e6391af352f1" dependencies = [ "memchr", ] -[[package]] -name = "winreg" -version = "0.50.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - [[package]] name = "wit-bindgen" -version = "0.51.0" +version = "0.57.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7249219f66ced02969388cf2bb044a09756a083d0fab1e566056b04d9fbcaa5" -dependencies = [ - "wit-bindgen-rust-macro", -] - -[[package]] -name = "wit-bindgen-core" -version = "0.51.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea61de684c3ea68cb082b7a88508a8b27fcc8b797d738bfc99a82facf1d752dc" -dependencies = [ - "anyhow", - "heck 0.5.0", - "wit-parser", -] - -[[package]] -name = "wit-bindgen-rust" -version = "0.51.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7c566e0f4b284dd6561c786d9cb0142da491f46a9fbed79ea69cdad5db17f21" -dependencies = [ - "anyhow", - "heck 0.5.0", - "indexmap 2.13.0", - "prettyplease", - "syn 2.0.117", - "wasm-metadata", - "wit-bindgen-core", - "wit-component", -] - -[[package]] -name = "wit-bindgen-rust-macro" -version = "0.51.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c0f9bfd77e6a48eccf51359e3ae77140a7f50b1e2ebfe62422d8afdaffab17a" -dependencies = [ - "anyhow", - "prettyplease", - "proc-macro2", - "quote", - "syn 2.0.117", - "wit-bindgen-core", - "wit-bindgen-rust", -] - -[[package]] -name = "wit-component" -version = "0.244.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d66ea20e9553b30172b5e831994e35fbde2d165325bec84fc43dbf6f4eb9cb2" -dependencies = [ - "anyhow", - "bitflags 2.11.0", - "indexmap 2.13.0", - "log", - "serde", - "serde_derive", - "serde_json", - "wasm-encoder", - "wasm-metadata", - "wasmparser", - "wit-parser", -] - -[[package]] -name = "wit-parser" -version = "0.244.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc8ac4bc1dc3381b7f59c34f00b67e18f910c2c0f50015669dde7def656a736" -dependencies = [ - "anyhow", - "id-arena", - "indexmap 2.13.0", - "log", - "semver", - "serde", - "serde_derive", - "serde_json", - "unicode-xid", - "wasmparser", -] +checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" [[package]] name = "writeable" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9edde0db4769d2dc68579893f2306b26c6ecfbe0ef499b013d731b7b9247e0b9" +checksum = "1ffae5123b2d3fc086436f8834ae3ab053a283cfac8fe0a0b8eaae044768a4c4" [[package]] name = "wyz" @@ -6720,35 +6254,18 @@ dependencies = [ "tap", ] -[[package]] -name = "x509-parser" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcbc162f30700d6f3f82a24bf7cc62ffe7caea42c0b2cba8bf7f3ae50cf51f69" -dependencies = [ - "asn1-rs 0.6.2", - "data-encoding", - "der-parser 9.0.0", - "lazy_static", - "nom 7.1.3", - "oid-registry 0.7.1", - "rusticata-macros", - "thiserror 1.0.69", - "time", -] - [[package]] name = "x509-parser" version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d43b0f71ce057da06bc0851b23ee24f3f86190b07203dd8f567d0b706a185202" dependencies = [ - "asn1-rs 0.7.1", + "asn1-rs", "data-encoding", - "der-parser 10.0.0", + "der-parser", "lazy_static", "nom 7.1.3", - "oid-registry 0.8.1", + "oid-registry", "ring", "rusticata-macros", "thiserror 2.0.18", @@ -6769,18 +6286,19 @@ checksum = "cfe53a6657fd280eaa890a3bc59152892ffa3e30101319d168b781ed6529b049" [[package]] name = "yasna" -version = "0.5.2" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e17bb3549cc1321ae1296b9cdc2698e2b6cb1992adfa19a8c72e5b7a738f44cd" +checksum = "b5f6765e852b9b4dc8e2a76843e4d64d1cea8e79bcde0b6901aea8e7c7f08282" dependencies = [ + "bit-vec", "time", ] [[package]] name = "yoke" -version = "0.8.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72d6e5c6afb84d73944e5cedb052c4680d5657337201555f9f2a16b7406d4954" +checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5" dependencies = [ "stable_deref_trait", "yoke-derive", @@ -6789,82 +6307,82 @@ dependencies = [ [[package]] name = "yoke-derive" -version = "0.8.1" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b659052874eb698efe5b9e8cf382204678a0086ebf46982b79d6ca3182927e5d" +checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", "synstructure", ] [[package]] name = "zerocopy" -version = "0.8.42" +version = "0.8.52" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2578b716f8a7a858b7f02d5bd870c14bf4ddbbcf3a4c05414ba6503640505e3" +checksum = "ce1022995ff5ff5d841ad7d994facc23098cd40152f2c1d11cd607c6f530653f" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.8.42" +version = "0.8.52" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e6cc098ea4d3bd6246687de65af3f920c430e236bee1e3bf2e441463f08a02f" +checksum = "1ae7f38b72ec2a254e2b87ef277cf2cd4fb97cbebf944faa6f33354da0867930" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "zerofrom" -version = "0.1.6" +version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50cc42e0333e05660c3587f3bf9d0478688e15d870fab3346451ce7f8c9fbea5" +checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272" dependencies = [ "zerofrom-derive", ] [[package]] name = "zerofrom-derive" -version = "0.1.6" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502" +checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", "synstructure", ] [[package]] name = "zeroize" -version = "1.8.2" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b97154e67e32c85465826e8bcc1c59429aaaf107c1e4a9e53c8d8ccd5eff88d0" +checksum = "e13c156562582aa81c60cb29407084cdb54c4164760106ab78e6c5b0858cf64e" dependencies = [ "zeroize_derive", ] [[package]] name = "zeroize_derive" -version = "1.4.3" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85a5b4158499876c763cb03bc4e49185d3cccbabb15b33c627f7884f43db852e" +checksum = "3c50655cbb0fe3fc43170059e702f1ce5e19b84cec58dc87b037a09935c2f328" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] name = "zerotrie" -version = "0.2.3" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a59c17a5562d507e4b54960e8569ebee33bee890c70aa3fe7b97e85a9fd7851" +checksum = "0f9152d31db0792fa83f70fb2f83148effb5c1f5b8c7686c3459e361d9bc20bf" dependencies = [ "displaydoc", "yoke", @@ -6873,9 +6391,9 @@ dependencies = [ [[package]] name = "zerovec" -version = "0.11.5" +version = "0.11.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c28719294829477f525be0186d13efa9a3c602f7ec202ca9e353d310fb9a002" +checksum = "90f911cbc359ab6af17377d242225f4d75119aec87ea711a880987b18cd7b239" dependencies = [ "yoke", "zerofrom", @@ -6884,13 +6402,13 @@ dependencies = [ [[package]] name = "zerovec-derive" -version = "0.11.2" +version = "0.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eadce39539ca5cb3985590102671f2567e659fca9666581ad3411d59207951f3" +checksum = "625dc425cab0dca6dc3c3319506e6593dcb08a9f387ea3b284dbd52a92c40555" dependencies = [ "proc-macro2", "quote", - "syn 2.0.117", + "syn 2.0.118", ] [[package]] @@ -6902,7 +6420,7 @@ dependencies = [ "arbitrary", "crc32fast", "flate2", - "indexmap 2.13.0", + "indexmap", "memchr", "zopfli", ] @@ -6948,9 +6466,9 @@ dependencies = [ [[package]] name = "zune-jpeg" -version = "0.5.13" +version = "0.5.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec5f41c76397b7da451efd19915684f727d7e1d516384ca6bd0ec43ec94de23c" +checksum = "27bc9d5b815bc103f142aa054f561d9187d191692ec7c2d1e2b4737f8dbd7296" dependencies = [ "zune-core", ] diff --git a/Cargo.toml b/Cargo.toml index ce660e3c..b3f8233a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -33,7 +33,7 @@ sea-orm-migration = { version = "1.1.0", features = ["runtime-tokio-rustls", "sq # Web framework axum = "0.8.0" -axum-server = { version = "0.7", features = ["tls-rustls"] } +axum-server = { version = "0.7", features = ["tls-rustls-no-provider"] } tower-http = { version = "0.7.0", features = ["cors", "trace", "fs"] } hyper = "1.5" hyper-util = { version = "0.1", features = ["client", "client-legacy", "http1", "http2", "tokio"] } @@ -69,7 +69,8 @@ etcd-client = { version = "0.19", default-features = false, features = ["tls-roo # PKI rcgen = { version = "0.14", features = ["pem", "x509-parser"] } -rustls = { version = "0.23", features = ["ring"] } +rustls = { version = "0.23", default-features = false, features = ["ring", "std", "tls12"] } +ring = "0.17" x509-parser = "0.18" # Metrics @@ -81,7 +82,7 @@ tower_governor = { version = "0.8", features = ["axum"] } # OpenTelemetry opentelemetry = { version = "0.32" } opentelemetry_sdk = { version = "0.32", features = ["rt-tokio"] } -opentelemetry-otlp = { version = "0.32", features = ["grpc-tonic", "trace"] } +opentelemetry-otlp = { version = "0.32", default-features = false, features = ["grpc-tonic", "trace", "internal-logs"] } opentelemetry-semantic-conventions = { version = "0.32" } tracing-opentelemetry = { version = "0.33" } @@ -94,10 +95,10 @@ sha2 = "0.11" cookie = { version = "0.18.1", features = ["percent-encode"] } qrcode = "0.14" image = "0.25" -sysinfo = "0.39" +sysinfo = "0.32" bollard = "0.21" futures-util = "0.3" -reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"] } +reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-no-provider", "webpki-roots"] } [profile.release] opt-level = 3 diff --git a/agent/Cargo.toml b/agent/Cargo.toml index aaa39c5c..fe7acd4c 100644 --- a/agent/Cargo.toml +++ b/agent/Cargo.toml @@ -10,7 +10,9 @@ path = "src/main.rs" [dependencies] tokio = { workspace = true, features = ["full"] } -reqwest = { version = "0.13", features = ["json", "rustls-tls"], default-features = false } +reqwest = { version = "0.13", features = ["json", "rustls-no-provider", "webpki-roots"], default-features = false } +ring = { workspace = true } +rustls = { workspace = true } serde = { workspace = true } serde_json = { workspace = true } tracing = { workspace = true } diff --git a/agent/src/client.rs b/agent/src/client.rs index bedce01c..d87cfce3 100644 --- a/agent/src/client.rs +++ b/agent/src/client.rs @@ -87,6 +87,7 @@ impl ApiClient { pub fn new(gateway_url: String) -> Result { let client = Client::builder() .timeout(std::time::Duration::from_secs(30)) + .danger_accept_invalid_certs(true) .build() .context("Failed to build HTTP client")?; @@ -171,15 +172,31 @@ impl ApiClient { self.gateway_url, agent_id ); - let (cpu_usage_percent, cpu_cores, memory_total_bytes, memory_used_bytes, - disk_total_bytes, disk_used_bytes, network_rx_bytes, network_tx_bytes, - uptime_seconds) = metrics.map(|m| ( - Some(m.cpu_usage_percent), Some(m.cpu_cores), - Some(m.memory_total_bytes), Some(m.memory_used_bytes), - Some(m.disk_total_bytes), Some(m.disk_used_bytes), - Some(m.network_rx_bytes), Some(m.network_tx_bytes), - Some(m.uptime_seconds), - )).unwrap_or_default(); + let ( + cpu_usage_percent, + cpu_cores, + memory_total_bytes, + memory_used_bytes, + disk_total_bytes, + disk_used_bytes, + network_rx_bytes, + network_tx_bytes, + uptime_seconds, + ) = metrics + .map(|m| { + ( + Some(m.cpu_usage_percent), + Some(m.cpu_cores), + Some(m.memory_total_bytes), + Some(m.memory_used_bytes), + Some(m.disk_total_bytes), + Some(m.disk_used_bytes), + Some(m.network_rx_bytes), + Some(m.network_tx_bytes), + Some(m.uptime_seconds), + ) + }) + .unwrap_or_default(); let mut req = self .client @@ -216,10 +233,7 @@ impl ApiClient { .context("Failed to parse heartbeat response") } - pub async fn fetch_assigned_workloads( - &self, - api_key: &str, - ) -> Result> { + pub async fn fetch_assigned_workloads(&self, api_key: &str) -> Result> { let url = format!("{}/api/agents/self/workloads", self.gateway_url); let resp = self @@ -232,7 +246,11 @@ impl ApiClient { if !resp.status().is_success() { let status = resp.status(); - anyhow::bail!("Failed to fetch workloads status={} {}", status, resp.text().await.unwrap_or_default()); + anyhow::bail!( + "Failed to fetch workloads status={} {}", + status, + resp.text().await.unwrap_or_default() + ); } let all: Vec = resp @@ -289,7 +307,11 @@ impl ApiClient { if !resp.status().is_success() { let status = resp.status(); - anyhow::bail!("Failed to fetch volumes status={} {}", status, resp.text().await.unwrap_or_default()); + anyhow::bail!( + "Failed to fetch volumes status={} {}", + status, + resp.text().await.unwrap_or_default() + ); } let all: Vec = resp diff --git a/agent/src/config.rs b/agent/src/config.rs index 82c6d1fb..8db8bc8c 100644 --- a/agent/src/config.rs +++ b/agent/src/config.rs @@ -24,8 +24,7 @@ pub fn is_registered() -> bool { } pub fn load_config() -> Result { - let data = std::fs::read_to_string(CONFIG_FILE) - .context("Failed to read daemon config")?; + let data = std::fs::read_to_string(CONFIG_FILE).context("Failed to read daemon config")?; serde_json::from_str(&data).context("Failed to parse daemon config") } @@ -53,12 +52,10 @@ pub fn save_credentials(api_key: &str) -> Result<()> { fn set_permissions_600(path: &str) -> Result<()> { use std::os::unix::fs::PermissionsExt; let perms = std::fs::Permissions::from_mode(0o600); - std::fs::set_permissions(path, perms) - .context("Failed to set credentials file permissions") + std::fs::set_permissions(path, perms).context("Failed to set credentials file permissions") } #[cfg(not(unix))] fn set_permissions_600(_path: &str) -> Result<()> { Ok(()) } - diff --git a/agent/src/docker.rs b/agent/src/docker.rs index 97e9977c..7ca8262d 100644 --- a/agent/src/docker.rs +++ b/agent/src/docker.rs @@ -1,7 +1,8 @@ use anyhow::{Context, Result}; -use bollard::container::{Config, CreateContainerOptions, StartContainerOptions}; -use bollard::image::CreateImageOptions; -use bollard::models::HostConfig; +use bollard::models::{ContainerCreateBody, HostConfig}; +use bollard::query_parameters::{ + CreateContainerOptionsBuilder, CreateImageOptionsBuilder, StartContainerOptionsBuilder, +}; use bollard::Docker; use futures_util::StreamExt; use serde::{Deserialize, Serialize}; @@ -30,18 +31,17 @@ pub struct DockerManager { impl DockerManager { pub fn new() -> Result { - let docker = Docker::connect_with_unix_defaults() - .context("Failed to connect to Docker socket")?; + let docker = + Docker::connect_with_unix_defaults().context("Failed to connect to Docker socket")?; Ok(Self { docker }) } pub async fn pull_image(&self, image: &str) -> Result<()> { info!(image = %image, "Pulling image"); - let options = CreateImageOptions { - from_image: image, - ..Default::default() - }; + let options = CreateImageOptionsBuilder::default() + .from_image(image) + .build(); let mut stream = self.docker.create_image(Some(options), None, None); @@ -72,11 +72,10 @@ impl DockerManager { pub async fn start_container(&self, spec: &WorkloadSpec) -> Result { let container_name = format!("csfx-{}", spec.workload_id); - let env: Option> = spec.env_vars.as_ref().map(|vars| { - vars.iter() - .map(|(k, v)| format!("{}={}", k, v)) - .collect() - }); + let env: Option> = spec + .env_vars + .as_ref() + .map(|vars| vars.iter().map(|(k, v)| format!("{}={}", k, v)).collect()); let (port_bindings, exposed_ports) = build_port_config(spec.ports.as_deref()); @@ -89,7 +88,7 @@ impl DockerManager { ..Default::default() }; - let config = Config { + let config = ContainerCreateBody { image: Some(spec.image.clone()), env, exposed_ports: if exposed_ports.is_empty() { @@ -105,10 +104,9 @@ impl DockerManager { ..Default::default() }; - let options = CreateContainerOptions { - name: container_name.clone(), - platform: None, - }; + let options = CreateContainerOptionsBuilder::default() + .name(&container_name) + .build(); let container = self .docker @@ -116,8 +114,10 @@ impl DockerManager { .await .context("Failed to create container")?; + let start_options = StartContainerOptionsBuilder::default().build(); + self.docker - .start_container(&container.id, None::>) + .start_container(&container.id, Some(start_options)) .await .context("Failed to start container")?; @@ -150,11 +150,11 @@ fn build_port_config( ports: Option<&[PortMapping]>, ) -> ( HashMap>>, - HashMap>, + Vec, ) { let mut port_bindings: HashMap>> = HashMap::new(); - let mut exposed_ports: HashMap> = HashMap::new(); + let mut exposed_ports: Vec = Vec::new(); if let Some(ports) = ports { for p in ports { @@ -169,7 +169,7 @@ fn build_port_config( }]), ); - exposed_ports.insert(container_key, HashMap::new()); + exposed_ports.push(container_key); } } diff --git a/agent/src/main.rs b/agent/src/main.rs index 0010d9ec..9a37e110 100644 --- a/agent/src/main.rs +++ b/agent/src/main.rs @@ -16,6 +16,10 @@ use tracing::{error, info, warn}; #[tokio::main] async fn main() -> Result<()> { + rustls::crypto::ring::default_provider() + .install_default() + .expect("failed to install ring crypto provider"); + tracing_subscriber::fmt() .with_env_filter( tracing_subscriber::EnvFilter::try_from_default_env() @@ -27,7 +31,11 @@ async fn main() -> Result<()> { let gateway_url = std::env::var("CSFX_GATEWAY_URL") .context("CSFX_GATEWAY_URL environment variable is required")?; - if let Some(username) = std::env::args().nth(1).filter(|a| a == "--authorized-keys").and_then(|_| std::env::args().nth(2)) { + if let Some(username) = std::env::args() + .nth(1) + .filter(|a| a == "--authorized-keys") + .and_then(|_| std::env::args().nth(2)) + { let agent_id = config::load_config() .context("Failed to load daemon config")? .agent_id; @@ -43,11 +51,10 @@ async fn main() -> Result<()> { .and_then(|v| v.parse().ok()) .unwrap_or(60); - let api_client = client::ApiClient::new(gateway_url.clone()) - .context("Failed to initialize API client")?; + let api_client = + client::ApiClient::new(gateway_url.clone()).context("Failed to initialize API client")?; - let agent_pki = pki::AgentPki::load_or_generate() - .context("Failed to initialize PKI")?; + let agent_pki = pki::AgentPki::load_or_generate().context("Failed to initialize PKI")?; let (agent_id, api_key) = if config::is_registered() { info!("Existing registration found, loading credentials"); @@ -56,8 +63,13 @@ async fn main() -> Result<()> { (cfg.agent_id, creds.api_key) } else { info!("No registration found, starting registration"); - perform_registration(&api_client, &gateway_url, heartbeat_interval_secs, &agent_pki) - .await? + perform_registration( + &api_client, + &gateway_url, + heartbeat_interval_secs, + &agent_pki, + ) + .await? }; let api_client = if pki::AgentPki::has_certificate() { @@ -91,8 +103,7 @@ async fn main() -> Result<()> { let running_containers: Arc>> = Arc::new(Mutex::new(HashMap::new())); - let mounted_volumes: Arc>> = - Arc::new(Mutex::new(HashMap::new())); + let mounted_volumes: Arc>> = Arc::new(Mutex::new(HashMap::new())); run_heartbeat_loop( &api_client, @@ -114,7 +125,10 @@ async fn perform_registration( heartbeat_interval_secs: u64, agent_pki: &pki::AgentPki, ) -> Result<(uuid::Uuid, String)> { - let token = match std::env::var("CSFX_REGISTRATION_TOKEN").ok().filter(|t| !t.is_empty()) { + let token = match std::env::var("CSFX_REGISTRATION_TOKEN") + .ok() + .filter(|t| !t.is_empty()) + { Some(t) => t, None => { info!("CSFX_REGISTRATION_TOKEN not set, fetching bootstrap token from gateway"); @@ -148,8 +162,7 @@ async fn perform_registration( .context("Registration request failed")?; if let (Some(cert_pem), Some(ca_pem)) = (&resp.certificate_pem, &resp.ca_cert_pem) { - pki::AgentPki::save_certificate(cert_pem, ca_pem) - .context("Failed to save certificate")?; + pki::AgentPki::save_certificate(cert_pem, ca_pem).context("Failed to save certificate")?; info!("PKI: certificate received and stored"); } else { warn!("Registry did not issue a certificate during registration"); @@ -247,7 +260,10 @@ async fn run_heartbeat_loop( } if failure_count > 0 { - error!(failures = failure_count, "Agent shutting down with unresolved heartbeat failures"); + error!( + failures = failure_count, + "Agent shutting down with unresolved heartbeat failures" + ); } } @@ -318,10 +334,7 @@ async fn process_workloads( }; for workload in workloads { - let already_running = running_containers - .lock() - .await - .contains_key(&workload.id); + let already_running = running_containers.lock().await.contains_key(&workload.id); if already_running { continue; diff --git a/agent/src/pki.rs b/agent/src/pki.rs index 95ea1fe0..81521869 100644 --- a/agent/src/pki.rs +++ b/agent/src/pki.rs @@ -15,10 +15,8 @@ pub struct AgentPki { impl AgentPki { pub fn load_or_generate() -> Result { if Path::new(KEY_FILE).exists() && Path::new(CSR_FILE).exists() { - let key_pem = std::fs::read_to_string(KEY_FILE) - .context("Failed to read agent key")?; - let csr_pem = std::fs::read_to_string(CSR_FILE) - .context("Failed to read agent CSR")?; + let key_pem = std::fs::read_to_string(KEY_FILE).context("Failed to read agent key")?; + let csr_pem = std::fs::read_to_string(CSR_FILE).context("Failed to read agent CSR")?; tracing::info!("PKI: loaded existing keypair and CSR"); return Ok(Self { key_pem, csr_pem }); @@ -32,7 +30,9 @@ impl AgentPki { .context("Failed to generate ECDSA keypair")?; let mut params = CertificateParams::default(); - params.distinguished_name.push(DnType::OrganizationName, "CS-Foundry"); + params + .distinguished_name + .push(DnType::OrganizationName, "CS-Foundry"); let csr = params .serialize_request(&key_pair) @@ -86,8 +86,7 @@ impl AgentPki { fn set_permissions_600(path: &str) -> Result<()> { use std::os::unix::fs::PermissionsExt; let perms = std::fs::Permissions::from_mode(0o600); - std::fs::set_permissions(path, perms) - .context("Failed to set file permissions") + std::fs::set_permissions(path, perms).context("Failed to set file permissions") } #[cfg(not(unix))] diff --git a/agent/src/rbd.rs b/agent/src/rbd.rs index 7b3aad80..76d00a49 100644 --- a/agent/src/rbd.rs +++ b/agent/src/rbd.rs @@ -1,4 +1,4 @@ -use anyhow::{Context, Result, anyhow}; +use anyhow::{anyhow, Context, Result}; use tokio::process::Command; use tracing::{info, warn}; diff --git a/agent/src/ssh_keys.rs b/agent/src/ssh_keys.rs index 9e481e45..7571bc72 100644 --- a/agent/src/ssh_keys.rs +++ b/agent/src/ssh_keys.rs @@ -8,10 +8,7 @@ struct AuthorizedKeysResponse { } pub async fn fetch_authorized_keys(gateway_url: &str, agent_id: Uuid) -> Result> { - let url = format!( - "{}/api/agents/{}/authorized-keys", - gateway_url, agent_id - ); + let url = format!("{}/api/agents/{}/authorized-keys", gateway_url, agent_id); let client = reqwest::Client::builder() .timeout(std::time::Duration::from_secs(5)) diff --git a/agent/src/system.rs b/agent/src/system.rs index e4679bda..2ae27cae 100644 --- a/agent/src/system.rs +++ b/agent/src/system.rs @@ -40,15 +40,16 @@ fn detect_os() -> (String, String) { .or_else(|| parse_os_release_field(&content, "BUILD_ID")); if let Some(os_type) = id { - let os_version = version.unwrap_or_else(|| { - System::os_version().unwrap_or_else(|| "unknown".to_string()) - }); + let os_version = version + .unwrap_or_else(|| System::os_version().unwrap_or_else(|| "unknown".to_string())); return (os_type.to_lowercase(), os_version); } } ( - System::name().unwrap_or_else(|| "linux".to_string()).to_lowercase(), + System::name() + .unwrap_or_else(|| "linux".to_string()) + .to_lowercase(), System::os_version().unwrap_or_else(|| "unknown".to_string()), ) } @@ -73,9 +74,13 @@ pub fn collect_metrics() -> SystemMetrics { let memory_used_bytes = sys.used_memory(); let disks = Disks::new_with_refreshed_list(); - let (disk_total_bytes, disk_used_bytes) = disks.iter().fold((0u64, 0u64), |(total, used), d| { - (total + d.total_space(), used + (d.total_space() - d.available_space())) - }); + let (disk_total_bytes, disk_used_bytes) = + disks.iter().fold((0u64, 0u64), |(total, used), d| { + ( + total + d.total_space(), + used + (d.total_space() - d.available_space()), + ) + }); let networks = Networks::new_with_refreshed_list(); let (network_rx_bytes, network_tx_bytes) = diff --git a/control-plane/api-gateway/Cargo.toml b/control-plane/api-gateway/Cargo.toml index 0c509b22..9adb4c58 100644 --- a/control-plane/api-gateway/Cargo.toml +++ b/control-plane/api-gateway/Cargo.toml @@ -30,6 +30,7 @@ hyper-util = { workspace = true } http = { workspace = true } rcgen = { workspace = true } rustls = { workspace = true } +ring = { workspace = true } # Serialization serde = { workspace = true } diff --git a/control-plane/api-gateway/src/auth/agent.rs b/control-plane/api-gateway/src/auth/agent.rs index f49853c5..23c92b77 100644 --- a/control-plane/api-gateway/src/auth/agent.rs +++ b/control-plane/api-gateway/src/auth/agent.rs @@ -1,6 +1,5 @@ use crate::AppState; use axum::{ - async_trait, extract::FromRequestParts, http::{request::Parts, StatusCode}, }; @@ -16,10 +15,13 @@ pub struct AgentApiKey { fn hash_key(key: &str) -> String { let mut hasher = Sha256::new(); hasher.update(key.as_bytes()); - format!("{:x}", hasher.finalize()) + hasher + .finalize() + .iter() + .map(|b| format!("{:02x}", b)) + .collect() } -#[async_trait] impl FromRequestParts for AgentApiKey { type Rejection = StatusCode; diff --git a/control-plane/api-gateway/src/auth/crypto.rs b/control-plane/api-gateway/src/auth/crypto.rs index ec1e9b57..42e08d02 100644 --- a/control-plane/api-gateway/src/auth/crypto.rs +++ b/control-plane/api-gateway/src/auth/crypto.rs @@ -1,6 +1,6 @@ use base64::Engine; use bcrypt::{hash, verify, DEFAULT_COST}; -use rand::rngs::OsRng; +use rsa::rand_core::{OsRng, RngCore}; use rsa::{ pkcs1::{DecodeRsaPrivateKey, EncodeRsaPrivateKey, EncodeRsaPublicKey}, RsaPrivateKey, RsaPublicKey, @@ -56,13 +56,12 @@ impl RsaKeyPair { } pub fn decrypt_password(encrypted_password: &str, private_key: &str) -> CryptoResult { + use rsa::sha2::Sha256; use rsa::Oaep; - use sha2::Sha256; let private_key = RsaPrivateKey::from_pkcs1_pem(private_key)?; let encrypted_bytes = base64::engine::general_purpose::STANDARD.decode(encrypted_password)?; - // Use SHA-256 for RSA-OAEP padding let padding = Oaep::new::(); let decrypted = private_key.decrypt(padding, &encrypted_bytes)?; @@ -80,9 +79,10 @@ pub fn verify_password(password: &str, salt: &str, hashed: &str) -> CryptoResult } pub fn encrypt_secret(plaintext: &str, key_b64: &str) -> CryptoResult { - use aes_gcm::{aead::{Aead, KeyInit}, Aes256Gcm, Nonce}; - use rand::RngCore; - + use aes_gcm::{ + aead::{Aead, KeyInit}, + Aes256Gcm, Nonce, + }; let key_bytes = base64::engine::general_purpose::STANDARD .decode(key_b64) .map_err(|_| CryptoError::InvalidEncryptedData)?; @@ -90,7 +90,8 @@ pub fn encrypt_secret(plaintext: &str, key_b64: &str) -> CryptoResult { return Err(CryptoError::InvalidEncryptedData); } - let cipher = Aes256Gcm::new_from_slice(&key_bytes).map_err(|_| CryptoError::InvalidEncryptedData)?; + let cipher = + Aes256Gcm::new_from_slice(&key_bytes).map_err(|_| CryptoError::InvalidEncryptedData)?; let mut nonce_bytes = [0u8; 12]; OsRng.fill_bytes(&mut nonce_bytes); let nonce = Nonce::from_slice(&nonce_bytes); @@ -105,7 +106,10 @@ pub fn encrypt_secret(plaintext: &str, key_b64: &str) -> CryptoResult { } pub fn decrypt_secret(encoded: &str, key_b64: &str) -> CryptoResult { - use aes_gcm::{aead::{Aead, KeyInit}, Aes256Gcm, Nonce}; + use aes_gcm::{ + aead::{Aead, KeyInit}, + Aes256Gcm, Nonce, + }; let key_bytes = base64::engine::general_purpose::STANDARD .decode(key_b64) @@ -122,7 +126,8 @@ pub fn decrypt_secret(encoded: &str, key_b64: &str) -> CryptoResult { } let (nonce_bytes, ciphertext) = combined.split_at(12); - let cipher = Aes256Gcm::new_from_slice(&key_bytes).map_err(|_| CryptoError::InvalidEncryptedData)?; + let cipher = + Aes256Gcm::new_from_slice(&key_bytes).map_err(|_| CryptoError::InvalidEncryptedData)?; let nonce = Nonce::from_slice(nonce_bytes); let plaintext = cipher @@ -133,16 +138,14 @@ pub fn decrypt_secret(encoded: &str, key_b64: &str) -> CryptoResult { } pub fn generate_salt() -> String { - use rand::Rng; const CHARSET: &[u8] = b"ABCDEFGHIJKLMNOPQRSTUVWXYZ\ abcdefghijklmnopqrstuvwxyz\ 0123456789"; const SALT_LEN: usize = 32; - let mut rng = rand::thread_rng(); (0..SALT_LEN) .map(|_| { - let idx = rng.gen_range(0..CHARSET.len()); + let idx = rand::random_range(0..CHARSET.len()); CHARSET[idx] as char }) .collect() diff --git a/control-plane/api-gateway/src/auth/middleware.rs b/control-plane/api-gateway/src/auth/middleware.rs index c9ffed82..95cfd15d 100644 --- a/control-plane/api-gateway/src/auth/middleware.rs +++ b/control-plane/api-gateway/src/auth/middleware.rs @@ -3,7 +3,6 @@ use crate::{ AppState, }; use axum::{ - async_trait, extract::FromRequestParts, http::{request::Parts, StatusCode}, }; @@ -14,7 +13,6 @@ use sea_orm::{ColumnTrait, EntityTrait, QueryFilter}; // Custom extractor for authenticated requests pub struct AuthenticatedUser(pub Claims); -#[async_trait] impl FromRequestParts for AuthenticatedUser { type Rejection = StatusCode; diff --git a/control-plane/api-gateway/src/auth/rbac.rs b/control-plane/api-gateway/src/auth/rbac.rs index 9b93c49e..69e42bbc 100644 --- a/control-plane/api-gateway/src/auth/rbac.rs +++ b/control-plane/api-gateway/src/auth/rbac.rs @@ -4,7 +4,6 @@ use crate::{ AppState, }; use axum::{ - async_trait, extract::FromRequestParts, http::{request::Parts, StatusCode}, }; @@ -42,7 +41,11 @@ async fn extract_claims(parts: &mut Parts, state: &AppState) -> Result, ) -> Result { let mut client = etcd_client().await?; - client - .delete(ETCD_PAUSED_KEY, None) - .await - .map_err(|e| { - tracing::error!(error = %e, "failed to delete update_paused from etcd"); - StatusCode::INTERNAL_SERVER_ERROR - })?; + client.delete(ETCD_PAUSED_KEY, None).await.map_err(|e| { + tracing::error!(error = %e, "failed to delete update_paused from etcd"); + StatusCode::INTERNAL_SERVER_ERROR + })?; tracing::info!("updates resumed"); Ok(StatusCode::NO_CONTENT) } diff --git a/control-plane/api-gateway/src/routes/volumes.rs b/control-plane/api-gateway/src/routes/volumes.rs index 610d629e..da5ef09b 100644 --- a/control-plane/api-gateway/src/routes/volumes.rs +++ b/control-plane/api-gateway/src/routes/volumes.rs @@ -8,7 +8,10 @@ use axum::{ }; use serde_json::json; -use crate::{auth::rbac::{CanManageVolumes, CanViewVolumes}, AppState}; +use crate::{ + auth::rbac::{CanManageVolumes, CanViewVolumes}, + AppState, +}; async fn proxy_to_volume_manager( state: &AppState, @@ -36,7 +39,9 @@ async fn proxy_to_volume_manager( tracing::error!("Failed to forward request to volume-manager: {}", e); Err(( StatusCode::BAD_GATEWAY, - Json(json!({ "error": "Volume Manager service unavailable", "details": e.to_string() })), + Json( + json!({ "error": "Volume Manager service unavailable", "details": e.to_string() }), + ), )) } } @@ -57,7 +62,14 @@ pub async fn create_volume( ) -> Result)> { let body_json: Option = serde_json::from_str(&body).ok(); let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::POST, "/volumes", body_json, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::POST, + "/volumes", + body_json, + Some(header_map), + ) + .await } pub async fn list_volumes( @@ -66,7 +78,14 @@ pub async fn list_volumes( headers: HeaderMap, ) -> Result)> { let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::GET, "/volumes", None, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::GET, + "/volumes", + None, + Some(header_map), + ) + .await } pub async fn get_volume( @@ -76,7 +95,14 @@ pub async fn get_volume( headers: HeaderMap, ) -> Result)> { let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::GET, &format!("/volumes/{}", id), None, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::GET, + &format!("/volumes/{}", id), + None, + Some(header_map), + ) + .await } pub async fn delete_volume( @@ -86,7 +112,14 @@ pub async fn delete_volume( headers: HeaderMap, ) -> Result)> { let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::DELETE, &format!("/volumes/{}", id), None, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::DELETE, + &format!("/volumes/{}", id), + None, + Some(header_map), + ) + .await } pub async fn attach_volume( @@ -98,7 +131,14 @@ pub async fn attach_volume( ) -> Result)> { let body_json: Option = serde_json::from_str(&body).ok(); let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::POST, &format!("/volumes/{}/attach", id), body_json, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::POST, + &format!("/volumes/{}/attach", id), + body_json, + Some(header_map), + ) + .await } pub async fn detach_volume( @@ -108,7 +148,14 @@ pub async fn detach_volume( headers: HeaderMap, ) -> Result)> { let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::POST, &format!("/volumes/{}/detach", id), None, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::POST, + &format!("/volumes/{}/detach", id), + None, + Some(header_map), + ) + .await } pub async fn create_snapshot( @@ -120,7 +167,14 @@ pub async fn create_snapshot( ) -> Result)> { let body_json: Option = serde_json::from_str(&body).ok(); let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::POST, &format!("/volumes/{}/snapshots", id), body_json, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::POST, + &format!("/volumes/{}/snapshots", id), + body_json, + Some(header_map), + ) + .await } pub async fn list_snapshots( @@ -130,17 +184,24 @@ pub async fn list_snapshots( headers: HeaderMap, ) -> Result)> { let header_map = header_vec(&headers); - proxy_to_volume_manager(&state, reqwest::Method::GET, &format!("/volumes/{}/snapshots", id), None, Some(header_map)).await + proxy_to_volume_manager( + &state, + reqwest::Method::GET, + &format!("/volumes/{}/snapshots", id), + None, + Some(header_map), + ) + .await } pub fn volumes_routes() -> Router { Router::new() .route("/volumes", post(create_volume)) .route("/volumes", get(list_volumes)) - .route("/volumes/:id", get(get_volume)) - .route("/volumes/:id", delete(delete_volume)) - .route("/volumes/:id/attach", post(attach_volume)) - .route("/volumes/:id/detach", post(detach_volume)) - .route("/volumes/:id/snapshots", post(create_snapshot)) - .route("/volumes/:id/snapshots", get(list_snapshots)) + .route("/volumes/{id}", get(get_volume)) + .route("/volumes/{id}", delete(delete_volume)) + .route("/volumes/{id}/attach", post(attach_volume)) + .route("/volumes/{id}/detach", post(detach_volume)) + .route("/volumes/{id}/snapshots", post(create_snapshot)) + .route("/volumes/{id}/snapshots", get(list_snapshots)) } diff --git a/control-plane/api-gateway/src/routes/workloads.rs b/control-plane/api-gateway/src/routes/workloads.rs index 2746a452..df1e0a81 100644 --- a/control-plane/api-gateway/src/routes/workloads.rs +++ b/control-plane/api-gateway/src/routes/workloads.rs @@ -8,7 +8,10 @@ use axum::{ }; use serde_json::json; -use crate::{auth::rbac::{CanManageWorkloads, CanViewWorkloads}, AppState}; +use crate::{ + auth::rbac::{CanManageWorkloads, CanViewWorkloads}, + AppState, +}; async fn proxy_to_scheduler( state: &AppState, @@ -50,7 +53,14 @@ pub async fn create_workload( ) -> Result)> { let body_json: Option = serde_json::from_str(&body).ok(); let header_map = header_vec(&headers); - proxy_to_scheduler(&state, reqwest::Method::POST, "/workloads", body_json, Some(header_map)).await + proxy_to_scheduler( + &state, + reqwest::Method::POST, + "/workloads", + body_json, + Some(header_map), + ) + .await } pub async fn list_workloads( @@ -59,7 +69,14 @@ pub async fn list_workloads( headers: HeaderMap, ) -> Result)> { let header_map = header_vec(&headers); - proxy_to_scheduler(&state, reqwest::Method::GET, "/workloads", None, Some(header_map)).await + proxy_to_scheduler( + &state, + reqwest::Method::GET, + "/workloads", + None, + Some(header_map), + ) + .await } pub async fn delete_workload( @@ -90,5 +107,5 @@ pub fn workloads_routes() -> Router { Router::new() .route("/workloads", post(create_workload)) .route("/workloads", get(list_workloads)) - .route("/workloads/:id", delete(delete_workload)) + .route("/workloads/{id}", delete(delete_workload)) } diff --git a/control-plane/api-gateway/src/self_monitor.rs b/control-plane/api-gateway/src/self_monitor.rs index c457225d..9c9604d7 100644 --- a/control-plane/api-gateway/src/self_monitor.rs +++ b/control-plane/api-gateway/src/self_monitor.rs @@ -120,7 +120,7 @@ impl SelfMonitor { .map(|cpu| cpu.brand().to_string()) .unwrap_or_else(|| "Unknown".to_string()); - let cpu_cores = self.system.physical_core_count().unwrap_or(0) as u32; + let cpu_cores = self.system.cpus().len() as u32; let cpu_threads = self.system.cpus().len() as u32; let cpu_usage_percent = if !self.system.cpus().is_empty() { diff --git a/control-plane/api-gateway/src/service_client.rs b/control-plane/api-gateway/src/service_client.rs index b97acfa3..dad81e33 100644 --- a/control-plane/api-gateway/src/service_client.rs +++ b/control-plane/api-gateway/src/service_client.rs @@ -232,7 +232,11 @@ impl ServiceClient { ) -> Result<(StatusCode, Option)> { let url = format!("{}{}", self.failover_controller_url, path); - tracing::debug!("Forwarding {} request to failover-controller: {}", method, url); + tracing::debug!( + "Forwarding {} request to failover-controller: {}", + method, + url + ); let mut request = match method { reqwest::Method::GET => self.client.get(&url), diff --git a/control-plane/api-gateway/src/system_collector.rs b/control-plane/api-gateway/src/system_collector.rs index 166f79dc..94ce3036 100644 --- a/control-plane/api-gateway/src/system_collector.rs +++ b/control-plane/api-gateway/src/system_collector.rs @@ -68,7 +68,7 @@ impl LocalSystemCollector { .map(|cpu| cpu.brand().to_string()) .unwrap_or_else(|| "Unknown".to_string()); - let cpu_cores = system.physical_core_count().unwrap_or(0) as u32; + let cpu_cores = system.cpus().len() as u32; let cpu_threads = system.cpus().len() as u32; let cpu_usage_percent = if !system.cpus().is_empty() { diff --git a/control-plane/api-gateway/src/telemetry.rs b/control-plane/api-gateway/src/telemetry.rs index de6754f0..0614fc30 100644 --- a/control-plane/api-gateway/src/telemetry.rs +++ b/control-plane/api-gateway/src/telemetry.rs @@ -32,9 +32,7 @@ pub fn init_tracing() { let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); let fmt_layer = fmt::layer().with_target(false); - let registry = tracing_subscriber::registry() - .with(filter) - .with(fmt_layer); + let registry = tracing_subscriber::registry().with(filter).with(fmt_layer); match build_otlp_provider() { Some(provider) => { diff --git a/control-plane/api-gateway/src/tls.rs b/control-plane/api-gateway/src/tls.rs index 6537cb23..bfbd69b9 100644 --- a/control-plane/api-gateway/src/tls.rs +++ b/control-plane/api-gateway/src/tls.rs @@ -17,7 +17,9 @@ pub async fn generate_tls_config() -> anyhow::Result { let mut params = CertificateParams::default(); params.distinguished_name = DistinguishedName::new(); - params.distinguished_name.push(DnType::CommonName, "csfx-gateway"); + params + .distinguished_name + .push(DnType::CommonName, "csfx-gateway"); let san_hosts = std::env::var("TLS_SANS").unwrap_or_else(|_| "localhost,127.0.0.1".to_string()); for san in san_hosts.split(',') { @@ -25,7 +27,9 @@ pub async fn generate_tls_config() -> anyhow::Result { if let Ok(ip) = san.parse::() { params.subject_alt_names.push(SanType::IpAddress(ip)); } else { - params.subject_alt_names.push(SanType::DnsName(san.try_into()?)); + params + .subject_alt_names + .push(SanType::DnsName(san.try_into()?)); } } diff --git a/control-plane/csfx-updater/Cargo.toml b/control-plane/csfx-updater/Cargo.toml index 58056c3f..173140cd 100644 --- a/control-plane/csfx-updater/Cargo.toml +++ b/control-plane/csfx-updater/Cargo.toml @@ -16,6 +16,8 @@ tracing-subscriber = { workspace = true } dotenvy = { workspace = true } anyhow = { workspace = true } etcd-client = { workspace = true } -reqwest = { version = "0.13", features = ["json", "rustls-tls-webpki-roots"], default-features = false } +reqwest = { version = "0.13", features = ["json", "rustls-no-provider", "webpki-roots"], default-features = false } +ring = { workspace = true } +rustls = { workspace = true } serde = { workspace = true } serde_json = { workspace = true } diff --git a/control-plane/csfx-updater/src/config.rs b/control-plane/csfx-updater/src/config.rs index 5cd02b47..c335b728 100644 --- a/control-plane/csfx-updater/src/config.rs +++ b/control-plane/csfx-updater/src/config.rs @@ -32,10 +32,8 @@ impl Config { .context("INFRA_REPO_MIRROR_URL must be set")?, infra_repo_github: env::var("INFRA_REPO_GITHUB") .context("INFRA_REPO_GITHUB must be set (e.g. csfx-cloud/CSFX-Infra)")?, - infra_repo_branch: env::var("INFRA_REPO_BRANCH") - .unwrap_or_else(|_| "main".to_string()), - nixos_config: env::var("NIXOS_CONFIG") - .unwrap_or_else(|_| "csfx-node".to_string()), + infra_repo_branch: env::var("INFRA_REPO_BRANCH").unwrap_or_else(|_| "main".to_string()), + nixos_config: env::var("NIXOS_CONFIG").unwrap_or_else(|_| "csfx-node".to_string()), gateway_url: env::var("GATEWAY_URL") .unwrap_or_else(|_| "https://localhost:8000".to_string()), health_check_timeout_secs: env::var("HEALTH_CHECK_TIMEOUT_SECS") diff --git a/control-plane/csfx-updater/src/git_mirror.rs b/control-plane/csfx-updater/src/git_mirror.rs index 91532051..c0bccab8 100644 --- a/control-plane/csfx-updater/src/git_mirror.rs +++ b/control-plane/csfx-updater/src/git_mirror.rs @@ -49,6 +49,5 @@ pub async fn rev_exists(mirror_dir: &str, rev: &str) -> Result { .output() .await?; - Ok(output.status.success() - && String::from_utf8_lossy(&output.stdout).trim() == "commit") + Ok(output.status.success() && String::from_utf8_lossy(&output.stdout).trim() == "commit") } diff --git a/control-plane/csfx-updater/src/health.rs b/control-plane/csfx-updater/src/health.rs index d0c0a709..255daf15 100644 --- a/control-plane/csfx-updater/src/health.rs +++ b/control-plane/csfx-updater/src/health.rs @@ -2,7 +2,11 @@ use std::time::Duration; use tokio::time::sleep; use tracing::{info, warn}; -pub async fn wait_for_gateway(gateway_url: &str, timeout_secs: u64, retry_interval_secs: u64) -> bool { +pub async fn wait_for_gateway( + gateway_url: &str, + timeout_secs: u64, + retry_interval_secs: u64, +) -> bool { let deadline = tokio::time::Instant::now() + Duration::from_secs(timeout_secs); let probe_url = format!("{}/api/public-key", gateway_url.trim_end_matches('/')); let client = reqwest::Client::builder() diff --git a/control-plane/csfx-updater/src/main.rs b/control-plane/csfx-updater/src/main.rs index 561c803e..8f57875d 100644 --- a/control-plane/csfx-updater/src/main.rs +++ b/control-plane/csfx-updater/src/main.rs @@ -13,6 +13,10 @@ use tracing::info; #[tokio::main] async fn main() -> anyhow::Result<()> { + rustls::crypto::ring::default_provider() + .install_default() + .expect("failed to install ring crypto provider"); + dotenvy::dotenv().ok(); tracing_subscriber::fmt() @@ -143,7 +147,14 @@ async fn execute_once(cfg: &config::Config, last_applied: &str) -> anyhow::Resul let (_cancel_tx, cancel_rx) = watch::channel(false); - match nix_build::build(&cfg.infra_repo_mirror_dir, &desired, &cfg.nixos_config, cancel_rx).await { + match nix_build::build( + &cfg.infra_repo_mirror_dir, + &desired, + &cfg.nixos_config, + cancel_rx, + ) + .await + { Ok(()) => {} Err(e) => { tracing::error!(error = %e, flake_rev = %desired, "nix build failed"); diff --git a/control-plane/csfx-updater/src/nix_build.rs b/control-plane/csfx-updater/src/nix_build.rs index 295d999e..64be608e 100644 --- a/control-plane/csfx-updater/src/nix_build.rs +++ b/control-plane/csfx-updater/src/nix_build.rs @@ -3,7 +3,12 @@ use tokio::process::Command; use tokio::sync::watch; use tracing::info; -pub async fn build(mirror_dir: &str, rev: &str, nixos_config: &str, mut cancel: watch::Receiver) -> Result<()> { +pub async fn build( + mirror_dir: &str, + rev: &str, + nixos_config: &str, + mut cancel: watch::Receiver, +) -> Result<()> { let flake_url = format!("git+file://{}?rev={}#{}", mirror_dir, rev, nixos_config); info!(flake_rev = %rev, nixos_config = %nixos_config, "starting nix build"); diff --git a/control-plane/csfx-updater/src/poller.rs b/control-plane/csfx-updater/src/poller.rs index 322a3200..5b52f52e 100644 --- a/control-plane/csfx-updater/src/poller.rs +++ b/control-plane/csfx-updater/src/poller.rs @@ -122,7 +122,10 @@ async fn dereference_tag(cfg: &Config, tag_sha: &str) -> Result { .await?; if !resp.status().is_success() { - bail!("GitHub API returned {} when dereferencing tag", resp.status()); + bail!( + "GitHub API returned {} when dereferencing tag", + resp.status() + ); } let tag: GitHubTag = resp.json().await?; diff --git a/control-plane/csfx-updater/src/rollback.rs b/control-plane/csfx-updater/src/rollback.rs index e1abc17d..ffe6df91 100644 --- a/control-plane/csfx-updater/src/rollback.rs +++ b/control-plane/csfx-updater/src/rollback.rs @@ -11,7 +11,10 @@ pub async fn rollback() -> Result<()> { .await?; if !status.success() { - bail!("nixos-rebuild switch --rollback failed with status {}", status); + bail!( + "nixos-rebuild switch --rollback failed with status {}", + status + ); } info!("rollback complete"); diff --git a/control-plane/failover-controller/Cargo.toml b/control-plane/failover-controller/Cargo.toml index b1a4bd64..c8118cd9 100644 --- a/control-plane/failover-controller/Cargo.toml +++ b/control-plane/failover-controller/Cargo.toml @@ -27,6 +27,8 @@ chrono = { workspace = true, features = ["serde"] } sea-orm = { workspace = true } etcd-client = { workspace = true } reqwest = { workspace = true, features = ["json"] } +ring = { workspace = true } +rustls = { workspace = true } prometheus = { workspace = true } opentelemetry = { workspace = true } opentelemetry_sdk = { workspace = true } diff --git a/control-plane/failover-controller/src/db/agents.rs b/control-plane/failover-controller/src/db/agents.rs index d8f2acb5..0a9720a5 100644 --- a/control-plane/failover-controller/src/db/agents.rs +++ b/control-plane/failover-controller/src/db/agents.rs @@ -1,16 +1,10 @@ use anyhow::Result; use chrono::Utc; use entity::entities::agents; -use sea_orm::{ - ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set, -}; +use sea_orm::{ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set}; use uuid::Uuid; -pub async fn set_agent_status( - db: &DatabaseConnection, - agent_id: Uuid, - status: &str, -) -> Result<()> { +pub async fn set_agent_status(db: &DatabaseConnection, agent_id: Uuid, status: &str) -> Result<()> { let agent = agents::Entity::find_by_id(agent_id) .one(db) .await? diff --git a/control-plane/failover-controller/src/db/events.rs b/control-plane/failover-controller/src/db/events.rs index 59b8bd37..16c1be5c 100644 --- a/control-plane/failover-controller/src/db/events.rs +++ b/control-plane/failover-controller/src/db/events.rs @@ -13,8 +13,8 @@ pub async fn insert( affected_workloads: Option>, duration_ms: Option, ) -> Result { - let workloads_json = affected_workloads - .map(|ids| serde_json::to_value(ids).unwrap_or(serde_json::Value::Null)); + let workloads_json = + affected_workloads.map(|ids| serde_json::to_value(ids).unwrap_or(serde_json::Value::Null)); let model = failover_events::ActiveModel { id: Set(Uuid::new_v4()), diff --git a/control-plane/failover-controller/src/logger.rs b/control-plane/failover-controller/src/logger.rs index 8d9f9d62..727fe564 100644 --- a/control-plane/failover-controller/src/logger.rs +++ b/control-plane/failover-controller/src/logger.rs @@ -58,9 +58,7 @@ pub fn init_logger_with_service(service_name: &'static str) { let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); let fmt_layer = fmt::layer().with_target(false).with_thread_ids(true); - let registry = tracing_subscriber::registry() - .with(filter) - .with(fmt_layer); + let registry = tracing_subscriber::registry().with(filter).with(fmt_layer); match build_otlp_provider(service_name) { Some(provider) => { @@ -79,11 +77,21 @@ pub fn log_message(level: LogLevel, module: &str, location: &str, description: & let lvl: Level = level.into(); match lvl { - Level::ERROR => event!(Level::ERROR, module = %module, location = %location, "{}", description), - Level::WARN => event!(Level::WARN, module = %module, location = %location, "{}", description), - Level::INFO => event!(Level::INFO, module = %module, location = %location, "{}", description), - Level::DEBUG => event!(Level::DEBUG, module = %module, location = %location, "{}", description), - Level::TRACE => event!(Level::TRACE, module = %module, location = %location, "{}", description), + Level::ERROR => { + event!(Level::ERROR, module = %module, location = %location, "{}", description) + } + Level::WARN => { + event!(Level::WARN, module = %module, location = %location, "{}", description) + } + Level::INFO => { + event!(Level::INFO, module = %module, location = %location, "{}", description) + } + Level::DEBUG => { + event!(Level::DEBUG, module = %module, location = %location, "{}", description) + } + Level::TRACE => { + event!(Level::TRACE, module = %module, location = %location, "{}", description) + } } } diff --git a/control-plane/failover-controller/src/main.rs b/control-plane/failover-controller/src/main.rs index 31433c71..65c17d05 100644 --- a/control-plane/failover-controller/src/main.rs +++ b/control-plane/failover-controller/src/main.rs @@ -10,6 +10,10 @@ mod services; #[tokio::main] async fn main() -> anyhow::Result<()> { + rustls::crypto::ring::default_provider() + .install_default() + .expect("failed to install ring crypto provider"); + dotenvy::dotenv().ok(); logger::init_logger(); diff --git a/control-plane/failover-controller/src/metrics.rs b/control-plane/failover-controller/src/metrics.rs index 64d068b0..aa5a9792 100644 --- a/control-plane/failover-controller/src/metrics.rs +++ b/control-plane/failover-controller/src/metrics.rs @@ -1,5 +1,7 @@ use axum::response::IntoResponse; -use prometheus::{register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder}; +use prometheus::{ + register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder, +}; use std::sync::OnceLock; static HTTP_REQUESTS_TOTAL: OnceLock = OnceLock::new(); @@ -46,7 +48,10 @@ pub async fn metrics_handler() -> impl IntoResponse { .encode(&metric_families, &mut buffer) .expect("failed to encode metrics"); ( - [(axum::http::header::CONTENT_TYPE, "text/plain; version=0.0.4")], + [( + axum::http::header::CONTENT_TYPE, + "text/plain; version=0.0.4", + )], buffer, ) } diff --git a/control-plane/failover-controller/src/services/failover.rs b/control-plane/failover-controller/src/services/failover.rs index 98688ffd..993f4b2d 100644 --- a/control-plane/failover-controller/src/services/failover.rs +++ b/control-plane/failover-controller/src/services/failover.rs @@ -132,10 +132,7 @@ impl FailoverService { Err(e) => { crate::log_warn!( "failover", - &format!( - "Reschedule request failed agent_id={} err={}", - agent_id, e - ) + &format!("Reschedule request failed agent_id={} err={}", agent_id, e) ); } } diff --git a/control-plane/failover-controller/src/services/monitor.rs b/control-plane/failover-controller/src/services/monitor.rs index b1929036..a35eda63 100644 --- a/control-plane/failover-controller/src/services/monitor.rs +++ b/control-plane/failover-controller/src/services/monitor.rs @@ -33,7 +33,10 @@ pub async fn run(db: DatabaseConnection) { if let Err(e) = agent_db::set_agent_status(&db, agent.id, "Degraded").await { crate::log_error!( "monitor", - &format!("Failed to mark agent degraded agent_id={} err={}", agent.id, e) + &format!( + "Failed to mark agent degraded agent_id={} err={}", + agent.id, e + ) ); continue; } @@ -49,7 +52,10 @@ pub async fn run(db: DatabaseConnection) { if let Err(e) = events::insert(&db, Some(agent.id), "degraded", None, None).await { crate::log_error!( "monitor", - &format!("Failed to insert degraded event agent_id={} err={}", agent.id, e) + &format!( + "Failed to insert degraded event agent_id={} err={}", + agent.id, e + ) ); } } @@ -58,7 +64,10 @@ pub async fn run(db: DatabaseConnection) { if let Err(e) = agent_db::set_agent_status(&db, agent.id, "Offline").await { crate::log_error!( "monitor", - &format!("Failed to mark agent offline agent_id={} err={}", agent.id, e) + &format!( + "Failed to mark agent offline agent_id={} err={}", + agent.id, e + ) ); continue; } diff --git a/control-plane/registry/Cargo.toml b/control-plane/registry/Cargo.toml index d0f6e577..22b5d361 100644 --- a/control-plane/registry/Cargo.toml +++ b/control-plane/registry/Cargo.toml @@ -39,6 +39,8 @@ sea-orm = { workspace = true } reqwest = { workspace = true } etcd-client = { workspace = true } +ring = { workspace = true } +rustls = { workspace = true } # Crypto sha2 = { workspace = true } diff --git a/control-plane/registry/src/db/agents.rs b/control-plane/registry/src/db/agents.rs index c6b16edb..c23ce15b 100644 --- a/control-plane/registry/src/db/agents.rs +++ b/control-plane/registry/src/db/agents.rs @@ -1,8 +1,6 @@ use anyhow::Result; use entity::agents; -use sea_orm::{ - ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set, -}; +use sea_orm::{ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set}; use uuid::Uuid; pub async fn get_by_hostname( @@ -118,8 +116,14 @@ pub async fn mark_degraded_by_timeout( ) -> Result { let threshold = chrono::Utc::now().naive_utc() - chrono::Duration::seconds(timeout_seconds); let result = agents::Entity::update_many() - .col_expr(agents::Column::Status, sea_orm::sea_query::Expr::value("Degraded")) - .col_expr(agents::Column::UpdatedAt, sea_orm::sea_query::Expr::value(chrono::Utc::now().naive_utc())) + .col_expr( + agents::Column::Status, + sea_orm::sea_query::Expr::value("Degraded"), + ) + .col_expr( + agents::Column::UpdatedAt, + sea_orm::sea_query::Expr::value(chrono::Utc::now().naive_utc()), + ) .filter(agents::Column::LastHeartbeat.lt(threshold)) .filter(agents::Column::Status.eq("Online")) .exec(db) @@ -127,12 +131,8 @@ pub async fn mark_degraded_by_timeout( Ok(result.rows_affected) } -pub async fn mark_offline_by_timeout( - db: &DatabaseConnection, - timeout_seconds: i64, -) -> Result { - let threshold = - chrono::Utc::now().naive_utc() - chrono::Duration::seconds(timeout_seconds); +pub async fn mark_offline_by_timeout(db: &DatabaseConnection, timeout_seconds: i64) -> Result { + let threshold = chrono::Utc::now().naive_utc() - chrono::Duration::seconds(timeout_seconds); let result = agents::Entity::update_many() .col_expr( @@ -145,8 +145,9 @@ pub async fn mark_offline_by_timeout( ) .filter(agents::Column::LastHeartbeat.lt(threshold)) .filter( - agents::Column::Status.eq("Online") - .or(agents::Column::Status.eq("Degraded")) + agents::Column::Status + .eq("Online") + .or(agents::Column::Status.eq("Degraded")), ) .exec(db) .await?; diff --git a/control-plane/registry/src/db/api_keys.rs b/control-plane/registry/src/db/api_keys.rs index a4e9e042..1f1f1456 100644 --- a/control-plane/registry/src/db/api_keys.rs +++ b/control-plane/registry/src/db/api_keys.rs @@ -1,15 +1,13 @@ use anyhow::Result; use entity::{agent_api_keys, agents}; -use sea_orm::{ - ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set, -}; +use sea_orm::{ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set}; use sha2::{Digest, Sha256}; use uuid::Uuid; pub fn hash_key(key: &str) -> String { let mut hasher = Sha256::new(); hasher.update(key.as_bytes()); - format!("{:x}", hasher.finalize()) + hasher.finalize().iter().map(|b| format!("{:02x}", b)).collect() } pub async fn create( diff --git a/control-plane/registry/src/db/bootstrap_tokens.rs b/control-plane/registry/src/db/bootstrap_tokens.rs index ec7dbbf2..cb01fed6 100644 --- a/control-plane/registry/src/db/bootstrap_tokens.rs +++ b/control-plane/registry/src/db/bootstrap_tokens.rs @@ -1,8 +1,6 @@ use anyhow::Result; use entity::bootstrap_tokens; -use sea_orm::{ - ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set, -}; +use sea_orm::{ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set}; use uuid::Uuid; pub async fn create( @@ -67,9 +65,7 @@ pub async fn revoke(db: &DatabaseConnection, id: Uuid) -> Result<()> { Ok(()) } -pub async fn get_all_active( - db: &DatabaseConnection, -) -> Result> { +pub async fn get_all_active(db: &DatabaseConnection) -> Result> { Ok(bootstrap_tokens::Entity::find() .filter(bootstrap_tokens::Column::Revoked.eq(false)) .all(db) diff --git a/control-plane/registry/src/db/certificates.rs b/control-plane/registry/src/db/certificates.rs index f6e2dc95..434ae15d 100644 --- a/control-plane/registry/src/db/certificates.rs +++ b/control-plane/registry/src/db/certificates.rs @@ -1,8 +1,6 @@ use anyhow::Result; use entity::{agent_certificates, certificate_revocations}; -use sea_orm::{ - ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set, -}; +use sea_orm::{ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set}; use uuid::Uuid; pub async fn create_certificate( diff --git a/control-plane/registry/src/db/tokens.rs b/control-plane/registry/src/db/tokens.rs index d855b48b..89ff98b5 100644 --- a/control-plane/registry/src/db/tokens.rs +++ b/control-plane/registry/src/db/tokens.rs @@ -1,8 +1,6 @@ use anyhow::Result; use entity::registry_tokens; -use sea_orm::{ - ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set, -}; +use sea_orm::{ActiveModelTrait, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, Set}; use uuid::Uuid; pub async fn create( diff --git a/control-plane/registry/src/handlers/admin.rs b/control-plane/registry/src/handlers/admin.rs index 25f5f055..59a3a6f7 100644 --- a/control-plane/registry/src/handlers/admin.rs +++ b/control-plane/registry/src/handlers/admin.rs @@ -89,10 +89,7 @@ pub async fn delete_pending_agent( .await { Ok(_) => Ok(StatusCode::NO_CONTENT), - Err(e) => Err(( - StatusCode::NOT_FOUND, - Json(ErrorResponse { error: e }), - )), + Err(e) => Err((StatusCode::NOT_FOUND, Json(ErrorResponse { error: e }))), } } @@ -144,16 +141,29 @@ pub async fn get_statistics( pub async fn create_bootstrap_token( State(state): State, Json(request): Json, -) -> Result, (StatusCode, Json)> { +) -> Result< + Json, + (StatusCode, Json), +> { let ttl_hours = request.ttl_hours.unwrap_or(24 * 30); let max_uses = request.max_uses.unwrap_or(100); state .bootstrap_token_manager - .create(request.description, "admin".to_string(), ttl_hours, max_uses) + .create( + request.description, + "admin".to_string(), + ttl_hours, + max_uses, + ) .await .map(Json) - .map_err(|e| (StatusCode::INTERNAL_SERVER_ERROR, Json(ErrorResponse { error: e }))) + .map_err(|e| { + ( + StatusCode::INTERNAL_SERVER_ERROR, + Json(ErrorResponse { error: e }), + ) + }) } pub async fn list_bootstrap_tokens( @@ -170,6 +180,10 @@ pub async fn revoke_bootstrap_token( .bootstrap_token_manager .revoke(id) .await - .map(|_| Json(RevokeBootstrapTokenResponse { message: format!("Bootstrap token {} revoked", id) })) + .map(|_| { + Json(RevokeBootstrapTokenResponse { + message: format!("Bootstrap token {} revoked", id), + }) + }) .map_err(|e| (StatusCode::NOT_FOUND, Json(ErrorResponse { error: e }))) } diff --git a/control-plane/registry/src/handlers/agent.rs b/control-plane/registry/src/handlers/agent.rs index 834144f3..c6992bd7 100644 --- a/control-plane/registry/src/handlers/agent.rs +++ b/control-plane/registry/src/handlers/agent.rs @@ -6,7 +6,9 @@ use axum::{ use uuid::Uuid; use crate::{ - models::agent::{ErrorResponse, HeartbeatRequest, HeartbeatResponse, RegisterRequest, RegisterResponse}, + models::agent::{ + ErrorResponse, HeartbeatRequest, HeartbeatResponse, RegisterRequest, RegisterResponse, + }, server::AppState, services::registry::RegisterAgentParams, }; @@ -108,7 +110,10 @@ pub async fn register_agent( if let Err(e) = state.api_key_manager.revoke_all_keys(agent.id).await { crate::log_warn!( "agent_handler", - &format!("Failed to revoke old API keys for agent={}: {}", agent.id, e) + &format!( + "Failed to revoke old API keys for agent={}: {}", + agent.id, e + ) ); } } @@ -300,7 +305,10 @@ async fn forward_container_statuses( if let Err(e) = state.http_client.post(&url).json(&payload).send().await { crate::log_warn!( "agent_handler", - &format!("Failed to forward container statuses to scheduler err={}", e) + &format!( + "Failed to forward container statuses to scheduler err={}", + e + ) ); } } diff --git a/control-plane/registry/src/handlers/pki.rs b/control-plane/registry/src/handlers/pki.rs index ac925853..b087147b 100644 --- a/control-plane/registry/src/handlers/pki.rs +++ b/control-plane/registry/src/handlers/pki.rs @@ -193,14 +193,11 @@ pub async fn get_agent_endpoint( ) })?; - let public_key_pem = crate::db::certificates::get_active_certificate( - &state.db, - agent_id, - ) - .await - .ok() - .flatten() - .map(|c| c.public_key_pem); + let public_key_pem = crate::db::certificates::get_active_certificate(&state.db, agent_id) + .await + .ok() + .flatten() + .map(|c| c.public_key_pem); Ok(Json(AgentEndpointResponse { agent_id, diff --git a/control-plane/registry/src/logger.rs b/control-plane/registry/src/logger.rs index 8d9f9d62..727fe564 100644 --- a/control-plane/registry/src/logger.rs +++ b/control-plane/registry/src/logger.rs @@ -58,9 +58,7 @@ pub fn init_logger_with_service(service_name: &'static str) { let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); let fmt_layer = fmt::layer().with_target(false).with_thread_ids(true); - let registry = tracing_subscriber::registry() - .with(filter) - .with(fmt_layer); + let registry = tracing_subscriber::registry().with(filter).with(fmt_layer); match build_otlp_provider(service_name) { Some(provider) => { @@ -79,11 +77,21 @@ pub fn log_message(level: LogLevel, module: &str, location: &str, description: & let lvl: Level = level.into(); match lvl { - Level::ERROR => event!(Level::ERROR, module = %module, location = %location, "{}", description), - Level::WARN => event!(Level::WARN, module = %module, location = %location, "{}", description), - Level::INFO => event!(Level::INFO, module = %module, location = %location, "{}", description), - Level::DEBUG => event!(Level::DEBUG, module = %module, location = %location, "{}", description), - Level::TRACE => event!(Level::TRACE, module = %module, location = %location, "{}", description), + Level::ERROR => { + event!(Level::ERROR, module = %module, location = %location, "{}", description) + } + Level::WARN => { + event!(Level::WARN, module = %module, location = %location, "{}", description) + } + Level::INFO => { + event!(Level::INFO, module = %module, location = %location, "{}", description) + } + Level::DEBUG => { + event!(Level::DEBUG, module = %module, location = %location, "{}", description) + } + Level::TRACE => { + event!(Level::TRACE, module = %module, location = %location, "{}", description) + } } } diff --git a/control-plane/registry/src/main.rs b/control-plane/registry/src/main.rs index bf52921e..4b341cd4 100644 --- a/control-plane/registry/src/main.rs +++ b/control-plane/registry/src/main.rs @@ -11,6 +11,10 @@ mod services; #[tokio::main] async fn main() -> anyhow::Result<()> { + rustls::crypto::ring::default_provider() + .install_default() + .expect("failed to install ring crypto provider"); + dotenvy::dotenv().ok(); logger::init_logger(); diff --git a/control-plane/registry/src/metrics.rs b/control-plane/registry/src/metrics.rs index 64d068b0..aa5a9792 100644 --- a/control-plane/registry/src/metrics.rs +++ b/control-plane/registry/src/metrics.rs @@ -1,5 +1,7 @@ use axum::response::IntoResponse; -use prometheus::{register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder}; +use prometheus::{ + register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder, +}; use std::sync::OnceLock; static HTTP_REQUESTS_TOTAL: OnceLock = OnceLock::new(); @@ -46,7 +48,10 @@ pub async fn metrics_handler() -> impl IntoResponse { .encode(&metric_families, &mut buffer) .expect("failed to encode metrics"); ( - [(axum::http::header::CONTENT_TYPE, "text/plain; version=0.0.4")], + [( + axum::http::header::CONTENT_TYPE, + "text/plain; version=0.0.4", + )], buffer, ) } diff --git a/control-plane/registry/src/server.rs b/control-plane/registry/src/server.rs index a84966b9..be89018d 100644 --- a/control-plane/registry/src/server.rs +++ b/control-plane/registry/src/server.rs @@ -12,11 +12,8 @@ use crate::{ handlers::{admin, agent, pki}, metrics, services::{ - api_keys::ApiKeyManager, - bootstrap_tokens::BootstrapTokenManager, - pki::PkiService, - registry::AgentRegistry, - tokens::TokenManager, + api_keys::ApiKeyManager, bootstrap_tokens::BootstrapTokenManager, pki::PkiService, + registry::AgentRegistry, tokens::TokenManager, }, }; @@ -42,42 +39,46 @@ pub fn create_router(state: AppState) -> Router { Router::new() .route("/health", get(health_check)) .route("/metrics", get(metrics::metrics_handler)) - // Admin — agent lifecycle - .route("/admin/agents/pre-register", post(admin::pre_register_agent)) + .route( + "/admin/agents/pre-register", + post(admin::pre_register_agent), + ) .route("/admin/agents/pending", get(admin::list_pending_agents)) .route( - "/admin/agents/pending/:agent_id", + "/admin/agents/pending/{agent_id}", delete(admin::delete_pending_agent), ) .route("/admin/tokens", get(admin::list_tokens)) - .route("/admin/bootstrap-tokens", post(admin::create_bootstrap_token)) + .route( + "/admin/bootstrap-tokens", + post(admin::create_bootstrap_token), + ) .route("/admin/bootstrap-tokens", get(admin::list_bootstrap_tokens)) - .route("/admin/bootstrap-tokens/:id/revoke", post(admin::revoke_bootstrap_token)) + .route( + "/admin/bootstrap-tokens/{id}/revoke", + post(admin::revoke_bootstrap_token), + ) .route("/admin/agents", get(admin::list_agents)) - .route("/admin/agents/:agent_id", get(admin::get_agent)) - .route("/admin/agents/:agent_id", delete(admin::deregister_agent)) + .route("/admin/agents/{agent_id}", get(admin::get_agent)) + .route("/admin/agents/{agent_id}", delete(admin::deregister_agent)) .route("/admin/statistics", get(admin::get_statistics)) - // Admin — PKI .route( - "/admin/agents/:agent_id/revoke", + "/admin/agents/{agent_id}/revoke", post(pki::revoke_certificate), ) .route( - "/admin/agents/:agent_id/endpoint", + "/admin/agents/{agent_id}/endpoint", get(pki::get_agent_endpoint), ) - // Public PKI .route("/pki/crl", get(pki::get_crl)) - // Agent — registration + heartbeat .route("/agents/register", post(agent::register_agent)) - .route("/agents/:agent_id/heartbeat", post(agent::heartbeat)) - // Agent — certificate management + .route("/agents/{agent_id}/heartbeat", post(agent::heartbeat)) .route( - "/agents/:agent_id/certificate", + "/agents/{agent_id}/certificate", post(pki::issue_certificate), ) .route( - "/agents/:agent_id/rotate-certificate", + "/agents/{agent_id}/rotate-certificate", post(pki::rotate_certificate), ) .with_state(state) diff --git a/control-plane/registry/src/services/registry.rs b/control-plane/registry/src/services/registry.rs index fe2b01a8..3df0ec69 100644 --- a/control-plane/registry/src/services/registry.rs +++ b/control-plane/registry/src/services/registry.rs @@ -156,7 +156,9 @@ impl AgentRegistry { agent_version: db_agent.agent_version, status: AgentStatus::Online, registered_at: db_agent.registered_at.and_utc(), - last_heartbeat: db_agent.last_heartbeat.map(|dt: NaiveDateTime| dt.and_utc()), + last_heartbeat: db_agent + .last_heartbeat + .map(|dt: NaiveDateTime| dt.and_utc()), tags: params.tags, }; @@ -198,7 +200,9 @@ impl AgentRegistry { agent_version: db_agent.agent_version, status: AgentStatus::Online, registered_at: db_agent.registered_at.and_utc(), - last_heartbeat: db_agent.last_heartbeat.map(|dt: NaiveDateTime| dt.and_utc()), + last_heartbeat: db_agent + .last_heartbeat + .map(|dt: NaiveDateTime| dt.and_utc()), tags: params.tags, }; @@ -231,7 +235,9 @@ impl AgentRegistry { agent_version: db_agent.agent_version, status: AgentStatus::from_str(&db_agent.status), registered_at: db_agent.registered_at.and_utc(), - last_heartbeat: db_agent.last_heartbeat.map(|dt: NaiveDateTime| dt.and_utc()), + last_heartbeat: db_agent + .last_heartbeat + .map(|dt: NaiveDateTime| dt.and_utc()), tags: None, }), _ => None, @@ -253,15 +259,14 @@ impl AgentRegistry { agent_version: db_agent.agent_version, status: AgentStatus::from_str(&db_agent.status), registered_at: db_agent.registered_at.and_utc(), - last_heartbeat: db_agent.last_heartbeat.map(|dt: NaiveDateTime| dt.and_utc()), + last_heartbeat: db_agent + .last_heartbeat + .map(|dt: NaiveDateTime| dt.and_utc()), tags: None, }) .collect(), Err(e) => { - crate::log_error!( - "agent_registry", - &format!("Failed to list agents: {}", e) - ); + crate::log_error!("agent_registry", &format!("Failed to list agents: {}", e)); vec![] } } @@ -281,7 +286,9 @@ impl AgentRegistry { } pub async fn check_agent_health(&self, degraded_seconds: i64, offline_seconds: i64) -> usize { - if let Err(e) = crate::db::agents::mark_degraded_by_timeout(&self.db, degraded_seconds).await { + if let Err(e) = + crate::db::agents::mark_degraded_by_timeout(&self.db, degraded_seconds).await + { crate::log_error!("agent_registry", &format!("Failed to mark degraded: {}", e)); } match crate::db::agents::mark_offline_by_timeout(&self.db, offline_seconds).await { diff --git a/control-plane/registry/src/services/tokens.rs b/control-plane/registry/src/services/tokens.rs index 2ad22752..ea89e61b 100644 --- a/control-plane/registry/src/services/tokens.rs +++ b/control-plane/registry/src/services/tokens.rs @@ -177,10 +177,7 @@ impl TokenManager { }) .collect(), Err(e) => { - crate::log_error!( - "token_manager", - &format!("Failed to list tokens: {}", e) - ); + crate::log_error!("token_manager", &format!("Failed to list tokens: {}", e)); vec![] } } diff --git a/control-plane/scheduler/src/db/agents.rs b/control-plane/scheduler/src/db/agents.rs index f449a5a7..fba9b0f7 100644 --- a/control-plane/scheduler/src/db/agents.rs +++ b/control-plane/scheduler/src/db/agents.rs @@ -4,7 +4,6 @@ use uuid::Uuid; use crate::models::workload::AgentResources; - const TOTAL_CPU_MILLICORES: i32 = 4000; const TOTAL_MEMORY_BYTES: i64 = 8 * 1024 * 1024 * 1024; const TOTAL_DISK_BYTES: i64 = 100 * 1024 * 1024 * 1024; @@ -68,6 +67,5 @@ pub async fn get_assigned_workload_resources( let mem: i64 = workloads.iter().map(|w| w.memory_bytes).sum(); let disk: i64 = workloads.iter().map(|w| w.disk_bytes).sum(); - Ok((cpu, mem, disk)) } diff --git a/control-plane/scheduler/src/db/workloads.rs b/control-plane/scheduler/src/db/workloads.rs index edc6f0f3..9b8c6218 100644 --- a/control-plane/scheduler/src/db/workloads.rs +++ b/control-plane/scheduler/src/db/workloads.rs @@ -1,8 +1,6 @@ use chrono::Utc; use entity::entities::workloads; -use sea_orm::{ - ActiveModelTrait, ActiveValue::Set, DatabaseConnection, EntityTrait, ModelTrait, -}; +use sea_orm::{ActiveModelTrait, ActiveValue::Set, DatabaseConnection, EntityTrait, ModelTrait}; use uuid::Uuid; use crate::models::workload::{CreateWorkloadRequest, WorkloadResponse, WorkloadStatus}; @@ -84,10 +82,7 @@ pub async fn update_container_status( Ok(()) } -pub async fn delete( - db: &DatabaseConnection, - workload_id: Uuid, -) -> Result<(), sea_orm::DbErr> { +pub async fn delete(db: &DatabaseConnection, workload_id: Uuid) -> Result<(), sea_orm::DbErr> { let workload = workloads::Entity::find_by_id(workload_id) .one(db) .await? diff --git a/control-plane/scheduler/src/handlers/internal.rs b/control-plane/scheduler/src/handlers/internal.rs index 3e44cfc0..cc852032 100644 --- a/control-plane/scheduler/src/handlers/internal.rs +++ b/control-plane/scheduler/src/handlers/internal.rs @@ -1,9 +1,4 @@ -use axum::{ - extract::State, - http::StatusCode, - response::IntoResponse, - Json, -}; +use axum::{extract::State, http::StatusCode, response::IntoResponse, Json}; use serde::Deserialize; use uuid::Uuid; diff --git a/control-plane/scheduler/src/logger.rs b/control-plane/scheduler/src/logger.rs index 8d9f9d62..727fe564 100644 --- a/control-plane/scheduler/src/logger.rs +++ b/control-plane/scheduler/src/logger.rs @@ -58,9 +58,7 @@ pub fn init_logger_with_service(service_name: &'static str) { let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); let fmt_layer = fmt::layer().with_target(false).with_thread_ids(true); - let registry = tracing_subscriber::registry() - .with(filter) - .with(fmt_layer); + let registry = tracing_subscriber::registry().with(filter).with(fmt_layer); match build_otlp_provider(service_name) { Some(provider) => { @@ -79,11 +77,21 @@ pub fn log_message(level: LogLevel, module: &str, location: &str, description: & let lvl: Level = level.into(); match lvl { - Level::ERROR => event!(Level::ERROR, module = %module, location = %location, "{}", description), - Level::WARN => event!(Level::WARN, module = %module, location = %location, "{}", description), - Level::INFO => event!(Level::INFO, module = %module, location = %location, "{}", description), - Level::DEBUG => event!(Level::DEBUG, module = %module, location = %location, "{}", description), - Level::TRACE => event!(Level::TRACE, module = %module, location = %location, "{}", description), + Level::ERROR => { + event!(Level::ERROR, module = %module, location = %location, "{}", description) + } + Level::WARN => { + event!(Level::WARN, module = %module, location = %location, "{}", description) + } + Level::INFO => { + event!(Level::INFO, module = %module, location = %location, "{}", description) + } + Level::DEBUG => { + event!(Level::DEBUG, module = %module, location = %location, "{}", description) + } + Level::TRACE => { + event!(Level::TRACE, module = %module, location = %location, "{}", description) + } } } diff --git a/control-plane/scheduler/src/metrics.rs b/control-plane/scheduler/src/metrics.rs index 64d068b0..aa5a9792 100644 --- a/control-plane/scheduler/src/metrics.rs +++ b/control-plane/scheduler/src/metrics.rs @@ -1,5 +1,7 @@ use axum::response::IntoResponse; -use prometheus::{register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder}; +use prometheus::{ + register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder, +}; use std::sync::OnceLock; static HTTP_REQUESTS_TOTAL: OnceLock = OnceLock::new(); @@ -46,7 +48,10 @@ pub async fn metrics_handler() -> impl IntoResponse { .encode(&metric_families, &mut buffer) .expect("failed to encode metrics"); ( - [(axum::http::header::CONTENT_TYPE, "text/plain; version=0.0.4")], + [( + axum::http::header::CONTENT_TYPE, + "text/plain; version=0.0.4", + )], buffer, ) } diff --git a/control-plane/scheduler/src/server.rs b/control-plane/scheduler/src/server.rs index 6accf762..0b85206e 100644 --- a/control-plane/scheduler/src/server.rs +++ b/control-plane/scheduler/src/server.rs @@ -4,7 +4,11 @@ use sea_orm::DatabaseConnection; use std::sync::Arc; use tokio::sync::Mutex; -use crate::{handlers::{internal, workloads}, metrics, services::scheduler::SchedulerService}; +use crate::{ + handlers::{internal, workloads}, + metrics, + services::scheduler::SchedulerService, +}; #[derive(Clone)] pub struct AppState { @@ -21,9 +25,18 @@ pub fn create_router(state: AppState) -> Router { Router::new() .route("/health", get(health_check)) .route("/metrics", get(metrics::metrics_handler)) - .route("/workloads", axum::routing::post(workloads::create_workload)) + .route( + "/workloads", + axum::routing::post(workloads::create_workload), + ) .route("/workloads", get(workloads::list_workloads)) - .route("/workloads/:id", axum::routing::delete(workloads::delete_workload)) - .route("/internal/workloads/status", axum::routing::post(internal::update_container_statuses)) + .route( + "/workloads/{id}", + axum::routing::delete(workloads::delete_workload), + ) + .route( + "/internal/workloads/status", + axum::routing::post(internal::update_container_statuses), + ) .with_state(state) } diff --git a/control-plane/scheduler/src/services/etcd.rs b/control-plane/scheduler/src/services/etcd.rs index 18db45fb..ec826a65 100644 --- a/control-plane/scheduler/src/services/etcd.rs +++ b/control-plane/scheduler/src/services/etcd.rs @@ -1,7 +1,7 @@ use etcd_client::Client; use serde::{Deserialize, Serialize}; -use tokio::sync::Mutex; use std::sync::Arc; +use tokio::sync::Mutex; use uuid::Uuid; #[derive(Debug, Clone, Serialize, Deserialize)] @@ -32,10 +32,7 @@ pub async fn put_placement( Ok(()) } -pub async fn delete_placement( - etcd: &Arc>, - workload_id: Uuid, -) -> Result<(), String> { +pub async fn delete_placement(etcd: &Arc>, workload_id: Uuid) -> Result<(), String> { let key = format!("/csfx/placements/{}", workload_id); etcd.lock() diff --git a/control-plane/scheduler/src/services/scheduler.rs b/control-plane/scheduler/src/services/scheduler.rs index 1b196624..1835c5fe 100644 --- a/control-plane/scheduler/src/services/scheduler.rs +++ b/control-plane/scheduler/src/services/scheduler.rs @@ -5,7 +5,9 @@ use std::sync::Arc; use tokio::sync::Mutex; use uuid::Uuid; -use crate::models::workload::{AgentResources, CreateWorkloadRequest, CreateWorkloadResponse, WorkloadStatus}; +use crate::models::workload::{ + AgentResources, CreateWorkloadRequest, CreateWorkloadResponse, WorkloadStatus, +}; use crate::services::etcd::{delete_placement, put_placement, PlacementRecord}; pub struct SchedulerService { @@ -18,7 +20,10 @@ impl SchedulerService { Self { db, etcd } } - pub async fn schedule(&self, req: CreateWorkloadRequest) -> Result { + pub async fn schedule( + &self, + req: CreateWorkloadRequest, + ) -> Result { let workload = crate::db::workloads::create(&self.db, &req) .await .map_err(|e| format!("Failed to persist workload: {}", e))?; @@ -120,7 +125,10 @@ impl SchedulerService { delete_placement(&self.etcd, workload_id).await?; - crate::log_info!("scheduler", &format!("Workload deleted workload_id={}", workload_id)); + crate::log_info!( + "scheduler", + &format!("Workload deleted workload_id={}", workload_id) + ); Ok(()) } diff --git a/control-plane/sdn-controller/Cargo.toml b/control-plane/sdn-controller/Cargo.toml index 0b83ea6a..913e7a62 100644 --- a/control-plane/sdn-controller/Cargo.toml +++ b/control-plane/sdn-controller/Cargo.toml @@ -27,6 +27,8 @@ chrono = { workspace = true, features = ["serde"] } sea-orm = { workspace = true } etcd-client = { workspace = true } reqwest = { workspace = true, features = ["json"] } +ring = { workspace = true } +rustls = { workspace = true } prometheus = { workspace = true } opentelemetry = { workspace = true } opentelemetry_sdk = { workspace = true } diff --git a/control-plane/sdn-controller/src/db/networks.rs b/control-plane/sdn-controller/src/db/networks.rs index 722d9f9c..78cee66e 100644 --- a/control-plane/sdn-controller/src/db/networks.rs +++ b/control-plane/sdn-controller/src/db/networks.rs @@ -2,8 +2,7 @@ use anyhow::{Context, Result}; use chrono::Utc; use entity::entities::{network_members, network_policies, networks}; use sea_orm::{ - ActiveModelTrait, ActiveValue::Set, ColumnTrait, DatabaseConnection, EntityTrait, - QueryFilter, + ActiveModelTrait, ActiveValue::Set, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, }; use uuid::Uuid; @@ -24,10 +23,7 @@ pub async fn create_network( updated_at: Set(None), }; - model - .insert(db) - .await - .context("Failed to insert network") + model.insert(db).await.context("Failed to insert network") } pub async fn list_networks(db: &DatabaseConnection) -> Result> { diff --git a/control-plane/sdn-controller/src/handlers/networks.rs b/control-plane/sdn-controller/src/handlers/networks.rs index f799f6e3..e4c55176 100644 --- a/control-plane/sdn-controller/src/handlers/networks.rs +++ b/control-plane/sdn-controller/src/handlers/networks.rs @@ -20,7 +20,10 @@ pub async fn create_network( Ok(network) => Ok((StatusCode::CREATED, Json(json!(network)))), Err(e) => { tracing::error!(error = %e, "Failed to create network"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -32,7 +35,10 @@ pub async fn list_networks( Ok(networks) => Ok(Json(json!(networks))), Err(e) => { tracing::error!(error = %e, "Failed to list networks"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -43,10 +49,16 @@ pub async fn get_network( ) -> Result)> { match db::get_network(&state.db, id).await { Ok(Some(network)) => Ok(Json(json!(network))), - Ok(None) => Err((StatusCode::NOT_FOUND, Json(json!({"error": "Network not found"})))), + Ok(None) => Err(( + StatusCode::NOT_FOUND, + Json(json!({"error": "Network not found"})), + )), Err(e) => { tracing::error!(error = %e, "Failed to get network"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -59,7 +71,10 @@ pub async fn delete_network( Ok(_) => Ok(StatusCode::NO_CONTENT), Err(e) => { tracing::error!(error = %e, "Failed to delete network"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -73,7 +88,10 @@ pub async fn create_policy( Ok(policy) => Ok((StatusCode::CREATED, Json(json!(policy)))), Err(e) => { tracing::error!(error = %e, "Failed to create policy"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -86,7 +104,10 @@ pub async fn list_policies( Ok(policies) => Ok(Json(json!(policies))), Err(e) => { tracing::error!(error = %e, "Failed to list policies"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -98,11 +119,25 @@ pub async fn add_member( ) -> Result)> { let network = match db::get_network(&state.db, network_id).await { Ok(Some(n)) => n, - Ok(None) => return Err((StatusCode::NOT_FOUND, Json(json!({"error": "Network not found"})))), - Err(e) => return Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))), + Ok(None) => { + return Err(( + StatusCode::NOT_FOUND, + Json(json!({"error": "Network not found"})), + )) + } + Err(e) => { + return Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) + } }; - let allocated_ip = match state.ipam.allocate(network_id, &network.cidr, req.workload_id).await { + let allocated_ip = match state + .ipam + .allocate(network_id, &network.cidr, req.workload_id) + .await + { Ok(ip) => ip, Err(e) => { tracing::error!(error = %e, "IPAM allocation failed"); @@ -114,7 +149,10 @@ pub async fn add_member( Ok(member) => Ok((StatusCode::CREATED, Json(json!(member)))), Err(e) => { tracing::error!(error = %e, "Failed to add network member"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -127,7 +165,10 @@ pub async fn list_members( Ok(members) => Ok(Json(json!(members))), Err(e) => { tracing::error!(error = %e, "Failed to list network members"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } @@ -136,7 +177,9 @@ pub async fn remove_member( State(mut state): State, Path((network_id, workload_id)): Path<(Uuid, Uuid)>, ) -> Result)> { - let members = db::list_members(&state.db, network_id).await.unwrap_or_default(); + let members = db::list_members(&state.db, network_id) + .await + .unwrap_or_default(); let ip = members .iter() .find(|m| m.workload_id == workload_id) @@ -150,7 +193,10 @@ pub async fn remove_member( Ok(_) => Ok(StatusCode::NO_CONTENT), Err(e) => { tracing::error!(error = %e, "Failed to remove network member"); - Err((StatusCode::INTERNAL_SERVER_ERROR, Json(json!({"error": e.to_string()})))) + Err(( + StatusCode::INTERNAL_SERVER_ERROR, + Json(json!({"error": e.to_string()})), + )) } } } diff --git a/control-plane/sdn-controller/src/logger.rs b/control-plane/sdn-controller/src/logger.rs index 8d9f9d62..727fe564 100644 --- a/control-plane/sdn-controller/src/logger.rs +++ b/control-plane/sdn-controller/src/logger.rs @@ -58,9 +58,7 @@ pub fn init_logger_with_service(service_name: &'static str) { let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); let fmt_layer = fmt::layer().with_target(false).with_thread_ids(true); - let registry = tracing_subscriber::registry() - .with(filter) - .with(fmt_layer); + let registry = tracing_subscriber::registry().with(filter).with(fmt_layer); match build_otlp_provider(service_name) { Some(provider) => { @@ -79,11 +77,21 @@ pub fn log_message(level: LogLevel, module: &str, location: &str, description: & let lvl: Level = level.into(); match lvl { - Level::ERROR => event!(Level::ERROR, module = %module, location = %location, "{}", description), - Level::WARN => event!(Level::WARN, module = %module, location = %location, "{}", description), - Level::INFO => event!(Level::INFO, module = %module, location = %location, "{}", description), - Level::DEBUG => event!(Level::DEBUG, module = %module, location = %location, "{}", description), - Level::TRACE => event!(Level::TRACE, module = %module, location = %location, "{}", description), + Level::ERROR => { + event!(Level::ERROR, module = %module, location = %location, "{}", description) + } + Level::WARN => { + event!(Level::WARN, module = %module, location = %location, "{}", description) + } + Level::INFO => { + event!(Level::INFO, module = %module, location = %location, "{}", description) + } + Level::DEBUG => { + event!(Level::DEBUG, module = %module, location = %location, "{}", description) + } + Level::TRACE => { + event!(Level::TRACE, module = %module, location = %location, "{}", description) + } } } diff --git a/control-plane/sdn-controller/src/main.rs b/control-plane/sdn-controller/src/main.rs index 6aad76f2..5d127850 100644 --- a/control-plane/sdn-controller/src/main.rs +++ b/control-plane/sdn-controller/src/main.rs @@ -10,6 +10,10 @@ mod services; #[tokio::main] async fn main() -> anyhow::Result<()> { + rustls::crypto::ring::default_provider() + .install_default() + .expect("failed to install ring crypto provider"); + dotenvy::dotenv().ok(); logger::init_logger(); diff --git a/control-plane/sdn-controller/src/metrics.rs b/control-plane/sdn-controller/src/metrics.rs index 64d068b0..aa5a9792 100644 --- a/control-plane/sdn-controller/src/metrics.rs +++ b/control-plane/sdn-controller/src/metrics.rs @@ -1,5 +1,7 @@ use axum::response::IntoResponse; -use prometheus::{register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder}; +use prometheus::{ + register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder, +}; use std::sync::OnceLock; static HTTP_REQUESTS_TOTAL: OnceLock = OnceLock::new(); @@ -46,7 +48,10 @@ pub async fn metrics_handler() -> impl IntoResponse { .encode(&metric_families, &mut buffer) .expect("failed to encode metrics"); ( - [(axum::http::header::CONTENT_TYPE, "text/plain; version=0.0.4")], + [( + axum::http::header::CONTENT_TYPE, + "text/plain; version=0.0.4", + )], buffer, ) } diff --git a/control-plane/sdn-controller/src/server.rs b/control-plane/sdn-controller/src/server.rs index 86166c32..2cecaeb3 100644 --- a/control-plane/sdn-controller/src/server.rs +++ b/control-plane/sdn-controller/src/server.rs @@ -1,11 +1,7 @@ use axum::{http::StatusCode, response::IntoResponse, routing::get, Router}; use sea_orm::DatabaseConnection; -use crate::{ - handlers::networks, - metrics, - services::ipam::IpamService, -}; +use crate::{handlers::networks, metrics, services::ipam::IpamService}; #[derive(Clone)] pub struct AppState { @@ -27,21 +23,24 @@ pub fn create_router(state: AppState) -> Router { Router::new() .route("/health", get(health_check)) .route("/metrics", get(metrics::metrics_handler)) - .route("/networks", get(networks::list_networks).post(networks::create_network)) .route( - "/networks/:id", + "/networks", + get(networks::list_networks).post(networks::create_network), + ) + .route( + "/networks/{id}", get(networks::get_network).delete(networks::delete_network), ) .route( - "/networks/:id/policies", + "/networks/{id}/policies", get(networks::list_policies).post(networks::create_policy), ) .route( - "/networks/:id/members", + "/networks/{id}/members", get(networks::list_members).post(networks::add_member), ) .route( - "/networks/:id/members/:workload_id", + "/networks/{id}/members/{workload_id}", axum::routing::delete(networks::remove_member), ) .with_state(state) diff --git a/control-plane/sdn-controller/src/services/ipam.rs b/control-plane/sdn-controller/src/services/ipam.rs index f1753bc7..bc9c875d 100644 --- a/control-plane/sdn-controller/src/services/ipam.rs +++ b/control-plane/sdn-controller/src/services/ipam.rs @@ -15,7 +15,12 @@ impl IpamService { Self { etcd } } - pub async fn allocate(&mut self, network_id: Uuid, cidr: &str, workload_id: Uuid) -> Result { + pub async fn allocate( + &mut self, + network_id: Uuid, + cidr: &str, + workload_id: Uuid, + ) -> Result { let (base, prefix_len) = parse_cidr(cidr)?; let total = 1u32 << (32 - prefix_len); @@ -60,7 +65,11 @@ impl IpamService { ) -> Result<()> { let base_key = format!("/csfx/peers/{}/{}", network_id, node_id); self.etcd - .put(format!("{}/overlay_ip", base_key).as_str(), overlay_ip, None) + .put( + format!("{}/overlay_ip", base_key).as_str(), + overlay_ip, + None, + ) .await .context("etcd put overlay_ip failed")?; diff --git a/control-plane/shared/entity/src/entities/mod.rs b/control-plane/shared/entity/src/entities/mod.rs index c002d753..d3ea77fd 100644 --- a/control-plane/shared/entity/src/entities/mod.rs +++ b/control-plane/shared/entity/src/entities/mod.rs @@ -1,13 +1,16 @@ pub mod agent_api_keys; -pub mod bootstrap_tokens; -pub mod failover_events; pub mod agent_certificates; pub mod agent_metrics; pub mod agents; +pub mod bootstrap_tokens; pub mod certificate_revocations; pub mod config; +pub mod failover_events; pub mod invalid_jwt; pub mod key; +pub mod network_members; +pub mod network_policies; +pub mod networks; pub mod organization; pub mod permission; pub mod registry_tokens; @@ -15,24 +18,24 @@ pub mod role; pub mod role_permission; pub mod user; pub mod user_organization; -pub mod network_members; -pub mod network_policies; -pub mod networks; +pub mod user_ssh_keys; pub mod volume_snapshots; pub mod volumes; -pub mod user_ssh_keys; pub mod workloads; pub use agent_api_keys::Entity as AgentApiKeys; -pub use bootstrap_tokens::Entity as BootstrapTokens; -pub use failover_events::Entity as FailoverEvents; pub use agent_certificates::Entity as AgentCertificates; pub use agent_metrics::Entity as AgentMetrics; pub use agents::Entity as Agents; +pub use bootstrap_tokens::Entity as BootstrapTokens; pub use certificate_revocations::Entity as CertificateRevocations; pub use config::Entity as Config; +pub use failover_events::Entity as FailoverEvents; pub use invalid_jwt::Entity as InvalidJwt; pub use key::Entity as Key; +pub use network_members::Entity as NetworkMembers; +pub use network_policies::Entity as NetworkPolicies; +pub use networks::Entity as Networks; pub use organization::Entity as Organization; pub use permission::Entity as Permission; pub use registry_tokens::Entity as RegistryTokens; @@ -40,10 +43,7 @@ pub use role::Entity as Role; pub use role_permission::Entity as RolePermission; pub use user::Entity as User; pub use user_organization::Entity as UserOrganization; -pub use network_members::Entity as NetworkMembers; -pub use network_policies::Entity as NetworkPolicies; -pub use networks::Entity as Networks; +pub use user_ssh_keys::Entity as UserSshKeys; pub use volume_snapshots::Entity as VolumeSnapshots; pub use volumes::Entity as Volumes; -pub use user_ssh_keys::Entity as UserSshKeys; pub use workloads::Entity as Workloads; diff --git a/control-plane/shared/migration/src/m20260304_000000_pki_certificates.rs b/control-plane/shared/migration/src/m20260304_000000_pki_certificates.rs index 00e6a5e3..322004a9 100644 --- a/control-plane/shared/migration/src/m20260304_000000_pki_certificates.rs +++ b/control-plane/shared/migration/src/m20260304_000000_pki_certificates.rs @@ -114,7 +114,11 @@ impl MigrationTrait for Migration { .await?; manager - .drop_table(Table::drop().table(CertificateRevocations::Table).to_owned()) + .drop_table( + Table::drop() + .table(CertificateRevocations::Table) + .to_owned(), + ) .await?; manager diff --git a/control-plane/shared/migration/src/m20260309_000000_add_bootstrap_tokens.rs b/control-plane/shared/migration/src/m20260309_000000_add_bootstrap_tokens.rs index 0c695eb5..2d689321 100644 --- a/control-plane/shared/migration/src/m20260309_000000_add_bootstrap_tokens.rs +++ b/control-plane/shared/migration/src/m20260309_000000_add_bootstrap_tokens.rs @@ -11,16 +11,56 @@ impl MigrationTrait for Migration { Table::create() .table(BootstrapTokens::Table) .if_not_exists() - .col(ColumnDef::new(BootstrapTokens::Id).uuid().not_null().primary_key()) - .col(ColumnDef::new(BootstrapTokens::Token).string().not_null().unique_key()) + .col( + ColumnDef::new(BootstrapTokens::Id) + .uuid() + .not_null() + .primary_key(), + ) + .col( + ColumnDef::new(BootstrapTokens::Token) + .string() + .not_null() + .unique_key(), + ) .col(ColumnDef::new(BootstrapTokens::Description).string().null()) - .col(ColumnDef::new(BootstrapTokens::CreatedBy).string().not_null()) - .col(ColumnDef::new(BootstrapTokens::CreatedAt).date_time().not_null()) - .col(ColumnDef::new(BootstrapTokens::ExpiresAt).date_time().not_null()) - .col(ColumnDef::new(BootstrapTokens::MaxUses).integer().not_null()) - .col(ColumnDef::new(BootstrapTokens::UseCount).integer().not_null().default(0)) - .col(ColumnDef::new(BootstrapTokens::Revoked).boolean().not_null().default(false)) - .col(ColumnDef::new(BootstrapTokens::RevokedAt).date_time().null()) + .col( + ColumnDef::new(BootstrapTokens::CreatedBy) + .string() + .not_null(), + ) + .col( + ColumnDef::new(BootstrapTokens::CreatedAt) + .date_time() + .not_null(), + ) + .col( + ColumnDef::new(BootstrapTokens::ExpiresAt) + .date_time() + .not_null(), + ) + .col( + ColumnDef::new(BootstrapTokens::MaxUses) + .integer() + .not_null(), + ) + .col( + ColumnDef::new(BootstrapTokens::UseCount) + .integer() + .not_null() + .default(0), + ) + .col( + ColumnDef::new(BootstrapTokens::Revoked) + .boolean() + .not_null() + .default(false), + ) + .col( + ColumnDef::new(BootstrapTokens::RevokedAt) + .date_time() + .null(), + ) .to_owned(), ) .await diff --git a/control-plane/shared/migration/src/m20260523_000000_add_ssh_keys.rs b/control-plane/shared/migration/src/m20260523_000000_add_ssh_keys.rs index 3ded61f5..f24b5d3a 100644 --- a/control-plane/shared/migration/src/m20260523_000000_add_ssh_keys.rs +++ b/control-plane/shared/migration/src/m20260523_000000_add_ssh_keys.rs @@ -11,7 +11,12 @@ impl MigrationTrait for Migration { Table::create() .table(UserSshKeys::Table) .if_not_exists() - .col(ColumnDef::new(UserSshKeys::Id).uuid().not_null().primary_key()) + .col( + ColumnDef::new(UserSshKeys::Id) + .uuid() + .not_null() + .primary_key(), + ) .col(ColumnDef::new(UserSshKeys::UserId).uuid().not_null()) .col(ColumnDef::new(UserSshKeys::Name).string().not_null()) .col(ColumnDef::new(UserSshKeys::PublicKey).text().not_null()) @@ -21,11 +26,7 @@ impl MigrationTrait for Migration { .timestamp() .not_null(), ) - .col( - ColumnDef::new(UserSshKeys::ExpiresAt) - .timestamp() - .null(), - ) + .col(ColumnDef::new(UserSshKeys::ExpiresAt).timestamp().null()) .to_owned(), ) .await diff --git a/control-plane/volume-manager/Cargo.toml b/control-plane/volume-manager/Cargo.toml index b42e49d8..4f6eaf05 100644 --- a/control-plane/volume-manager/Cargo.toml +++ b/control-plane/volume-manager/Cargo.toml @@ -35,7 +35,9 @@ serde = { workspace = true } serde_json = { workspace = true } # HTTP Client for Patroni -reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-tls"] } +reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-no-provider", "webpki-roots"] } +ring = { workspace = true } +rustls = { workspace = true } # Utilities dotenvy = { workspace = true } diff --git a/control-plane/volume-manager/src/ceph/storage/pool.rs b/control-plane/volume-manager/src/ceph/storage/pool.rs index 3d558860..01df096a 100644 --- a/control-plane/volume-manager/src/ceph/storage/pool.rs +++ b/control-plane/volume-manager/src/ceph/storage/pool.rs @@ -1,5 +1,5 @@ -use crate::ceph::core::CephClient; use super::types::*; +use crate::ceph::core::CephClient; use anyhow::{Context, Result}; pub struct PoolManager { @@ -26,7 +26,9 @@ impl PoolManager { .arg(pool.pg_num.to_string()) .arg(pool.pgp_num.to_string()); - self.client.execute(cmd).await + self.client + .execute(cmd) + .await .context("Failed to create pool")?; // Replikation setzen @@ -37,7 +39,9 @@ impl PoolManager { .arg("size") .arg(pool.size.to_string()); - self.client.execute(cmd).await + self.client + .execute(cmd) + .await .context("Failed to set pool size")?; // Min size setzen @@ -48,7 +52,9 @@ impl PoolManager { .arg("min_size") .arg(pool.min_size.to_string()); - self.client.execute(cmd).await + self.client + .execute(cmd) + .await .context("Failed to set pool min_size")?; // RBD Pool initialisieren @@ -59,7 +65,9 @@ impl PoolManager { .arg(&pool.name) .arg("rbd"); - self.client.execute(cmd).await + self.client + .execute(cmd) + .await .context("Failed to enable RBD application")?; crate::log_info!( @@ -84,7 +92,9 @@ impl PoolManager { .arg(pool_name) // Bestätigung .arg("--yes-i-really-really-mean-it"); - self.client.execute(cmd).await + self.client + .execute(cmd) + .await .context("Failed to delete pool")?; Ok(()) @@ -93,19 +103,17 @@ impl PoolManager { /// Listet alle Pools auf pub async fn list_pools(&self) -> Result> { crate::log_debug!("pool_manager", "Listing all Ceph pools"); - - let cmd = CephCommand::new("osd") - .arg("pool") - .arg("ls"); + + let cmd = CephCommand::new("osd").arg("pool").arg("ls"); let output = self.client.execute(cmd).await?; let pools: Vec = serde_json::from_str(&output)?; - + crate::log_debug!( "pool_manager", &format!("Found {} pools: {}", pools.len(), pools.join(", ")) ); - + Ok(pools) } diff --git a/control-plane/volume-manager/src/db/volumes.rs b/control-plane/volume-manager/src/db/volumes.rs index 44a3d2a1..7e6921a3 100644 --- a/control-plane/volume-manager/src/db/volumes.rs +++ b/control-plane/volume-manager/src/db/volumes.rs @@ -1,8 +1,8 @@ use chrono::Utc; use entity::entities::{volume_snapshots, volumes}; use sea_orm::{ - ActiveModelTrait, ActiveValue::Set, DatabaseConnection, EntityTrait, ModelTrait, - QueryFilter, ColumnTrait, + ActiveModelTrait, ActiveValue::Set, ColumnTrait, DatabaseConnection, EntityTrait, ModelTrait, + QueryFilter, }; use uuid::Uuid; @@ -14,7 +14,10 @@ pub async fn create( db: &DatabaseConnection, req: &CreateVolumeRequest, ) -> Result { - let pool = req.pool.clone().unwrap_or_else(|| "csfx-volumes".to_string()); + let pool = req + .pool + .clone() + .unwrap_or_else(|| "csfx-volumes".to_string()); let image_name = format!("{}-{}", req.name, Uuid::new_v4()); let model = volumes::ActiveModel { diff --git a/control-plane/volume-manager/src/etcd/ha/health.rs b/control-plane/volume-manager/src/etcd/ha/health.rs index f456dd60..c22c65a3 100644 --- a/control-plane/volume-manager/src/etcd/ha/health.rs +++ b/control-plane/volume-manager/src/etcd/ha/health.rs @@ -40,7 +40,14 @@ impl HealthChecker { let is_healthy = time_since_heartbeat < self.timeout; if !is_healthy { - log_warn!("etcd::ha::health", &format!("Node {} is unhealthy ({}s since last heartbeat)", node.node_id, time_since_heartbeat.as_secs())); + log_warn!( + "etcd::ha::health", + &format!( + "Node {} is unhealthy ({}s since last heartbeat)", + node.node_id, + time_since_heartbeat.as_secs() + ) + ); } NodeHealthStatus { @@ -69,7 +76,10 @@ impl HealthChecker { let healthy = health_statuses.iter().filter(|s| s.is_healthy).count(); let unhealthy = total - healthy; - log_info!("etcd::ha::health", &format!("Cluster Health: {}/{} nodes healthy", healthy, total)); + log_info!( + "etcd::ha::health", + &format!("Cluster Health: {}/{} nodes healthy", healthy, total) + ); ClusterHealthSummary { total_nodes: total, diff --git a/control-plane/volume-manager/src/etcd/state/manager.rs b/control-plane/volume-manager/src/etcd/state/manager.rs index 8cd5cdfc..1b162f32 100644 --- a/control-plane/volume-manager/src/etcd/state/manager.rs +++ b/control-plane/volume-manager/src/etcd/state/manager.rs @@ -26,7 +26,10 @@ impl StateManager { encrypted: bool, ) -> Result { let volume = VolumeState::new(name, size_gb, pool, encrypted); - log_info!("etcd::state::manager", &format!("Creating volume: {} ({})", volume.name, volume.id)); + log_info!( + "etcd::state::manager", + &format!("Creating volume: {} ({})", volume.name, volume.id) + ); self.storage.save_volume(&volume).await?; Ok(volume) } @@ -45,7 +48,10 @@ impl StateManager { volume.update_status(status); self.storage.save_volume(&volume).await?; - log_info!("etcd::state::manager", &format!("Updated volume {} status to {:?}", id, volume.status)); + log_info!( + "etcd::state::manager", + &format!("Updated volume {} status to {:?}", id, volume.status) + ); Ok(()) } @@ -84,7 +90,10 @@ impl StateManager { volumes: Vec::new(), }; - log_info!("etcd::state::manager", &format!("Registering node: {}", node_id)); + log_info!( + "etcd::state::manager", + &format!("Registering node: {}", node_id) + ); self.storage.save_node(&node).await?; Ok(node) } @@ -110,7 +119,10 @@ impl StateManager { .await? .ok_or_else(|| EtcdError::StateOperation(format!("Node {} not found", node_id)))?; - log_warn!("etcd::state::manager", &format!("Marking node {} as offline", node_id)); + log_warn!( + "etcd::state::manager", + &format!("Marking node {} as offline", node_id) + ); node.status = NodeStatus::Offline; self.storage.save_node(&node).await } @@ -125,7 +137,10 @@ impl StateManager { node.role = role; self.storage.save_node(&node).await?; - log_info!("etcd::state::manager", &format!("Set node {} role to {:?}", node_id, node.role)); + log_info!( + "etcd::state::manager", + &format!("Set node {} role to {:?}", node_id, node.role) + ); Ok(()) } @@ -161,7 +176,10 @@ impl StateManager { created_at: chrono::Utc::now(), }; - log_info!("etcd::state::manager", &format!("Creating snapshot: {} for volume {}", name, volume_id)); + log_info!( + "etcd::state::manager", + &format!("Creating snapshot: {} for volume {}", name, volume_id) + ); self.storage.save_snapshot(&snapshot).await?; Ok(snapshot) } diff --git a/control-plane/volume-manager/src/handlers/volumes.rs b/control-plane/volume-manager/src/handlers/volumes.rs index bed3cefc..c6255977 100644 --- a/control-plane/volume-manager/src/handlers/volumes.rs +++ b/control-plane/volume-manager/src/handlers/volumes.rs @@ -34,10 +34,7 @@ pub async fn list_volumes(State(state): State) -> impl IntoResponse { } } -pub async fn get_volume( - State(state): State, - Path(id): Path, -) -> impl IntoResponse { +pub async fn get_volume(State(state): State, Path(id): Path) -> impl IntoResponse { match state.volume_service.get_volume(id).await { Ok(Some(vol)) => (StatusCode::OK, Json(serde_json::json!(vol))).into_response(), Ok(None) => ( diff --git a/control-plane/volume-manager/src/logger.rs b/control-plane/volume-manager/src/logger.rs index 8d9f9d62..727fe564 100644 --- a/control-plane/volume-manager/src/logger.rs +++ b/control-plane/volume-manager/src/logger.rs @@ -58,9 +58,7 @@ pub fn init_logger_with_service(service_name: &'static str) { let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); let fmt_layer = fmt::layer().with_target(false).with_thread_ids(true); - let registry = tracing_subscriber::registry() - .with(filter) - .with(fmt_layer); + let registry = tracing_subscriber::registry().with(filter).with(fmt_layer); match build_otlp_provider(service_name) { Some(provider) => { @@ -79,11 +77,21 @@ pub fn log_message(level: LogLevel, module: &str, location: &str, description: & let lvl: Level = level.into(); match lvl { - Level::ERROR => event!(Level::ERROR, module = %module, location = %location, "{}", description), - Level::WARN => event!(Level::WARN, module = %module, location = %location, "{}", description), - Level::INFO => event!(Level::INFO, module = %module, location = %location, "{}", description), - Level::DEBUG => event!(Level::DEBUG, module = %module, location = %location, "{}", description), - Level::TRACE => event!(Level::TRACE, module = %module, location = %location, "{}", description), + Level::ERROR => { + event!(Level::ERROR, module = %module, location = %location, "{}", description) + } + Level::WARN => { + event!(Level::WARN, module = %module, location = %location, "{}", description) + } + Level::INFO => { + event!(Level::INFO, module = %module, location = %location, "{}", description) + } + Level::DEBUG => { + event!(Level::DEBUG, module = %module, location = %location, "{}", description) + } + Level::TRACE => { + event!(Level::TRACE, module = %module, location = %location, "{}", description) + } } } diff --git a/control-plane/volume-manager/src/main.rs b/control-plane/volume-manager/src/main.rs index 6da6bd59..d380e0df 100644 --- a/control-plane/volume-manager/src/main.rs +++ b/control-plane/volume-manager/src/main.rs @@ -14,6 +14,10 @@ mod services; #[tokio::main] async fn main() -> anyhow::Result<()> { + rustls::crypto::ring::default_provider() + .install_default() + .expect("failed to install ring crypto provider"); + dotenvy::dotenv().ok(); logger::init_logger(); diff --git a/control-plane/volume-manager/src/metrics.rs b/control-plane/volume-manager/src/metrics.rs index 64d068b0..aa5a9792 100644 --- a/control-plane/volume-manager/src/metrics.rs +++ b/control-plane/volume-manager/src/metrics.rs @@ -1,5 +1,7 @@ use axum::response::IntoResponse; -use prometheus::{register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder}; +use prometheus::{ + register_counter_vec, register_histogram_vec, CounterVec, Encoder, HistogramVec, TextEncoder, +}; use std::sync::OnceLock; static HTTP_REQUESTS_TOTAL: OnceLock = OnceLock::new(); @@ -46,7 +48,10 @@ pub async fn metrics_handler() -> impl IntoResponse { .encode(&metric_families, &mut buffer) .expect("failed to encode metrics"); ( - [(axum::http::header::CONTENT_TYPE, "text/plain; version=0.0.4")], + [( + axum::http::header::CONTENT_TYPE, + "text/plain; version=0.0.4", + )], buffer, ) } diff --git a/control-plane/volume-manager/src/server.rs b/control-plane/volume-manager/src/server.rs index f2e06c07..5f2e3cf1 100644 --- a/control-plane/volume-manager/src/server.rs +++ b/control-plane/volume-manager/src/server.rs @@ -23,11 +23,23 @@ pub fn create_router(state: AppState) -> Router { .route("/metrics", get(metrics::metrics_handler)) .route("/volumes", axum::routing::post(volumes::create_volume)) .route("/volumes", get(volumes::list_volumes)) - .route("/volumes/:id", get(volumes::get_volume)) - .route("/volumes/:id", axum::routing::delete(volumes::delete_volume)) - .route("/volumes/:id/attach", axum::routing::post(volumes::attach_volume)) - .route("/volumes/:id/detach", axum::routing::post(volumes::detach_volume)) - .route("/volumes/:id/snapshots", axum::routing::post(volumes::create_snapshot)) - .route("/volumes/:id/snapshots", get(volumes::list_snapshots)) + .route("/volumes/{id}", get(volumes::get_volume)) + .route( + "/volumes/{id}", + axum::routing::delete(volumes::delete_volume), + ) + .route( + "/volumes/{id}/attach", + axum::routing::post(volumes::attach_volume), + ) + .route( + "/volumes/{id}/detach", + axum::routing::post(volumes::detach_volume), + ) + .route( + "/volumes/{id}/snapshots", + axum::routing::post(volumes::create_snapshot), + ) + .route("/volumes/{id}/snapshots", get(volumes::list_snapshots)) .with_state(state) } diff --git a/control-plane/volume-manager/src/services/volume.rs b/control-plane/volume-manager/src/services/volume.rs index 11585b89..130dce45 100644 --- a/control-plane/volume-manager/src/services/volume.rs +++ b/control-plane/volume-manager/src/services/volume.rs @@ -1,4 +1,4 @@ -use crate::{log_warn}; +use crate::log_warn; use etcd_client::Client as EtcdClient; use sea_orm::DatabaseConnection; use std::sync::Arc; @@ -24,7 +24,11 @@ impl VolumeService { etcd: Arc>, ceph: Option>, ) -> Self { - Self { db, _etcd: etcd, ceph } + Self { + db, + _etcd: etcd, + ceph, + } } pub async fn create_volume(&self, req: CreateVolumeRequest) -> Result { @@ -67,7 +71,11 @@ impl VolumeService { .ok_or_else(|| format!("Volume {} not found", id))?; if let Some(ceph) = &self.ceph { - if let Err(e) = ceph.rbd_manager.delete_image(&model.pool, &model.image_name).await { + if let Err(e) = ceph + .rbd_manager + .delete_image(&model.pool, &model.image_name) + .await + { log_warn!("volume_service", &format!("Ceph RBD delete failed: {}", e)); } } @@ -86,7 +94,11 @@ impl VolumeService { .ok_or_else(|| format!("Volume {} not found", volume_id))?; let device = if let Some(ceph) = &self.ceph { - match ceph.rbd_manager.map_device(&model.pool, &model.image_name).await { + match ceph + .rbd_manager + .map_device(&model.pool, &model.image_name) + .await + { Ok(dev) => Some(dev), Err(e) => { log_warn!("volume_service", &format!("Ceph RBD map failed: {}", e)); @@ -141,7 +153,10 @@ impl VolumeService { .create_snapshot(&model.pool, &model.image_name, &req.name) .await { - log_warn!("volume_service", &format!("Ceph snapshot create failed: {}", e)); + log_warn!( + "volume_service", + &format!("Ceph snapshot create failed: {}", e) + ); } } diff --git a/docker-compose.yml b/docker-compose.yml index ee793691..da71700e 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -80,6 +80,7 @@ services: SDN_CONTROLLER_URL: http://sdn-controller:8005 FRONTEND_URL: http://localhost:5173 CSFX_INCLUDE_CONTAINERS: "true" + TLS_ENABLED: "false" ports: - "8000:8000" depends_on: