Skip to content

Enable fully switching to rustls#108

Open
mtkennerly wants to merge 2 commits into
reown-com:mainfrom
mtkennerly:feature/rustls
Open

Enable fully switching to rustls#108
mtkennerly wants to merge 2 commits into
reown-com:mainfrom
mtkennerly:feature/rustls

Conversation

@mtkennerly

@mtkennerly mtkennerly commented Jun 16, 2026

Copy link
Copy Markdown

Description

Hi! I noticed that the rustls feature doesn't fully disable OpenSSL, because it's included in the default features for reqwest 0.12 (https://github.com/seanmonstar/reqwest/blob/v0.12.28/Cargo.toml#L37 via default-tls). This change just disables reqwest's default features, then explicitly re-enables the necessary ones depending on the selected relay_client features. There's no change in behavior for anyone using relay_client's default features.

How Has This Been Tested?

  • Verified that GitHub workflow still passes
  • Verified with rustls feature in a private project where the build environment does not include OpenSSL (also using default-features = false for relay_client)

Due Diligence

  • Breaking change
  • Requires a documentation update
  • Requires a e2e/integration test update

Copilot AI review requested due to automatic review settings June 16, 2026 16:54

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Updates relay_client dependency features to explicitly control reqwest TLS backends and reduce default reqwest feature enablement.

Changes:

  • Extend crate features to toggle reqwest TLS backend alongside tokio-tungstenite.
  • Disable reqwest default features and explicitly opt into a smaller feature set (json, http2, etc.).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread relay_client/Cargo.toml Outdated
Comment on lines +8 to +9
default = ["tokio-tungstenite/native-tls", "reqwest/default-tls"]
rustls = ["tokio-tungstenite/rustls-tls-native-roots", "reqwest/rustls-tls"]

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added reqwest/rustls-tls-native-roots in 8a1fc2f to align with the existing tokio-tungstenite/rustls-tls-native-roots.

Comment thread relay_client/Cargo.toml Outdated
Comment on lines +8 to +9
default = ["tokio-tungstenite/native-tls", "reqwest/default-tls"]
rustls = ["tokio-tungstenite/rustls-tls-native-roots", "reqwest/rustls-tls"]

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the existing pattern in the project, so I didn't want to introduce a breaking change here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants