Skip to content

fix(apns): remove vulnerable legacy tls dependencies - #217

Merged
ZingerLittleBee merged 2 commits into
mainfrom
fix/apns-tls-security
Oct 16, 2026
Merged

ZingerLittleBee merged 2 commits into
mainfrom
fix/apns-tls-security

Conversation

@ZingerLittleBee

Copy link
Copy Markdown
Owner

The legacy APNs channel depends on a2 0.10, which retains rustls 0.22 and vulnerable rustls-webpki 0.102.8. Replace that transport with the existing reqwest/ring stack, removing the old dependency chain without introducing new package versions. Cargo.lock now contains rustls 0.23.45 and rustls-webpki 0.103.15, covering Dependabot alerts 160, 194, 151, and 150.

Preserve existing APNs configuration, notification payloads, recipient ownership and migration checks, and snapshot-safe 410 Unregistered cleanup. The replacement uses HTTPS/HTTP2, ES256 JWT reuse/refresh, bounded payload and error bodies, and the legacy direct connection, 20-second request timeout and 600-second idle pool settings. Add real loopback TLS/HTTP2 tests and proxy-environment regression coverage. Shared reqwest clients can negotiate HTTP/2 while retaining HTTP/1.1 fallback.

Review and validation

Standards and specification reviews both passed for the full range from f9cbb8e3 to f42ad0bf with no findings.

At head f42ad0bfc12b19f383277896257b8f588d400c78:

  • cargo test -p serverbee-server --lib service::apns --locked: 14 passed, including JWT verification, TLS/HTTP2 dispatch, provider responses, token cleanup races and proxy isolation.
  • cargo clippy --workspace --benches --tests --examples --all-features --locked -- -D warnings: passed.
  • cargo test -p serverbee-agent --features reqwest/http2 --locked probe_utils: 65 passed.
  • cargo test -p serverbee-agent --features reqwest/http2 --locked ip_quality::http: 32 passed, including real local HTTP/1.1 response handling.
  • Agent navigation, integration-target coverage (47 targets), changed-file formatting and diff checks: passed.

Earlier regression at dede3c37, before the direct-connection/timeout compatibility correction: Server library 1,554, mobile push integration 90 and mobile API 95 tests passed; Relay 74 tests and typecheck passed. These are earlier-commit results, not a full-suite run at the final head.

Live Apple provider acceptance and physical-device notification presentation have not been verified. The committed certificates/private key are public loopback test fixtures, trusted only by the test client. Dependabot will reevaluate the alerts after the change reaches the default branch.

Replace a2 with HTTP/2 reqwest requests and cached ES256 provider tokens. Preserve legacy recipient fencing, notification payloads, and terminal token cleanup.
@vercel

vercel Bot commented Oct 6, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
serverbee-docs Ready Ready Preview Oct 6, 2026 3:34am UTC

@ZingerLittleBee
ZingerLittleBee merged commit 303f9e7 into main Oct 16, 2026
15 checks passed
@ZingerLittleBee
ZingerLittleBee deleted the fix/apns-tls-security branch October 16, 2026 04:45

This branch was successfully deployed

1 active deployment
Preview — f42ad0bf Deployed Oct 6, 2026 by vercel[bot]
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.

1 participant