diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index e9d02a0..8002fbd 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -12,7 +12,7 @@ name: build # Update the RUST_VERSION here and in the Makefile when we upgrade env: CARGO_TERM_COLOR: always - RUST_VERSION: 1.74.1 + RUST_VERSION: 1.78.0 on: push: @@ -22,7 +22,7 @@ on: branches: - master release: - types: [created] + types: [ created ] jobs: @@ -47,20 +47,20 @@ jobs: runs-on: ubuntu-latest if: ${{ github.ref != 'refs/heads/master' }} steps: - - name: Checkout code - uses: actions/checkout@v3 - - name: Install Rust toolchain - uses: actions-rs/toolchain@v1 - with: - toolchain: ${{ env.RUST_VERSION }} - override: true - default: true - components: rustfmt - - name: Check formatting - uses: actions-rs/cargo@v1 - with: - command: fmt - args: --all -- --check + - name: Checkout code + uses: actions/checkout@v3 + - name: Install Rust toolchain + uses: actions-rs/toolchain@v1 + with: + toolchain: ${{ env.RUST_VERSION }} + override: true + default: true + components: rustfmt + - name: Check formatting + uses: actions-rs/cargo@v1 + with: + command: fmt + args: --all -- --check clippy: name: Run Clippy @@ -84,24 +84,24 @@ jobs: args: --all-features --workspace -- -D warnings test: - name: Run Tests - runs-on: ubuntu-latest - steps: - - name: Checkout sources - uses: actions/checkout@v3 - - name: Install rust toolchain - uses: actions-rs/toolchain@v1 - with: - toolchain: ${{ env.RUST_VERSION }} - override: true - default: true - components: clippy - - name: Install build dependencies - run: sudo apt-get update && sudo apt-get install -y libpam-dev - - name: Run tests - run: cargo test --verbose --workspace --all --all-features - - name: Build Docs - run: cargo doc --all-features --workspace --no-deps + name: Run Tests + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v3 + - name: Install rust toolchain + uses: actions-rs/toolchain@v1 + with: + toolchain: ${{ env.RUST_VERSION }} + override: true + default: true + components: clippy + - name: Install build dependencies + run: sudo apt-get update && sudo apt-get install -y libpam-dev + - name: Run tests + run: cargo test --verbose --workspace --all --all-features + - name: Build Docs + run: cargo doc --all-features --workspace --no-deps build-linux-gnu: runs-on: ubuntu-latest @@ -244,7 +244,7 @@ jobs: target: ${{ env.target }} - name: Install Rosetta if: runner.os == 'macOS' && runner.arch == 'arm64' - run: softwareupdate --install-rosetta + run: softwareupdate --install-rosetta --agree-to-license - name: Build run: cargo build --release --target=${{ env.target }} --features rest_auth,jsonfile_auth,cloud_storage - name: Rename @@ -255,7 +255,7 @@ jobs: name: unftp_${{ env.target }} path: target/${{ env.target }}/release/unftp_${{ env.target }} - upload-release-binaries: + upload-release-binaries: if: ${{ github.event_name == 'release' }} # Testing: if: ${{ github.ref == 'refs/heads/hannes/upload' }} runs-on: ubuntu-latest strategy: @@ -329,7 +329,7 @@ jobs: run: chmod +x ./x86_64-unknown-linux-musl/unftp_x86_64-unknown-linux-musl - name: Build Docker image - run: docker build -t bolcom/unftp:${{ env.BUILD_VERSION }}-scratch -f packaging/docker/scratch.Dockerfile.ci . + run: docker build -t bolcom/unftp:${{ env.BUILD_VERSION }}-scratch -f packaging/docker/scratch.Dockerfile.ci . - name: Save Docker image as tar run: docker save -o docker-image-scratch.tar bolcom/unftp:${{ env.BUILD_VERSION }}-scratch diff --git a/CHANGELOG.md b/CHANGELOG.md index 3b64081..fa8f7fa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 2023-12-24 unftp v0.14.6 + +- Upgraded to libunftp v0.20.0 +- Upgraded other dependencies +- Compile with Rust 1.78.0 + ## 2023-12-24 unftp v0.14.5 - Added support for source IP in REST authentication requests @@ -32,7 +38,8 @@ ## 2022-12-08 unftp v0.14.0 -- The JSON authentication method (`--auth-json-path`) JSON user file (`--usr-json-path`) now support gzipped or gzipped+base64-encoded gzip files. +- The JSON authentication method (`--auth-json-path`) JSON user file (`--usr-json-path`) now support gzipped or + gzipped+base64-encoded gzip files. The compression makes it possible to fit large configuration files in a Kubernetes configmap for example. - Upgraded to unftp-auth-jsonfile v0.3.0 to support the gzipped or gzipped+base64-encoded auth json @@ -52,10 +59,11 @@ ## 2022-06-26 unftp v0.13.2 -- Added support for [tokio-console])(https://github.com/tokio-rs/console), the debugger for async Rust. Enable through +- Added support for [tokio-console])(https://github.com/tokio-rs/console), the debugger for async Rust. Enable through the `tokio_console` compile time feature. - [#414](https://github.com/bolcom/libunftp/pull/414) via libunftp: Fixed path display issues for Windows clients. -- [#413](https://github.com/bolcom/libunftp/pull/413) via libunftp: Fixed issue where the `OPTS UTF8` command was not handled correctly as seen with the FTP client included in Windows Explorer. +- [#413](https://github.com/bolcom/libunftp/pull/413) via libunftp: Fixed issue where the `OPTS UTF8` command was not + handled correctly as seen with the FTP client included in Windows Explorer. - Upgraded dependencies ## 2022-04-15 unftp v0.13.1 @@ -70,16 +78,17 @@ - BREAKING: Changed the format of the message sent in the Google Pub/Sub notifications. - Expanded on messages sent in Google Pub/Sub notifications: - 1. Include a Logout event - 2. Added a Trace ID field to allowing matching messages pertaining to the same control channel session - 3. Added a sequence number field to allow message ordering. - 4. Added the event type as a message attribute to allow for pub/sub message filtering + 1. Include a Logout event + 2. Added a Trace ID field to allowing matching messages pertaining to the same control channel session + 3. Added a sequence number field to allow message ordering. + 4. Added the event type as a message attribute to allow for pub/sub message filtering The message data format is documented in our user documentation at [unftp.rs](https://unftp.rs/server/pubsub). ## 2021-11-19 unftp v0.12.13 -- Implemented integration with Google Pub/Sub through the `--ntf-pubsub-project` and `ntf-pubsub-topic` arguments. Configuring +- Implemented integration with Google Pub/Sub through the `--ntf-pubsub-project` and `ntf-pubsub-topic` arguments. + Configuring this will send notifications to the pub/sub topic for FTP file system changes and logins for instance. - \#33 Implemented graceful shutdown - Upgraded dependencies @@ -94,29 +103,33 @@ _tag: v0.12.12_ _tag: v0.12.11_ -- Added the `--usr-json-path` argument to allow per-user settings to be specified in a JSON file. This can be the same +- Added the `--usr-json-path` argument to allow per-user settings to be specified in a JSON file. This can be the same JSON file specified for `--auth-json-path`. See the project README for examples. -- \#85 Ability to restrict the file system operations that an FTP user can do. Accomplished with above-mentioned per user +- \#85 Ability to restrict the file system operations that an FTP user can do. Accomplished with above-mentioned per + user settings (`vfs_perms` property). -- \#85 Ability to specify a separate root directory per user account (`root` property). -- Ability to enable/disable an FTP account. Accomplished with above-mentioned per user settings (`account_enabled` property). +- \#85 Ability to specify a separate root directory per user account (`root` property). +- Ability to enable/disable an FTP account. Accomplished with above-mentioned per user settings (`account_enabled` + property). - \#87 Added ability to enforce mTLS per user (`client_cert` property). -- \#87 Added ability to check the CN of a user's client certificate (`client_cert.allowed_cn` property). -- Upgraded to the latest libunftp and its extentions. See [the libunftp changelog](https://github.com/bolcom/libunftp/blob/master/CHANGELOG.md) - for more info. +- \#87 Added ability to check the CN of a user's client certificate (`client_cert.allowed_cn` property). +- Upgraded to the latest libunftp and its extentions. + See [the libunftp changelog](https://github.com/bolcom/libunftp/blob/master/CHANGELOG.md) + for more info. ## 2021-05-26 unftp v0.12.10 _tag: v0.12.10_ - Fixed a bug where logging to Redis stops after some time. -- Added support for the `SITE MD5` command. Use `--enable-sitemd5` for the filesystem backend (it is automatically enabled for the GCS storage backend) +- Added support for the `SITE MD5` command. Use `--enable-sitemd5` for the filesystem backend (it is automatically + enabled for the GCS storage backend) ## 2021-05-02 unftp v0.12.9 _tag: v0.12.9_ - Added Mutual TLS support with the addition of the `--ftps-client-auth` and `--ftps-trust-store` arguments. -- The JSON authentication method (`--auth-json-path`) now supports encryption through - [PBKDF2](https://tools.ietf.org/html/rfc2898#section-5.2) encoded passwords. See the +- The JSON authentication method (`--auth-json-path`) now supports encryption through + [PBKDF2](https://tools.ietf.org/html/rfc2898#section-5.2) encoded passwords. See the [unftp-auth-jsonfile](https://docs.rs/unftp-auth-jsonfile/0.1.1/unftp_auth_jsonfile/) documentation for an example. diff --git a/Cargo.lock b/Cargo.lock index ebfa51e..780c51d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -26,6 +26,12 @@ dependencies = [ "memchr", ] +[[package]] +name = "ambient-authority" +version = "0.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e9d4ee0d472d1cd2e28c97dfa124b3d8d992e10eb0a035f33f5d12e3a177ba3b" + [[package]] name = "android-tzdata" version = "0.1.1" @@ -55,9 +61,9 @@ checksum = "bddcadddf5e9015d310179a59bb28c4d4b9920ad0f11e8e14dbadf654890c9a6" [[package]] name = "asn1-rs" -version = "0.5.2" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fd5ddaf0351dff5b8da21b2fb4ff8e08ddd02857f0bf69c47639106c0fff0" +checksum = "22ad1373757efa0f70ec53939aabc7152e1591cb485208052993070ac8d2429d" dependencies = [ "asn1-rs-derive", "asn1-rs-impl", @@ -71,36 +77,36 @@ dependencies = [ [[package]] name = "asn1-rs-derive" -version = "0.4.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "726535892e8eae7e70657b4c8ea93d26b8553afb1ce617caee529ef96d7dee6c" +checksum = "7378575ff571966e99a744addeff0bff98b8ada0dedf1956d59e634db95eaac1" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.64", "synstructure", ] [[package]] name = "asn1-rs-impl" -version = "0.1.0" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2777730b2039ac0f95f093556e61b6d26cebed5393ca6f152717777cec3a42ed" +checksum = "7b18050c2cd6fe86c3a76584ef5e0baf286d038cda203eb6223df2cc413565f7" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.64", ] [[package]] name = "async-trait" -version = "0.1.75" +version = "0.1.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdf6721fb0140e4f897002dd086c06f6c27775df19cfe1fccb21181a48fd2c98" +checksum = "c6fa2087f2753a7da8cc1c0dbfcf89579dd57458e36769de5ac750b4671737ca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] @@ -188,9 +194,9 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.5" +version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" +checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" [[package]] name = "bitflags" @@ -200,9 +206,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "block-buffer" @@ -244,9 +250,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.5.0" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" [[package]] name = "camino" @@ -257,6 +263,35 @@ dependencies = [ "serde", ] +[[package]] +name = "cap-primitives" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe16767ed8eee6d3f1f00d6a7576b81c226ab917eb54b96e5f77a5216ef67abb" +dependencies = [ + "ambient-authority", + "fs-set-times", + "io-extras", + "io-lifetimes", + "ipnet", + "maybe-owned", + "rustix", + "windows-sys 0.52.0", + "winx", +] + +[[package]] +name = "cap-std" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "593db20e4c51f62d3284bae7ee718849c3214f93a3b94ea1899ad85ba119d330" +dependencies = [ + "cap-primitives", + "io-extras", + "io-lifetimes", + "rustix", +] + [[package]] name = "cargo-lock" version = "8.0.3" @@ -293,12 +328,13 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.83" +version = "1.0.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" +checksum = "099a5357d84c4c61eb35fc8eafa9a79a902c2f76911e5747ced4e032edd8d9b4" dependencies = [ "jobserver", "libc", + "once_cell", ] [[package]] @@ -307,17 +343,23 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +[[package]] +name = "cfg_aliases" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" + [[package]] name = "chrono" -version = "0.4.31" +version = "0.4.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" +checksum = "a21f936df1771bf62b77f047b726c4625ff2e8aa607c01ec06e5a05bd8463401" dependencies = [ "android-tzdata", "iana-time-zone", "num-traits", "serde", - "windows-targets 0.48.5", + "windows-targets 0.52.0", ] [[package]] @@ -359,16 +401,6 @@ dependencies = [ "os_str_bytes", ] -[[package]] -name = "codespan-reporting" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" -dependencies = [ - "termcolor", - "unicode-width", -] - [[package]] name = "combine" version = "4.6.6" @@ -439,9 +471,9 @@ checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" [[package]] name = "crc32fast" -version = "1.3.2" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" +checksum = "b3855a8a784b474f333699ef2bbca9db2c4a1f6d9088a90a2d25b1eb53111eaa" dependencies = [ "cfg-if", ] @@ -486,50 +518,6 @@ dependencies = [ "typenum", ] -[[package]] -name = "cxx" -version = "1.0.91" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86d3488e7665a7a483b57e25bdd90d0aeb2bc7608c8d0346acf2ad3f1caf1d62" -dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", -] - -[[package]] -name = "cxx-build" -version = "1.0.91" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48fcaf066a053a41a81dfb14d57d99738b767febb8b735c3016e469fac5da690" -dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2", - "quote", - "scratch", - "syn 1.0.109", -] - -[[package]] -name = "cxxbridge-flags" -version = "1.0.91" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2ef98b8b717a829ca5603af80e1f9e2e48013ab227b68ef37872ef84ee479bf" - -[[package]] -name = "cxxbridge-macro" -version = "1.0.91" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "086c685979a698443656e5cf7856c95c642295a38599f12fb1ff76fb28d19892" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "dashmap" version = "5.5.3" @@ -551,9 +539,9 @@ checksum = "7e962a19be5cfc3f3bf6dd8f61eb50107f356ad6270fbb3ed41476571db78be5" [[package]] name = "der-parser" -version = "8.2.0" +version = "9.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbd676fbbab537128ef0278adb5576cf363cff6aa22a7b24effe97347cfab61e" +checksum = "5cd0a5c643689626bec213c4d8bd4d96acc8ffdb4ad4bb6bc16abf27d5f4b553" dependencies = [ "asn1-rs", "displaydoc", @@ -565,9 +553,9 @@ dependencies = [ [[package]] name = "deranged" -version = "0.3.10" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eb30d70a07a3b04884d2677f06bec33509dc67ca60d92949e5535352d3191dc" +checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" dependencies = [ "powerfmt", "serde", @@ -631,7 +619,7 @@ checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] @@ -652,17 +640,6 @@ version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" -[[package]] -name = "errno" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f639046355ee4f37944e44f60642c6f3a7efa3cf6b78c78a0d989a8ce6c396a1" -dependencies = [ - "errno-dragonfly", - "libc", - "winapi", -] - [[package]] name = "errno" version = "0.3.8" @@ -673,16 +650,6 @@ dependencies = [ "windows-sys 0.52.0", ] -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - [[package]] name = "error-chain" version = "0.12.4" @@ -700,9 +667,9 @@ checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" [[package]] name = "flate2" -version = "1.0.28" +version = "1.0.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" dependencies = [ "crc32fast", "miniz_oxide", @@ -723,6 +690,17 @@ dependencies = [ "percent-encoding", ] +[[package]] +name = "fs-set-times" +version = "0.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "033b337d725b97690d86893f9de22b67b80dcc4e9ad815f348254c38119db8fb" +dependencies = [ + "io-lifetimes", + "rustix", + "windows-sys 0.52.0", +] + [[package]] name = "futures" version = "0.3.30" @@ -779,7 +757,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] @@ -824,9 +802,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.11" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe9006bed769170c11f845cf00c7c1e9092aeb3f268e007c3e760ac68008070f" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", @@ -919,9 +897,9 @@ dependencies = [ [[package]] name = "hermit-abi" -version = "0.3.2" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex" @@ -931,9 +909,9 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] name = "http" -version = "0.2.11" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8947b1a6fad4393052c7ba1f4cd97bed3e953a95c79c92ad9b051a04611d9fbb" +checksum = "601cbb57e577e2f5ef5be8e7b83f0f63994f25aa94d673e54a92d5c516d101f1" dependencies = [ "bytes", "fnv", @@ -1018,7 +996,7 @@ dependencies = [ "http", "hyper", "log", - "rustls 0.21.10", + "rustls 0.21.12", "rustls-native-certs", "tokio", "tokio-rustls 0.24.1", @@ -1038,9 +1016,9 @@ dependencies = [ [[package]] name = "iana-time-zone" -version = "0.1.58" +version = "0.1.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8326b86b6cff230b97d0d312a6c40a60726df3332e721f72a1b035f451663b20" +checksum = "e7ffbb5a1b541ea2561f8c41c087286cc091e21e556a4f09a8f6cbf17b69b141" dependencies = [ "android_system_properties", "core-foundation-sys", @@ -1052,12 +1030,11 @@ dependencies = [ [[package]] name = "iana-time-zone-haiku" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0703ae284fc167426161c2e3f1da3ea71d94b21bedbcc9494e92b28e334e3dca" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" dependencies = [ - "cxx", - "cxx-build", + "cc", ] [[package]] @@ -1081,16 +1058,21 @@ dependencies = [ ] [[package]] -name = "io-lifetimes" -version = "1.0.10" +name = "io-extras" +version = "0.18.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c66c74d2ae7e79a5a8f7ac924adbe38ee42a859c6539ad869eb51f0b52dc220" +checksum = "c9f046b9af244f13b3bd939f55d16830ac3a201e8a9ba9661bfcb03e2be72b9b" dependencies = [ - "hermit-abi 0.3.2", - "libc", - "windows-sys 0.48.0", + "io-lifetimes", + "windows-sys 0.52.0", ] +[[package]] +name = "io-lifetimes" +version = "2.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a611371471e98973dbcab4e0ec66c31a10bc356eeb4d54a0e05eac8158fe38c" + [[package]] name = "ipnet" version = "2.9.0" @@ -1106,6 +1088,17 @@ dependencies = [ "ipnet", ] +[[package]] +name = "is-terminal" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f23ff5ef2b80d608d61efee834934d862cd92461afc0560dedf493e4c033738b" +dependencies = [ + "hermit-abi 0.3.9", + "libc", + "windows-sys 0.52.0", +] + [[package]] name = "itertools" version = "0.10.5" @@ -1115,6 +1108,15 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + [[package]] name = "itoa" version = "0.4.8" @@ -1129,9 +1131,9 @@ checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" [[package]] name = "jobserver" -version = "0.1.27" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c37f63953c4c63420ed5fd3d6d398c719489b9f872b9fa683262f8edd363c7d" +checksum = "d2b099aaa34a9751c5bf0878add70444e1ed2dd73f347be99003d4577277de6e" dependencies = [ "libc", ] @@ -1153,9 +1155,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.151" +version = "0.2.154" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" +checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346" [[package]] name = "libgit2-sys" @@ -1171,12 +1173,12 @@ dependencies = [ [[package]] name = "libunftp" -version = "0.19.1" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f49971080b2ea8c8f254a94bd98d7873e236b32c1f2b486ab514009e09fdb4b" +checksum = "2adf9eb6541e4791db5d23bd803ee38a4aacc82979c315524c015a95c4e00bd8" dependencies = [ "async-trait", - "bitflags 2.4.1", + "bitflags 2.5.0", "bytes", "chrono", "dashmap", @@ -1187,9 +1189,10 @@ dependencies = [ "libc", "md-5", "moka", + "nix", "prometheus", "proxy-protocol", - "rustls 0.21.10", + "rustls 0.21.12", "rustls-pemfile", "slog", "slog-stdlog", @@ -1215,26 +1218,11 @@ dependencies = [ "vcpkg", ] -[[package]] -name = "link-cplusplus" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecd207c9c713c34f95a097a5b029ac2ce6010530c7b49d7fea24d977dede04f5" -dependencies = [ - "cc", -] - -[[package]] -name = "linux-raw-sys" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" - [[package]] name = "linux-raw-sys" -version = "0.4.12" +version = "0.4.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4cd1a83af159aa67994778be9070f0ae1bd732942279cabb14f86f986a21456" +checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" [[package]] name = "lock_api" @@ -1267,6 +1255,12 @@ version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b87248edafb776e59e6ee64a79086f65890d3510f2c656c000bf2a7e8a0aea40" +[[package]] +name = "maybe-owned" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4facc753ae494aeb6e3c22f839b158aebd4f9270f55cd3c79906c45476c47ab4" + [[package]] name = "md-5" version = "0.10.6" @@ -1279,9 +1273,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.6.4" +version = "2.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" +checksum = "523dc4f511e55ab87b694dc30d0f820d60906ef06413f93d4d7a1385599cc149" [[package]] name = "mime" @@ -1297,18 +1291,18 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.10" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" dependencies = [ "libc", "wasi", @@ -1336,6 +1330,18 @@ dependencies = [ "uuid", ] +[[package]] +name = "nix" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab2156c4fce2f8df6c499cc1c763e4394b7482525bf2a9701c9d79d215f519e4" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "cfg_aliases", + "libc", +] + [[package]] name = "nom" version = "7.1.3" @@ -1357,6 +1363,12 @@ dependencies = [ "num-traits", ] +[[package]] +name = "num-conv" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + [[package]] name = "num-integer" version = "0.1.45" @@ -1369,9 +1381,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "da0df0e5185db44f69b44f26786fe401b6c293d1907744beaa7fa62b2e5a517a" dependencies = [ "autocfg", ] @@ -1382,7 +1394,7 @@ version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi 0.3.2", + "hermit-abi 0.3.9", "libc", ] @@ -1406,9 +1418,9 @@ dependencies = [ [[package]] name = "oid-registry" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bedf36ffb6ba96c2eb7144ef6270557b52e54b20c0a8e1eb2ff99a6c6959bff" +checksum = "1c958dd45046245b9c3c2547369bb634eb461670b2e7e0de552905801a648d1d" dependencies = [ "asn1-rs", ] @@ -1578,31 +1590,41 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.71" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75cb1540fadbd5b8fbccc4dddad2734eba435053f725621c070711a14bb5f4b8" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "procfs" -version = "0.14.2" +version = "0.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1de8dacb0873f77e6aefc6d71e044761fcc68060290f5b1089fcdf84626bb69" +checksum = "731e0d9356b0c25f16f33b5be79b1c57b562f141ebfcdb0ad8ac2c13a24293b4" dependencies = [ - "bitflags 1.3.2", - "byteorder", + "bitflags 2.5.0", "hex", "lazy_static", - "rustix 0.36.6", + "procfs-core", + "rustix", +] + +[[package]] +name = "procfs-core" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d3554923a69f4ce04c4a754260c338f505ce22642d3830e049a399fc2059a29" +dependencies = [ + "bitflags 2.5.0", + "hex", ] [[package]] name = "prometheus" -version = "0.13.3" +version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "449811d15fbdf5ceb5c1144416066429cf82316e2ec8ce0c1f6f8a02e7bbcf8c" +checksum = "3d33c28a30771f7f96db69893f78b857f7450d7e0237e9c8fc6427a81bae7ed1" dependencies = [ "cfg-if", "fnv", @@ -1632,7 +1654,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4" dependencies = [ "anyhow", - "itertools", + "itertools 0.10.5", "proc-macro2", "quote", "syn 1.0.109", @@ -1676,9 +1698,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.33" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -1780,13 +1802,13 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.2" +version = "1.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" +checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.3", + "regex-automata 0.4.6", "regex-syntax 0.8.2", ] @@ -1801,9 +1823,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.3" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" +checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" dependencies = [ "aho-corasick", "memchr", @@ -1877,28 +1899,16 @@ dependencies = [ [[package]] name = "rustix" -version = "0.36.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4feacf7db682c6c329c4ede12649cd36ecab0f3be5b7d74e6a20304725db4549" -dependencies = [ - "bitflags 1.3.2", - "errno 0.2.8", - "io-lifetimes", - "libc", - "linux-raw-sys 0.1.4", - "windows-sys 0.42.0", -] - -[[package]] -name = "rustix" -version = "0.38.28" +version = "0.38.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72e572a5e8ca657d7366229cdde4bd14c4eb5499a9573d4d366fe1b599daa316" +checksum = "6ea3e1a662af26cd7a3ba09c0297a31af215563ecf42817c98df621387f4e949" dependencies = [ - "bitflags 2.4.1", - "errno 0.3.8", + "bitflags 2.5.0", + "errno", + "itoa 1.0.10", "libc", - "linux-raw-sys 0.4.12", + "linux-raw-sys", + "once_cell", "windows-sys 0.52.0", ] @@ -1916,16 +1926,30 @@ dependencies = [ [[package]] name = "rustls" -version = "0.21.10" +version = "0.21.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9d5a6813c0759e4609cd494e8e725babae6a2ca7b62a5536a13daaec6fcb7ba" +checksum = "3f56a14d1f48b391359b22f731fd4bd7e43c97f3c50eee276f3aa09c94784d3e" dependencies = [ "log", "ring 0.17.7", - "rustls-webpki", + "rustls-webpki 0.101.7", "sct", ] +[[package]] +name = "rustls" +version = "0.22.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf4ef73721ac7bcd79b2b315da7779d8fc09718c6b3d2d1b2d94850eb8c18432" +dependencies = [ + "log", + "ring 0.17.7", + "rustls-pki-types", + "rustls-webpki 0.102.4", + "subtle", + "zeroize", +] + [[package]] name = "rustls-native-certs" version = "0.6.2" @@ -1944,9 +1968,15 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" dependencies = [ - "base64 0.21.5", + "base64 0.21.7", ] +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + [[package]] name = "rustls-webpki" version = "0.101.7" @@ -1957,6 +1987,17 @@ dependencies = [ "untrusted 0.9.0", ] +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring 0.17.7", + "rustls-pki-types", + "untrusted 0.9.0", +] + [[package]] name = "rustversion" version = "1.0.12" @@ -1965,9 +2006,9 @@ checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" [[package]] name = "ryu" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" +checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" [[package]] name = "same-file" @@ -2002,12 +2043,6 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" -[[package]] -name = "scratch" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddccb15bcce173023b3fedd9436f882a0739b8dfb45e4f6b6002bee5929f61b2" - [[package]] name = "sct" version = "0.7.1" @@ -2058,29 +2093,29 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.193" +version = "1.0.202" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25dd9975e68d0cb5aa1120c288333fc98731bd1dd12f561e468ea4728c042b89" +checksum = "226b61a0d411b2ba5ff6d7f73a476ac4f8bb900373459cd00fab8512828ba395" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.193" +version = "1.0.202" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43576ca501357b9b071ac53cdc7da8ef0cbd9493d8df094cd821777ea6e894d3" +checksum = "6048858004bcff69094cd972ed40a32500f153bd3be9f716b2eed2e8217c4838" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] name = "serde_json" -version = "1.0.108" +version = "1.0.117" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d1c7e3eac408d115102c4c24ad393e0821bb3a5df4d506a80f85f7a742a526b" +checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" dependencies = [ "itoa 1.0.10", "ryu", @@ -2113,9 +2148,9 @@ dependencies = [ [[package]] name = "signal-hook-registry" -version = "1.4.1" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" dependencies = [ "libc", ] @@ -2199,11 +2234,11 @@ dependencies = [ [[package]] name = "slog-term" -version = "2.9.0" +version = "2.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87d29185c55b7b258b4f120eab00f48557d4d9bc814f41713f449d35b0f8977c" +checksum = "b6e022d0b998abfe5c3782c1f03551a596269450ccd677ea51c56f8b214610e8" dependencies = [ - "atty", + "is-terminal", "slog", "term", "thread_local", @@ -2212,9 +2247,9 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "e6ecd384b10a64542d77071bd64bd7b231f4ed5940fba55e98c3de13824cf3d7" [[package]] name = "snafu" @@ -2239,12 +2274,12 @@ dependencies = [ [[package]] name = "socket2" -version = "0.5.5" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" dependencies = [ "libc", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -2281,6 +2316,12 @@ version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +[[package]] +name = "subtle" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" + [[package]] name = "syn" version = "1.0.109" @@ -2294,9 +2335,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.42" +version = "2.0.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b7d0a2c048d661a1a59fcd7355baa232f7ed34e0ee4df2eef3c1c1c0d3852d8" +checksum = "7ad3dee41f36859875573074334c200d1add8e4a87bb37113ebd31d926b7b11f" dependencies = [ "proc-macro2", "quote", @@ -2311,14 +2352,13 @@ checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" [[package]] name = "synstructure" -version = "0.12.6" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" +checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", - "unicode-xid", + "syn 2.0.64", ] [[package]] @@ -2342,7 +2382,7 @@ dependencies = [ "cfg-if", "fastrand", "redox_syscall 0.4.1", - "rustix 0.38.28", + "rustix", "windows-sys 0.48.0", ] @@ -2359,9 +2399,9 @@ dependencies = [ [[package]] name = "termcolor" -version = "1.4.0" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff1bc3d3f05aff0403e8ac0d92ced918ec05b666a43f83297ccef5bea8a3d449" +checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" dependencies = [ "winapi-util", ] @@ -2374,22 +2414,22 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.51" +version = "1.0.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f11c217e1416d6f036b870f14e0413d480dbf28edbee1f877abaf0206af43bb7" +checksum = "579e9083ca58dd9dcf91a9923bb9054071b9ebbd800b342194c9feb0ee89fc18" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.51" +version = "1.0.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01742297787513b79cf8e29d1056ede1313e2420b7b3b15d0a768b4921f549df" +checksum = "e2470041c06ec3ac1ab38d0356a6119054dedaea53e12fbefc0de730a1c08524" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] @@ -2404,13 +2444,14 @@ dependencies = [ [[package]] name = "time" -version = "0.3.31" +version = "0.3.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f657ba42c3f86e7680e53c8cd3af8abbe56b5491790b46e22e19c0d57463583e" +checksum = "5dfd88e563464686c916c7e46e623e520ddc6d79fa6641390f2e3fa86e83e885" dependencies = [ "deranged", "itoa 1.0.10", "libc", + "num-conv", "num_threads", "powerfmt", "serde", @@ -2426,10 +2467,11 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.16" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26197e33420244aeb70c3e8c78376ca46571bc4e701e4791c2cd9f57dcb3a43f" +checksum = "3f252a68540fde3a3877aeea552b832b40ab9a69e318efd078774a01ddee1ccf" dependencies = [ + "num-conv", "time-core", ] @@ -2450,9 +2492,9 @@ checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" [[package]] name = "tokio" -version = "1.35.1" +version = "1.37.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c89b4efa943be685f629b149f53829423f8f5531ea21249408e8e2f8671ec104" +checksum = "1adbebffeca75fcfd058afa480fb6c0b81e165a0323f9c9d39c9697e37c46787" dependencies = [ "backtrace", "bytes", @@ -2485,7 +2527,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] @@ -2505,15 +2547,15 @@ version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" dependencies = [ - "rustls 0.21.10", + "rustls 0.21.12", "tokio", ] [[package]] name = "tokio-stream" -version = "0.1.14" +version = "0.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" +checksum = "267ac89e0bec6e691e5813911606935d77c476ff49024f98abcea3e7b15e37af" dependencies = [ "futures-core", "pin-project-lite", @@ -2522,9 +2564,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.10" +version = "0.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" dependencies = [ "bytes", "futures-core", @@ -2532,7 +2574,6 @@ dependencies = [ "futures-sink", "pin-project-lite", "tokio", - "tracing", ] [[package]] @@ -2552,7 +2593,7 @@ checksum = "3082666a3a6433f7f511c7192923fa1fe07c69332d3c6a2e6bb040b569199d5a" dependencies = [ "async-trait", "axum", - "base64 0.21.5", + "base64 0.21.7", "bytes", "futures-core", "futures-util", @@ -2623,7 +2664,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", ] [[package]] @@ -2671,7 +2712,7 @@ checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" [[package]] name = "unftp" -version = "0.14.5" +version = "0.14.6" dependencies = [ "async-trait", "base64 0.13.1", @@ -2706,12 +2747,12 @@ dependencies = [ [[package]] name = "unftp-auth-jsonfile" -version = "0.3.3" +version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e70b92dc601a8b364a9048879f0d0866eee41d700da1c825cd32a714dadb85d" +checksum = "49826e40f9829c7ed3a3bc8e8becd7b35ca6f82ea033ec68133bb2fc8d6850cb" dependencies = [ "async-trait", - "base64 0.21.5", + "base64 0.21.7", "bytes", "flate2", "ipnet", @@ -2728,9 +2769,9 @@ dependencies = [ [[package]] name = "unftp-auth-pam" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ab664a1645c03184c1f99ab71d70493de7eb15792bfaa553111dbc0b3525797" +checksum = "2d660456a1235650b768ac909150e5b6a9bb2c72057ec5aefa8436147f916807" dependencies = [ "async-trait", "libunftp", @@ -2741,9 +2782,9 @@ dependencies = [ [[package]] name = "unftp-auth-rest" -version = "0.2.4" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "092ea9a32364a7160dadddd277bd386ed679bdf272cd3f74d50a81645dc58395" +checksum = "bdba42e5964ef945842167cab4c10fd12667dc12acbcfc702414f3d0262267ac" dependencies = [ "async-trait", "hyper", @@ -2760,13 +2801,15 @@ dependencies = [ [[package]] name = "unftp-sbe-fs" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f7165a6e8d96504e2515247fec05fac7f3add1b295d53d81f6aa3c0eee69ace" +checksum = "c79e842d1c8f1bca18a78773b131072ab2dc15d3caed6091fbc5c0aac5672fc9" dependencies = [ "async-trait", + "cap-std", "cfg-if", "futures", + "lazy_static", "libunftp", "path_abs", "tokio", @@ -2777,12 +2820,12 @@ dependencies = [ [[package]] name = "unftp-sbe-gcs" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "539b07479f2139bab50bcef472f0169abda057fdd00ae86313b22350701d18b0" +checksum = "157f845a3413ed71da2070d5b76dd007beba21322f78fcd8909a1a08086da785" dependencies = [ "async-trait", - "base64 0.21.5", + "base64 0.21.7", "bytes", "chrono", "futures", @@ -2804,21 +2847,21 @@ dependencies = [ [[package]] name = "unftp-sbe-restrict" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3a8e70163045039e0ae0a045c12b4db8751e5fc99f5a0f5cfdc848bc269b668" +checksum = "7c13c64b1590901941ebe735f77f8c6d7d667662cb3212ecf83b1f3dfa0ca43a" dependencies = [ "async-trait", - "bitflags 2.4.1", + "bitflags 2.5.0", "libunftp", "tokio", ] [[package]] name = "unftp-sbe-rooter" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11cb8eb3192cd578bcaf261be0e6bd1d83e908c791bbeae2608568d8558ea393" +checksum = "b0923e85f821471ebc4c1cfcf2211c40ca36b3ceb1b22d5462567fde89d08a3c" dependencies = [ "async-trait", "libunftp", @@ -2855,18 +2898,6 @@ dependencies = [ "tinyvec", ] -[[package]] -name = "unicode-width" -version = "0.1.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" - -[[package]] -name = "unicode-xid" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" - [[package]] name = "untrusted" version = "0.7.1" @@ -2901,9 +2932,9 @@ dependencies = [ [[package]] name = "uuid" -version = "1.6.1" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e395fcf16a7a3d8127ec99782007af141946b4795001f876d54fb0d55978560" +checksum = "a183cf7feeba97b4dd1c0d46788634f6221d87fa961b305bed08c851829efcc0" dependencies = [ "getrandom", ] @@ -2979,7 +3010,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", "wasm-bindgen-shared", ] @@ -3001,7 +3032,7 @@ checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.42", + "syn 2.0.64", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -3261,14 +3292,23 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" +[[package]] +name = "winx" +version = "0.36.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9643b83820c0cd246ecabe5fa454dd04ba4fa67996369466d0747472d337346" +dependencies = [ + "bitflags 2.5.0", + "windows-sys 0.52.0", +] + [[package]] name = "x509-parser" -version = "0.14.0" +version = "0.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0ecbeb7b67ce215e40e3cc7f2ff902f94a223acf44995934763467e7b1febc8" +checksum = "fcbc162f30700d6f3f82a24bf7cc62ffe7caea42c0b2cba8bf7f3ae50cf51f69" dependencies = [ "asn1-rs", - "base64 0.13.1", "data-encoding", "der-parser", "lazy_static", @@ -3287,21 +3327,21 @@ checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" [[package]] name = "yup-oauth2" -version = "8.3.1" +version = "8.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24bea7df5a9a74a9a0de92f22e5ab3fb9505dd960c7f1f00de5b7231d9d97206" +checksum = "b61da40aeb0907a65f7fb5c1de83c5a224d6a9ebb83bf918588a2bb744d636b8" dependencies = [ "anyhow", "async-trait", - "base64 0.13.1", + "base64 0.21.7", "futures", "http", "hyper", "hyper-rustls 0.24.2", - "itertools", + "itertools 0.12.1", "log", "percent-encoding", - "rustls 0.21.10", + "rustls 0.22.4", "rustls-pemfile", "seahash", "serde", @@ -3311,3 +3351,9 @@ dependencies = [ "tower-service", "url", ] + +[[package]] +name = "zeroize" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" diff --git a/Cargo.toml b/Cargo.toml index 1298f98..98247d9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "unftp" -version = "0.14.5" +version = "0.14.6" authors = [ "Agoston Horvath ", "Dávid Kosztka ", @@ -23,38 +23,38 @@ documentation = "https://github.com/bolcom/unFTP" [workspace] [dependencies.slog-redis] -path="crates/redislog" -version="0.1.2" +path = "crates/redislog" +version = "0.1.2" [dependencies] -async-trait = "0.1.75" +async-trait = "0.1.80" base64 = "0.13.1" clap = { version = "3.2.25", features = ["derive", "env"] } console-subscriber = { version = "0.1.10", optional = true } -flate2 = "1.0.28" +flate2 = "1.0.30" futures = "0.3.30" -http = "0.2.11" +http = "0.2.12" hyper = { version = "0.14.28", features = ["server", "http1"] } hyper-rustls = "0.23.2" lazy_static = "1.4.0" -libunftp = "0.19.1" -prometheus = { version = "0.13.3", features = ["process"] } -serde = { version = "1.0.193", features = ["derive"] } -serde_json = "1.0.108" +libunftp = "0.20.0" +prometheus = { version = "0.13.4", features = ["process"] } +serde = { version = "1.0.202", features = ["derive"] } +serde_json = "1.0.117" slog = { version = "2.7.0", features = ["max_level_trace", "release_max_level_info"] } slog-async = "2.8.0" -slog-term = "2.9.0" -thiserror = "1.0.51" -tokio = { version = "1.35.1", features = ["signal", "rt-multi-thread"] } -unftp-sbe-fs = "0.2.4" -unftp-sbe-gcs = { version = "0.2.5", optional = true } -unftp-auth-rest = { version = "0.2.4", optional = true } -unftp-auth-jsonfile = { version = "0.3.3", optional = true } -unftp-sbe-rooter = "0.2.0" -unftp-sbe-restrict = "0.1.1" +slog-term = "2.9.1" +thiserror = "1.0.60" +tokio = { version = "1.37.0", features = ["signal", "rt-multi-thread"] } +unftp-sbe-fs = "0.2.5" +unftp-sbe-gcs = { version = "0.2.6", optional = true } +unftp-auth-rest = { version = "0.2.6", optional = true } +unftp-auth-jsonfile = { version = "0.3.4", optional = true } +unftp-sbe-rooter = "0.2.1" +unftp-sbe-restrict = "0.1.2" [target.'cfg(unix)'.dependencies] -unftp-auth-pam = { version = "0.2.4", optional = true } +unftp-auth-pam = { version = "0.2.5", optional = true } [features] default = ["rest_auth", "cloud_storage", "jsonfile_auth"] diff --git a/Makefile b/Makefile index d6e4f8a..5e72f4b 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -RUST_VERSION=1.74.1 +RUST_VERSION=1.78.0 DOCKER_TAG=$(shell git describe --tags) DOCKER_TEMPLATES:=$(wildcard *.Dockerfile.template) DOCKER_FILES=$(DOCKER_TEMPLATES:%.template=%) diff --git a/RELEASE-CHECKLIST.md b/RELEASE-CHECKLIST.md index 2c609b6..e357c1e 100644 --- a/RELEASE-CHECKLIST.md +++ b/RELEASE-CHECKLIST.md @@ -1,22 +1,23 @@ # Release Checklist * Update the Rust version in the Makefile and the Github actions file -* Update minor versions dependencies +* Update minor versions dependencies. Install [cargo-edit](https://crates.io/crates/cargo-edit) and run `cargo upgrade`. + Cargo-edit also covers all the crates in the workspace * Update Cargo.toml with the new version number (also check for libunftp version references) * Search for the old version number to find references to it in documentation and update those occurrences. * Run `make pr-prep`, ensuring everything is green * Prepare release notes for the Github release page -* Make a new commit indicating the crate name and version number e.g. - > Release unftp version x.y.x +* Make a new commit indicating the crate name and version number e.g. + > Release unftp version x.y.x - or + or - > Release slog-redis version x.y.x + > Release slog-redis version x.y.x * Make a pull request for this but don't merge. * Wait till MR pipelins are OK then run `make publish` * Merge the MR via the command line by merging marster into the branch and pushing it. * Create the release in Github using tag format \[{component}-\]{version} e.g. - > v0.14.5 + > v0.14.6 or > slog-redis-v0.1.2 * Wait for the Github Actions pipeline to finish. You should see all artifacts in the release page. diff --git a/crates/redislog/Cargo.toml b/crates/redislog/Cargo.toml index 420c3ad..6bb3790 100644 --- a/crates/redislog/Cargo.toml +++ b/crates/redislog/Cargo.toml @@ -13,11 +13,11 @@ repository = "https://github.com/bolcom/unFTP/tree/master/crates/redislog" readme = "README.md" [dependencies] -chrono = { version = "0.4.31", default-features = false, features = ["std", "clock"] } +chrono = { version = "0.4.38", default-features = false, features = ["std", "clock"] } r2d2 = "0.8.10" r2d2_redis = "0.14.0" redis = "0.20.2" -serde_json = "1.0.108" +serde_json = "1.0.117" slog = { version = "2.7.0", features = ["max_level_trace", "release_max_level_info"] } [dev-dependencies] diff --git a/docs/server/docker.md b/docs/server/docker.md index 1e1e437..23c979e 100644 --- a/docs/server/docker.md +++ b/docs/server/docker.md @@ -5,9 +5,9 @@ title: Docker You can download pre-made docker images from [docker hub](https://hub.docker.com/r/bolcom/unftp/tags) e.g.: ```sh -docker pull bolcom/unftp:v0.14.5-alpine -docker pull bolcom/unftp:v0.14.5-alpine-istio -docker pull bolcom/unftp:v0.14.5-scratch +docker pull bolcom/unftp:v0.14.6-alpine +docker pull bolcom/unftp:v0.14.6-alpine-istio +docker pull bolcom/unftp:v0.14.6-scratch ``` Example running unFTP in a Docker container: @@ -34,6 +34,6 @@ docker run \ -v /Users/xxx/unftp/unftp.crt:/unftp.crt \ -v /Users/xxx/unftp/the-key.json:/key.json \ -ti \ - bolcom/unftp:v0.14.5-alpine + bolcom/unftp:v0.14.6-alpine ``` diff --git a/docs/server/installation.md b/docs/server/installation.md index 5af1fae..5177fcd 100644 --- a/docs/server/installation.md +++ b/docs/server/installation.md @@ -5,7 +5,8 @@ title: Installation ## Binaries [Precompiled binaries for unFTP are available](https://github.com/bolcom/unFTP/releases) for Linux and macOS. On Linux -you can choose between a statically linked image (no PAM integration) or a dynamically linked image with PAM integration: +you can choose between a statically linked image (no PAM integration) or a dynamically linked image with PAM +integration: - unftp_x86_64-apple-darwin - macOS - unftp_x86_64-unknown-linux-musl - Linux statically linked, no PAM support. @@ -16,21 +17,21 @@ you can choose between a statically linked image (no PAM integration) or a dynam Linux (static, no PAM): ```sh -curl -L https://github.com/bolcom/unFTP/releases/download/v0.14.5/unftp_x86_64-unknown-linux-musl \ +curl -L https://github.com/bolcom/unFTP/releases/download/v0.14.6/unftp_x86_64-unknown-linux-musl \ | sudo tee /usr/local/bin/unftp > /dev/null && sudo chmod +x /usr/local/bin/unftp ``` Linux (dynamic with PAM support): ```sh -curl -L https://github.com/bolcom/unFTP/releases/download/v0.14.5/unftp_x86_64-unknown-linux-gnu \ +curl -L https://github.com/bolcom/unFTP/releases/download/v0.14.6/unftp_x86_64-unknown-linux-gnu \ | sudo tee /usr/local/bin/unftp > /dev/null && sudo chmod +x /usr/local/bin/unftp ``` macOS Intel: ```sh -curl -L https://github.com/bolcom/unFTP/releases/download/v0.14.5/unftp_x86_64-apple-darwin \ +curl -L https://github.com/bolcom/unFTP/releases/download/v0.14.6/unftp_x86_64-apple-darwin \ | sudo tee /usr/local/bin/unftp > /dev/null && sudo chmod +x /usr/local/bin/unftp ``` @@ -41,16 +42,16 @@ curl -L https://github.com/bolcom/unFTP/releases/download/v4/unftp_aarch64-apple | sudo tee /usr/local/bin/unftp > /dev/null && sudo chmod +x /usr/local/bin/unftp ``` - ## From Source -You'll need [Rust](https://rust-lang.org) 1.67.1 (including `cargo`) or higher to build unFTP. Then: +You'll need [Rust](https://rust-lang.org) 1.67.1 (including `cargo`) or higher to build unFTP. Then: ```sh cargo install unftp ``` -and find unftp in `~/.cargo/bin/unftp`. You may want to add `~/.cargo/bin` to your PATH if you haven't done so. The above +and find unftp in `~/.cargo/bin/unftp`. You may want to add `~/.cargo/bin` to your PATH if you haven't done so. The +above merely creates the binary there, it won't start it as a service at the moment. ## Docker Images diff --git a/docs/server/pubsub.md b/docs/server/pubsub.md index 55dd3c2..fa18a8b 100644 --- a/docs/server/pubsub.md +++ b/docs/server/pubsub.md @@ -7,9 +7,10 @@ integration with [Google Pub/Sub](https://cloud.google.com/pubsub). # Enabling the Pub/Sub integration -You can enable the unFTP Pub/Sub notifier by specifying the `--ntf-pubsub-project` and `--ntf-pubsub-topic` arguments. +You can enable the unFTP Pub/Sub notifier by specifying the `--ntf-pubsub-project` and `--ntf-pubsub-topic` arguments. -NOTE: Currently authentication with [workload identity](https://cloud.google.com/kubernetes-engine/docs/how-to/workload-identity) is the +NOTE: Currently authentication +with [workload identity](https://cloud.google.com/kubernetes-engine/docs/how-to/workload-identity) is the only supported authentication mechanism. Here is an example: @@ -30,9 +31,9 @@ Message attributes can be used to [filter messages](https://cloud.google.com/pub when you receive messages from a subscription with a filter, you only receive the messages that match the filter. unFTP only specifies an `eventType` attribute: -Key | Value | Description | ------------------|--------|-----| -eventType | _One of_:

