{"schemaVersion":3,"id":"CVE-2008-2942","aliases":["GHSA-v2gw-x5jf-pgwv","PYSEC-2026-666","DEBIAN-CVE-2008-2942"],"status":"published","duplicateOf":null,"title":null,"description":"Directory traversal vulnerability in patch.py in Mercurial 1.0.1 allows user-assisted attackers to modify arbitrary files via \"..\" (dot dot) sequences in a patch file.","dates":{"published":"2008-06-30T20:00:00.000Z","modified":"2024-08-07T09:21:34.414Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":6.8,"severity":"medium","version":"2.0","versionLabel":"v2.0","source":"NVD","vector":"AV:N/AC:M/Au:N/C:P/I:P/A:P","computed":false,"selection":"backend-summary"},"metrics":[{"version":"2.0","versionLabel":"v2.0","source":"NVD","score":6.8,"severity":"medium","vector":"AV:N/AC:M/Au:N/C:P/I:P/A:P","exploitability":null,"impact":null,"computed":false}]},"epss":{"probability":0.01901,"percentile":0.79396,"severity":"low","asOf":"2026-10-20T00:00:00.000Z","change":{"pp":0,"baselineDate":"2026-09-20T00:00:00.000Z","baselineScore":0.01901},"history":[{"date":"2026-09-14T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-15T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-16T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-17T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-18T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-19T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.01901,"percentile":0.79396}],"last30":[{"date":"2026-09-20T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.01901,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.01901,"percentile":0.79396}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[{"id":"REF_E08E104AB0B927E1","name":"Exploit Reference (selenic.com)","source":"reference","url":"http://www.selenic.com/hg/rev/87c704ac92d4","maturity":"unknown","reliabilityScore":0.2,"verified":false,"type":null,"platforms":[],"requiresAuth":null,"exploitdb":null,"metasploit":null}],"exploitCount":1,"weaknesses":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')","description":"The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.","type":"weakness","status":"Stable","abstraction":"Base","likelihoodOfExploit":"High","url":"https://cwe.mitre.org/data/definitions/22.html"}],"affected":[{"vendor":"debian","product":"mercurial","name":"mercurial","label":"mercurial","ecosystem":"Debian","cpePart":null,"purl":"pkg:deb/debian/mercurial","purlType":"deb","versions":[{"text":"< 1.0.1-2","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 1.0.1-2","eol":null,"hubHref":null},{"vendor":"mercurial","product":"mercurial","name":"mercurial","label":"mercurial","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"1.0.1","noFixRecorded":false,"fixedIn":null}],"versionsText":"1.0.1","eol":null,"hubHref":"/vendor/mercurial/mercurial"},{"vendor":"PyPI","product":"mercurial","name":"mercurial","label":"mercurial","ecosystem":"PyPI","cpePart":null,"purl":"pkg:pypi/mercurial","purlType":"pypi","versions":[{"text":"< 1.0.2","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 1.0.2","eol":null,"hubHref":null}],"affectedCount":3,"eol":{"hasEol":false,"count":0},"references":[{"url":"http://www.selenic.com/hg/rev/87c704ac92d4","label":"www.selenic.com/hg/rev/87c704ac92d4","hostname":"www.selenic.com","tags":["X Refsource CONFIRM","Exploit","WEB"]},{"url":"https://exchange.xforce.ibmcloud.com/vulnerabilities/43551","label":"exchange.xforce.ibmcloud.com/vulnerabilities/43551","hostname":"exchange.xforce.ibmcloud.com","tags":["VDB Entry","X Refsource XF","WEB"]},{"url":"http://www.securityfocus.com/bid/30072","label":"www.securityfocus.com/bid/30072","hostname":"www.securityfocus.com","tags":["VDB Entry","X Refsource BID","WEB"]},{"url":"https://issues.rpath.com/browse/RPL-2633","label":"issues.rpath.com/browse/RPL-2633","hostname":"issues.rpath.com","tags":["X Refsource CONFIRM","WEB"]},{"url":"http://www.openwall.com/lists/oss-security/2008/06/30/1","label":"www.openwall.com/lists/oss-security/2008/06/30/1","hostname":"www.openwall.com","tags":["Mailing List","X Refsource MLIST","WEB"]},{"url":"http://lists.opensuse.org/opensuse-security-announce/2008-07/msg00006.html","label":"lists.opensuse.org/opensuse-security-announce/2008-07/msg00006.html","hostname":"lists.opensuse.org","tags":["Vendor Advisory","X Refsource SUSE","WEB"]},{"url":"http://wiki.rpath.com/Advisories:rPSA-2008-0211","label":"wiki.rpath.com/Advisories:rPSA-2008-0211","hostname":"wiki.rpath.com","tags":["X Refsource CONFIRM","WEB"]},{"url":"http://www.securityfocus.com/archive/1/493881/100/0/threaded","label":"www.securityfocus.com/archive/1/493881/100/0/threaded","hostname":"www.securityfocus.com","tags":["Mailing List","X Refsource BUGTRAQ","WEB"]},{"url":"http://security.gentoo.org/glsa/glsa-200807-09.xml","label":"security.gentoo.org/glsa/glsa-200807-09.xml","hostname":"security.gentoo.org","tags":["Vendor Advisory","X Refsource GENTOO","WEB"]},{"url":"http://www.openwall.com/lists/oss-security/2008/07/01/1","label":"www.openwall.com/lists/oss-security/2008/07/01/1","hostname":"www.openwall.com","tags":["Mailing List","X Refsource MLIST","WEB"]},{"url":"http://secunia.com/advisories/31110","label":"secunia.com/advisories/31110","hostname":"secunia.com","tags":["Third Party Advisory","X Refsource SECUNIA","WEB"]},{"url":"http://secunia.com/advisories/31167","label":"secunia.com/advisories/31167","hostname":"secunia.com","tags":["Third Party Advisory","X Refsource SECUNIA","WEB"]},{"url":"http://secunia.com/advisories/31108","label":"secunia.com/advisories/31108","hostname":"secunia.com","tags":["Third Party Advisory","X Refsource SECUNIA","WEB"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2008-2942","label":"nvd.nist.gov/vuln/detail/CVE-2008-2942","hostname":"nvd.nist.gov","tags":["Advisory"]},{"url":"https://github.com/dscho/hg","label":"github.com/dscho/hg","hostname":"github.com","tags":["PACKAGE"]},{"url":"https://pypi.org/project/mercurial","label":"pypi.org/project/mercurial","hostname":"pypi.org","tags":["PACKAGE"]},{"url":"https://github.com/advisories/GHSA-v2gw-x5jf-pgwv","label":"github.com/advisories/GHSA-v2gw-x5jf-pgwv","hostname":"github.com","tags":["Advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2008-2942","label":"security-tracker.debian.org/tracker/CVE-2008-2942","hostname":"security-tracker.debian.org","tags":["Advisory"]}],"lineage":{"upstream":[],"downstream":["OPENSUSE-SU-2024:10586-1"],"duplicates":[],"related":["OPENSUSE-SU-2024:10586-1"]},"timeline":[{"kind":"published","date":"2008-06-30T20:00:00.000Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2024-08-07T09:21:34.414Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"risk":{"score":38,"level":"medium","profile":"Default","thresholds":{"critical":75,"high":50,"medium":25,"low":10}},"meta":{"dataAsOf":"2026-10-20T15:54:03.286Z","stale":false,"partial":false}}