Rust SDK hard-codes native-tls (OpenSSL); offer a rustls TLS backend so musl/static builds work
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 52/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- rust
- Domain
- build-system, networking, security
Research direction
Start by inspecting rust/Cargo.toml and running the stated cargo build for x86_64-unknown-linux-musl. Trace the reqwest and tokio-tungstenite TLS features, then confirm the chosen default or feature-gated backend builds without requiring system OpenSSL while preserving the requested client functionality.
Written by the indexing model from the issue text.
Description
Summary
The Rust crate (rust/Cargo.toml) hard-codes the OpenSSL-backed native-tls stack for its HTTP and WebSocket clients, with no way to opt into rustls:
reqwest = { version = "0.12", default-features = false, features = ["stream", "http2", "default-tls"] }
tokio-tungstenite = { version = "0.24", default-features = false, features = ["connect", "native-tls"] }
default-tls (reqwest) and native-tls (tokio-tungstenite) both pull in openssl-sys, which links the system OpenSSL on Linux. These deps were introduced with the HTTP request callback support in #1689.
Impact
- musl / fully-static targets fail to build. Cross-compiling to
*-unknown-linux-muslfails in theopenssl-sysbuild script withCould not find openssl via pkg-config/Could not find directory of OpenSSL installation, because there is no OpenSSL sysroot for the musl target. Consumers that ship static binaries (Alpine, distroless, hardened CI) cannot build the Rust SDK without vendoring OpenSSL. - glibc binaries gain a dynamic libssl runtime dependency. Even where the build succeeds, the resulting binary now dynamically links
libssl.so.3/libcrypto.so.3, narrowing portability for consumers that previously shipped self-contained rustls binaries.
Request
Make the TLS backend rustls-based, or feature-gate it so consumers can choose. Two shapes:
- Default to rustls — reqwest
rustls-tls(orrustls-tls-native-roots) and tokio-tungsteniterustls-tls-native-roots. Thering/aws-lc-rsbackends cross-compile to musl with no system OpenSSL, keeping the SDK OpenSSL-free out of the box. - Expose cargo features (e.g.
native-tlsvsrustls-tls) so downstreams pick a backend, while keeping native-tls available for those who want it.
Option 1 keeps the SDK cross-compilable by default; option 2 preserves choice. Happy to open a PR once you confirm the preferred shape.
Repro
With musl-tools installed:
cargo build -p <rust-sdk-crate> --target x86_64-unknown-linux-musl
fails in the openssl-sys build script.
- Dominant language
- Java
- Stars
- 10.5k
- Forks
- 1.5k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 130
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from github/copilot-sdk
-
agentic-workflows
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
github/copilot-sdk#2760 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
github/copilot-sdk#2759 ·
-
documentation
Difficulty 1/5 Under an hour Newbie friendliness 85/100
github/copilot-sdk#2758 ·
-
agentic-workflows
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
github/copilot-sdk#2709 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
github/copilot-sdk#2673 ·
All issues in github/copilot-sdk
Similar issues
-
certification
Difficulty 1/5 Under an hour Newbie friendliness 80/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
[BUG] ECR GetAuthorizationToken returns a proxyEndpoint for the default region, not the request's Openbug ecr
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Needs: Triage Type: Feature request
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
AntennaPod/AntennaPod#8794 ·
-
awaiting triage bug Causes friction Hop Gui P1 P2 Transforms
Difficulty 2/5 1-3 hours Newbie friendliness 75/100