Vulnerability HighRUSTSEC-2024-0369 · phonenumber
RUSTSEC-2024-0369: phonenumber: panic on parsing crafted phonenumber inputs
Short answerA security vulnerability in the phonenumber crate: phonenumber: panic on parsing crafted phonenumber inputs. High severity (CVSS 8.6). Fixed in 0.3.6: update to a fixed version.
| Crate | phonenumber |
|---|---|
| Type | Vulnerability (denial-of-service) |
| Affected versions | From 0.3.3 before 0.3.6. |
| Fixed in | 0.3.6 |
| Severity | High, CVSS 8.6 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:N/A:H |
| Published | 2024-07-07 |
| Last changed | 2026-10-13 |
| Also known as | CVE-2024-39697, GHSA-mjw4-jj88-v687 |
| Affected functions | phonenumber::parse |
What to do
- See which version you have:
cargo tree -i phonenumber(it also shows which of your dependencies pulls it in). - Update within your version requirement:
cargo update -p phonenumber. If the fix is a newer major or minor than your requirement allows, raise it in Cargo.toml (for examplephonenumber = "0.3.6") or update the dependency that pulls it in. - Check again with
cargo audit, or paste your Cargo.lock into our Cargo.toml checker.
Details from the advisory
Impact
The phonenumber parsing code may panic due to a reachable assert! guard on the phonenumber string.
In a typical deployment of rust-phonenumber, this may get triggered by feeding a maliciously crafted phonenumber, e.g. over the network, specifically strings of the form +dwPAA;phone-context=AA, where the "number" part potentially parses as a number larger than 2^56.
Since f69abee1/0.3.4/#52.
0.2.x series is not affected.
Patches
Patches have been published as version 0.3.6+8.13.36.
References
- Package: crates.io/crates/phonenumber
- Advisory: rustsec.org/advisories/RUSTSEC-2024-0369.html
- Report: github.com/whisperfish/rust-phonenumber/issues/69
- Web: cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-39697
From the RustSec Advisory Database (CC0-1.0) via the OSV export, downloaded Oct 24, 2026. Severity score computed from the published CVSS vector.
Other advisories for phonenumber
Up next
Same cratephonenumber: security historyEvery advisory for this crate, and whether it is safe to use today.Read it next →Did this answer your question?