From b8e00c244ae11d0eaabf228e8a2e518e9a3ae8f5 Mon Sep 17 00:00:00 2001 From: Awiteb Date: Mon, 1 Jul 2024 11:30:57 +0300 Subject: [PATCH] chore: Use rustls instead of native-tls Signed-off-by: Awiteb --- Cargo.lock | 31 +++++++++++++++---------------- Cargo.toml | 4 ++-- crates/oxidetalis/Cargo.toml | 2 +- 3 files changed, 18 insertions(+), 19 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7983c05..3e48080 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -444,9 +444,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.101" +version = "1.0.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac367972e516d45567c7eafc73d24e1c193dcf200a8d94e9db7b3d38b349572d" +checksum = "2755ff20a1d93490d26ba33a6f092a38a508398a5320df5d4b3014fcccce9410" dependencies = [ "jobserver", "libc", @@ -492,9 +492,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.7" +version = "4.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" dependencies = [ "clap_builder", "clap_derive", @@ -502,9 +502,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.7" +version = "4.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" dependencies = [ "anstream", "anstyle", @@ -514,9 +514,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.5" +version = "4.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c780290ccf4fb26629baa7a1081e68ced113f1d3ec302fa5948f1c381ebf06c6" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" dependencies = [ "heck 0.5.0", "proc-macro2", @@ -1546,9 +1546,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.21" +version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" [[package]] name = "logcall" @@ -1720,9 +1720,9 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ "num-integer", "num-traits", @@ -1793,9 +1793,9 @@ dependencies = [ [[package]] name = "object" -version = "0.36.0" +version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "576dfe1fc8f9df304abb159d767a29d0476f7750fbf8aa7ad07816004a207434" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" dependencies = [ "memchr", ] @@ -2761,7 +2761,6 @@ dependencies = [ "mime-infer", "multer", "multimap", - "native-tls", "nix", "once_cell", "parking_lot", @@ -2769,6 +2768,7 @@ dependencies = [ "pin-project", "rand", "regex", + "rustls-pemfile 2.1.2", "salvo_macros", "serde", "serde-xml-rs", @@ -2778,7 +2778,6 @@ dependencies = [ "tempfile", "thiserror", "tokio", - "tokio-native-tls", "tokio-rustls", "tokio-util", "tracing", diff --git a/Cargo.toml b/Cargo.toml index 98d8fc7..57e7d68 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,8 +23,8 @@ log = "0.4.21" logcall = "0.1.9" chrono = "0.4.38" sea-orm = { version = "0.12.15", features = ["with-chrono", "macros"] } -salvo_core = { version = "0.68.3", default-features = false } -salvo-oapi = { version = "0.68.3", features = ["rapidoc","redoc","scalar","swagger-ui"] } +salvo_core = { version = "0.68.3", default-features = false, features = ["rustls"] } +salvo-oapi = { version = "0.68.3", default-features = false, features = ["rapidoc","redoc","scalar","swagger-ui"] } [profile.release] strip = true # Automatically strip symbols from the binary. diff --git a/crates/oxidetalis/Cargo.toml b/crates/oxidetalis/Cargo.toml index 035cf8b..7a59970 100644 --- a/crates/oxidetalis/Cargo.toml +++ b/crates/oxidetalis/Cargo.toml @@ -21,7 +21,7 @@ sea-orm = { workspace = true } serde = { workspace = true } thiserror = { workspace = true } chrono = { workspace = true } -salvo = { version = "0.68.2", features = ["affix", "logging", "native-tls", "oapi", "rate-limiter", "websocket"] } +salvo = { version = "0.68.2", features = ["rustls", "affix", "logging", "oapi", "rate-limiter", "websocket"] } tokio = { version = "1.38.0", features = ["macros", "rt-multi-thread"] } derive-new = "0.6.0" pretty_env_logger = "0.5.0"