Skip to content

feat(crypto): add support for crypto-native-tls feature and update reqwest dependencies#2537

Open
AaronRM wants to merge 2 commits intoopen-telemetry:mainfrom
AaronRM:crypto-native-tls
Open

feat(crypto): add support for crypto-native-tls feature and update reqwest dependencies#2537
AaronRM wants to merge 2 commits intoopen-telemetry:mainfrom
AaronRM:crypto-native-tls

Conversation

@AaronRM
Copy link
Copy Markdown
Contributor

@AaronRM AaronRM commented Apr 3, 2026

Change Summary

Add a new crypto-native-tls feature flag that uses the platform's native TLS stack (SChannel on Windows, OpenSSL on Linux, Security.framework on macOS) instead of rustls. This follows the pluggable crypto architecture from PR #2269
and avoids cross-compilation issues with C/asm crypto providers on Windows.

What issue does this PR close?

How are these changes tested?

  • cargo test --no-default-features --features crypto-native-tls --workspace passes (591 tests, same as default features)
  • CI step added to no_default_features_check job

Are there any user-facing changes?

Yes: new crypto-native-tls feature flag available for embedders who want platform-native TLS without compiling a crypto library from source. Default behavior is unchanged (crypto-ring). Note that crypto-native-tls covers client-side HTTP/HTTPS connections only (reqwest); server-side gRPC TLS (experimental-tls) still requires a rustls-based crypto feature.

@AaronRM AaronRM requested a review from a team as a code owner April 3, 2026 21:02
@github-actions github-actions bot added rust Pull requests that update Rust code ci-repo Repository maintenance, build, GH workflows, repo cleanup, or other chores labels Apr 3, 2026
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.32%. Comparing base (c9f412a) to head (2a4f53d).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2537      +/-   ##
==========================================
- Coverage   88.35%   88.32%   -0.04%     
==========================================
  Files         613      613              
  Lines      221837   221840       +3     
==========================================
- Hits       196005   195930      -75     
- Misses      25308    25386      +78     
  Partials      524      524              
Components Coverage Δ
otap-dataflow 90.21% <100.00%> (-0.05%) ⬇️
query_abstraction 80.61% <ø> (ø)
query_engine 90.74% <ø> (ø)
syslog_cef_receivers ∅ <ø> (∅)
otel-arrow-go 52.45% <ø> (ø)
quiver 91.92% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@AaronRM
Copy link
Copy Markdown
Contributor Author

AaronRM commented Apr 3, 2026

@lalitb and @pritishnahar95 have some context in this area and may have feedback

Copy link
Copy Markdown
Contributor

@lquerel lquerel left a comment

Choose a reason for hiding this comment

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

LGTM

not(feature = "crypto-aws-lc"),
not(feature = "crypto-openssl")
))]
{
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This looks unsafe with experimental-tls: crypto-native-tls skips rustls provider installation here, but experimental-tls still uses rustls-based code paths that require a default provider. That means the build can succeed and then fail at runtime. Can we disallow that combination or still install a rustls provider in that case?

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

Labels

ci-repo Repository maintenance, build, GH workflows, repo cleanup, or other chores rust Pull requests that update Rust code

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

Support platform-native TLS backend (SChannel on Windows, OpenSSL on Linux) via crypto-native-tls feature

4 participants