- startup
- login
- logout
- get
- put
- delete
- makeDir
- rename
- removeDir | Indicates the type of event | + Key | Value | Description | +-----------|---------------------------------------------------------------------------------------------------------------------------------------|-----------------------------| + eventType | _One of_:

- startup
- login
- logout
- get
- put
- delete
- makeDir
- rename
- removeDir | Indicates the type of event | ## Message Body @@ -67,14 +68,14 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "Startup":{ - "libunftp_version":"0.19.1", - "unftp_version":"v0.14.5" - } - } + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "Startup": { + "libunftp_version": "0.19.1", + "unftp_version": "v0.14.6" + } + } } ``` @@ -82,14 +83,14 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "Login":{ } - }, - "username":"hannes", - "trace_id":"0xe25ceb1d960303f3", - "sequence_number":1 + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "Login": {} + }, + "username": "hannes", + "trace_id": "0xe25ceb1d960303f3", + "sequence_number": 1 } ``` @@ -97,14 +98,14 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "Logout":{ } - }, - "username":"hannes", - "trace_id":"0xe25ceb1d960303f3", - "sequence_number":2 + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "Logout": {} + }, + "username": "hannes", + "trace_id": "0xe25ceb1d960303f3", + "sequence_number": 2 } ``` @@ -112,16 +113,16 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "Get":{ - "path":"hello.txt" - } - }, - "username":"hannes", - "trace_id":"0x687ee52555459a9c", - "sequence_number":2 + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "Get": { + "path": "hello.txt" + } + }, + "username": "hannes", + "trace_id": "0x687ee52555459a9c", + "sequence_number": 2 } ``` @@ -129,16 +130,16 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "MakeDir":{ - "path":"/x" - } - }, - "username":"hannes", - "trace_id":"0x687ee52555459a9c", - "sequence_number":3 + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "MakeDir": { + "path": "/x" + } + }, + "username": "hannes", + "trace_id": "0x687ee52555459a9c", + "sequence_number": 3 } ``` @@ -146,17 +147,17 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "Rename":{ - "from":"/x", - "to":"/y" - } - }, - "username":"hannes", - "trace_id":"0x687ee52555459a9c", - "sequence_number":4 + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "Rename": { + "from": "/x", + "to": "/y" + } + }, + "username": "hannes", + "trace_id": "0x687ee52555459a9c", + "sequence_number": 4 } ``` @@ -164,15 +165,15 @@ All of them are of type JSON object. Examples of their format are shown below. ```json { - "source_instance":"unFTP", - "hostname":"MYMAC-XYZ", - "payload":{ - "Put":{ - "path":"x.yaml" - } - }, - "username":"hannes", - "trace_id":"0x687ee52555459a9c", - "sequence_number":5 + "source_instance": "unFTP", + "hostname": "MYMAC-XYZ", + "payload": { + "Put": { + "path": "x.yaml" + } + }, + "username": "hannes", + "trace_id": "0x687ee52555459a9c", + "sequence_number": 5 } ``` diff --git a/src/infra/usrdetail_json.rs b/src/infra/usrdetail_json.rs index 117853b..77e1921 100644 --- a/src/infra/usrdetail_json.rs +++ b/src/infra/usrdetail_json.rs @@ -3,7 +3,7 @@ use serde::Deserialize; use std::path::PathBuf; use unftp_sbe_restrict::VfsOperations; -/// A [`UserDetail`] provider that gets user details from a JSON file. +/// A [`UserDetailProvider`] that gets user details from a JSON file. #[derive(Debug, Deserialize)] pub struct JsonUserProvider { users: Vec, diff --git a/src/main.rs b/src/main.rs index da3da85..16a17b4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -31,7 +31,7 @@ use libunftp::{ FailedLoginsBlock, FailedLoginsPolicy, FtpsClientAuth, FtpsRequired, SiteMd5, TlsFlags, }, storage::StorageBackend, - Server, + ServerBuilder, }; use slog::*; use std::io::{Read, Seek}; @@ -465,7 +465,7 @@ where hostname: hostname.clone(), }); - let mut server = Server::with_authenticator(storage_backend, authenticator) + let mut server = ServerBuilder::with_authenticator(storage_backend, authenticator) .greeting("Welcome to unFTP") .passive_ports(start_port..end_port) .idle_session_timeout(idle_timeout) @@ -653,6 +653,10 @@ where } }; + let server = server + .build() + .map_err(|e| format!("Could not build server: {}", e))?; + let log = log.clone(); tokio::spawn(async move { if let Err(e) = server.listen(addr).await {