Skip to content

Commit

Permalink
demo: update to axum-server v0.7.1
Browse files Browse the repository at this point in the history
Switch to the `tls-rustls-no-provider` feature added in v0.7.1.
Since v0.7.0 the `tls-rustls` feature uses rustls v0.23 which
require a per-process (or thread) `CryptoProvider` be set.
By default, rustls uses `aws_lc_rs` which requires `cmake` et al.
to build. Worse, `axum-server` doesn't re-export the relevant
`rustls` symbols, so one has to declare a direct `rustls` dependency
and keep it in sync to call the required initialization function.

Since this is a basic example, just disable to provider for simplicity.
  • Loading branch information
rillian committed Aug 13, 2024
1 parent ff5b3d4 commit 2fc6f0f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion demo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ rand = { version = "0.8.5" }
rand_core = { version = "0.6.4" }
ark-ff-macros = { version = "0.4.2", default-features = false }
axum = "0.7" # or the latest version
axum-server = { version = "0.6", features = ["tls-rustls"] }
axum-server = { version = "0.7.1", features = ["tls-rustls-no-provider"] }
tokio = { version = "1", features = ["full"] }
tracing = "0.1" # Ensure you have tracing
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
Expand Down

0 comments on commit 2fc6f0f

Please sign in to comment.