CVE-2018-13346
HIGH 7.5CVSS 3.0Mercurial Improper Input Validation vulnerability
The mpatch_apply function in mpatch.c in Mercurial before 4.6.1 incorrectly proceeds in cases where the fragment start is past the end of the original data, aka OVE-20180430-0004.
- Published
- 6 Jul 2018
- Last modified
- 17 Jun 2026
- Assigned by
- cve@mitre.org
- NVD status
- Modified
- Weakness
- CWE-20
- Also known as
- GHSA-9xv4-r2hf-26ghPYSEC-2018-88
- Sources
- NVDJSONOSV GHSA-9xv4-r2hf-26ghJSONOSV PYSEC-2018-88JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| OSV | GitHub | CVSS 4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N | |
| NVD | nvd@nist.gov (Primary) | CVSS 3.0 | HIGH 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N |
| OSV | GitHub | CVSS 3.0 | HIGH 7.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | MEDIUM 5.0 | AV:N/AC:L/Au:N/C:N/I:P/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | mercurial | mercurialcpe:2.3:a:mercurial:mercurial:*:*:*:*:*:*:*:* |
< 4.6.1 | 4.6.1 |
| OSV | PyPI | mercurial | < 4.6.1 | 4.6.1 |
References
- https://access.redhat.com/errata/RHSA-2019:2276 · WEB, ADVISORY
- https://lists.debian.org/debian-lts-announce/2020/07/msg00032.html · WEB
- https://www.mercurial-scm.org/repo/hg/rev/faa924469635 · Patch, Third Party Advisory, WEB
- https://www.mercurial-scm.org/wiki/WhatsNew#Mercurial_4.6.1_.282018-06-06.29 · Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2018-13346 · ADVISORY
- https://github.com/pypa/advisory-database/tree/main/vulns/mercurial/PYSEC-2018-88.yaml · WEB
- https://github.com/advisories/GHSA-9xv4-r2hf-26gh · ADVISORY
History
- 25 Nov 2026 20:21 UTC · NVD: first stored (published 6 Jul 2018)
- 25 Nov 2026 20:12 UTC · OSV: first stored (published 6 Jul 2018)
- 25 Nov 2026 20:11 UTC · OSV: first stored (published 13 May 2022)