{"id":"CVE-2021-29932","aliases":["CVE-2021-29932","GHSA-qpgv-g792-wh6x","CAN-2021-1000007","RUSTSEC-2021-0041"],"related":[],"kind":"vulnerability","state":"published","title":"Uncontrolled Resource Consumption in parse_duration","summary":"An issue was discovered in the parse_duration crate through 2021-03-18 for Rust. It allows attackers to cause a denial of service (CPU and memory consumption) via a duration string with a large exponent.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"An issue was discovered in the parse_duration crate through 2021-03-18 for Rust. It allows attackers to cause a denial of service (CPU and memory consumption) via a duration string with a large exponent.","source":"cvelist"},{"lang":"en","text":"The `parse_duration::parse` function allows for parsing duration strings with exponents like `5e5s` where under the hood, the [`BigInt` type along with the `pow` function are used for such payloads](https://github.com/zeta12ti/parse_duration/blob/26940ab5cd4e3a9d6bd97aa101f8d4bbfd18ee8c/src/parse.rs#L335). Passing an arbitrarily big exponent makes the `parse_duration::parse` function to process the payload for a very long time taking up CPU and memory.\n\nThis allows an attacker to cause a DoS if the `parse_duration::parse` function is used to process untrusted input.","format":"markdown","source":"rustsec"},{"lang":"es","text":"Se detectó un problema en la crate parse_duration hasta el 18-03-2021 para Rust.&#xa0;Permite a atacantes causar una denegación de servicio (consumo de CPU y memoria) por medio de una cadena de duración con un gran exponente.","source":"nvd"}],"published":"2021-03-18T12:00:00.000Z","modified":"2026-06-17T03:48:27.800Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},"severities":[{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"RustSec Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:N/C:N/I:N/A:P","score":5,"rating":"MEDIUM"}],"cwes":["CWE-400","CWE-770"],"affected":[{"ranges":[{"version":"n/a","status":"affected"}],"source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","lastAffected":"2.1.1"}],"ecosystem":"crates.io","package":"parse_duration","purl":"pkg:cargo/parse_duration","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.0.0-0","status":"affected"}],"ecosystem":"crates.io","package":"parse_duration","purl":"pkg:cargo/parse_duration","source":"rustsec"},{"ranges":[{"status":"affected","lastAffected":"2021-03-18"}],"vendor":"parse_duration_project","product":"parse_duration","cpe":"cpe:2.3:a:parse_duration_project:parse_duration:*:*:*:*:*:rust:*:*","source":"nvd"}],"references":[{"url":"https://rustsec.org/advisories/RUSTSEC-2021-0041.html","tags":["advisory","vendor-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","rustsec","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-29932","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/zeta12ti/parse_duration/issues/21","tags":["report","web"],"sources":["ghsa","rustsec"]},{"url":"https://github.com/zeta12ti/parse_duration","tags":["package"],"sources":["ghsa"]},{"url":"https://crates.io/crates/parse_duration","tags":["package"],"sources":["rustsec"]}],"credits":[],"assigner":"mitre","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2021-29932","url":"https://www.cve.org/CVERecord?id=CVE-2021-29932","licence":"CVE Terms of Use","modified":"2024-08-03T22:18:03.277Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-qpgv-g792-wh6x","url":"https://github.com/advisories/GHSA-qpgv-g792-wh6x","licence":"CC-BY-4.0","modified":"2023-11-08T03:56:44.037Z"},{"source":"rustsec","name":"RustSec Advisory Database","id":"RUSTSEC-2021-0041","url":"https://rustsec.org/advisories/RUSTSEC-2021-0041.html","licence":"CC0-1.0","modified":"2023-11-08T03:56:44.037Z"},{"source":"nvd","name":"NVD","id":"CVE-2021-29932","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-29932","licence":"Public domain","modified":"2026-06-17T03:48:27.800Z"}],"updatedAt":"2026-11-25T22:58:00.538Z","epss":{"score":0.01036,"percentile":0.64828,"date":"2026-12-01T12:00:22.000Z"}}