Skip to content

Commit

Permalink
use rustls v0.21
Browse files Browse the repository at this point in the history
  • Loading branch information
robjtede committed Aug 29, 2023
1 parent 9ac2421 commit cfea68d
Show file tree
Hide file tree
Showing 12 changed files with 66 additions and 50 deletions.
77 changes: 46 additions & 31 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -73,20 +73,20 @@ actix-broker = "0.4"
actix-codec = "0.5"
actix-cors = "0.6"
actix-files = "0.6"
actix-http = "3"
actix-http = "3.4"
actix-identity = "0.5"
actix-multipart = "0.6"
actix-multipart-derive = "0.6"
actix-protobuf = "0.9"
actix-session = "0.7"
actix-test = "0.1"
actix-tls = "3"
actix-tls = "3.1"
actix-utils = "3"
actix-web = "4.3"
actix-web = "4.4"
actix-web-actors = "4.1"
actix-web-lab = "0.19"
actix-ws = "0.2.5"
awc = "3"
awc = "3.2"

chrono = { version = "0.4.20", default-features = false, features = ["clock", "serde"] }
derive_more = "0.99.7"
Expand All @@ -96,6 +96,7 @@ futures-util = { version = "0.3.17", default-features = false, features = ["std"
log = "0.4"
openssl = { version = "0.10.55", features = ["v110"] }
rand = "0.8"
rustls = "0.21"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
tokio = { version = "1.24.2", features = ["sync", "io-util"] }
Expand Down
2 changes: 1 addition & 1 deletion cors/backend/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "1.0.0"
edition = "2021"

[dependencies]
actix-web = { workspace = true, features = ["rustls"] }
actix-web.workspace = true
actix-cors.workspace = true

env_logger.workspace = true
Expand Down
6 changes: 3 additions & 3 deletions https-tls/awc-https/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ edition = "2021"

[dependencies]
actix-web.workspace = true
awc = { version = "3", features = ["rustls"] }
awc = { workspace = true, features = ["rustls-0_21"] }

env_logger.workspace = true
log.workspace = true
mime = "0.3"
rustls = "0.20"
webpki-roots = "0.24"
rustls.workspace = true
webpki-roots = "0.25"
2 changes: 1 addition & 1 deletion https-tls/openssl-auto-le/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ edition = "2021"
actix-web = { workspace = true, features = ["openssl"] }
actix-files.workspace = true

acme-micro = "0.12"
acme-lib = "0.8"
anyhow = "1"
env_logger.workspace = true
log.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion https-tls/openssl-auto-le/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::{fs, time::Duration};

use acme_micro::{create_p384_key, Certificate, Directory, DirectoryUrl};
use acme_lib::{create_p384_key, Certificate, Directory, DirectoryUrl};
use actix_files::Files;
use actix_web::{rt, web, App, HttpRequest, HttpServer, Responder};
use anyhow::anyhow;
Expand Down
4 changes: 2 additions & 2 deletions https-tls/rustls-client-cert/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ edition = "2021"

[dependencies]
actix-tls.workspace = true
actix-web = { workspace = true, features = ["rustls"] }
actix-web = { workspace = true, features = ["rustls-0_21"] }
env_logger.workspace = true
log.workspace = true
rustls = "0.20"
rustls.workspace = true
rustls-pemfile = "1"
2 changes: 1 addition & 1 deletion https-tls/rustls-client-cert/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ async fn main() -> std::io::Result<()> {
HttpServer::new(|| App::new().default_service(web::to(route_whoami)))
.on_connect(get_client_cert)
.bind(("localhost", 8080))?
.bind_rustls(("localhost", 8443), config)?
.bind_rustls_021(("localhost", 8443), config)?
.workers(1)
.run()
.await
Expand Down
4 changes: 2 additions & 2 deletions https-tls/rustls/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ name = "rustls-server"
path = "src/main.rs"

[dependencies]
actix-web = { workspace = true, features = ["rustls"] }
actix-web = { workspace = true, features = ["rustls-0_21"] }
actix-files.workspace = true

env_logger.workspace = true
log.workspace = true
rustls = "0.20.2"
rustls.workspace = true
rustls-pemfile = "1"
2 changes: 1 addition & 1 deletion https-tls/rustls/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ async fn main() -> std::io::Result<()> {
.service(web::redirect("/", "/index.html"))
.service(Files::new("/static", "static"))
})
.bind_rustls("127.0.0.1:8443", config)?
.bind_rustls_021("127.0.0.1:8443", config)?
.run()
.await
}
Expand Down
4 changes: 2 additions & 2 deletions middleware/middleware-http-to-https/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ version = "1.0.0"
edition = "2021"

[dependencies]
actix-web = { workspace = true, features = ["rustls"] }
actix-web = { workspace = true, features = ["rustls-0_21"] }
env_logger.workspace = true
futures-util.workspace = true
log.workspace = true
rustls = "0.20"
rustls.workspace = true
rustls-pemfile = "1"
2 changes: 1 addition & 1 deletion middleware/middleware-http-to-https/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ async fn main() -> std::io::Result<()> {
.service(index)
})
.bind(("127.0.0.1", 80))? // HTTP port
.bind_rustls(("127.0.0.1", 443), config)? // HTTPS port
.bind_rustls_021(("127.0.0.1", 443), config)? // HTTPS port
.run()
.await
}

0 comments on commit cfea68d

Please sign in to comment.