Tokio broadcast channel calls clone in parallel, but does not require `Sync`GHSA-rr8g-9fpq-6wmg
Fix: tokio-rs/tokio#7232GHSA-rr8g-9fpq-6wmg is a security vulnerability in tokio. A fix is available for tokio — see the affected versions and patch details below.
Real-World Exposure
tokio🦀tokio🦀tokioReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects crates.io packages — download data is not available via public APIs for these ecosystems.
Description
The broadcast channel internally calls clone on the stored value when receiving it, and only requires T:Send. This means that using the broadcast channel with values that are Send but not Sync can trigger unsoundness if the clone implementation makes use of the value being !Sync.
Thank you to Austin Bonander for finding and reporting this issue.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🦀crates.io | tokio | ≥ 1.44.0&&< 1.44.2 | 1.44.2cargo update -p tokio --precise 1.44.2 |
| 🦀crates.io | tokio | ≥ 0.2.5&&< 1.38.2 | 1.38.2cargo update -p tokio --precise 1.38.2 |
| 🦀crates.io | tokio | ≥ 1.39.0&&< 1.43.1 | 1.43.1cargo update -p tokio --precise 1.43.1 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for tokio, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update tokio to 1.44.2 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-rr8g-9fpq-6wmg is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
Frequently Asked Questions
Is GHSA-rr8g-9fpq-6wmg in your dependencies?
Find it across crates.io, including transitive dependencies.