{"id":"CVE-2026-40611","published":"2026-04-21T17:58:35Z","modified":"2026-07-15T01:00:42Z","title":"Lego: Arbitrary File Write via Path Traversal in Webroot HTTP-01 Provider","vendor":"go-acme","product":"lego","tier":"tail","description":{"text":"Let's Encrypt client and ACME library written in Go (Lego). Prior to 4.34.0, the webroot HTTP-01 challenge provider in lego is vulnerable to arbitrary file write and deletion via path traversal. A malicious ACME server can supply a crafted challenge token containing ../ sequences, causing lego to write attacker-influenced content to any path writable by the lego process. This vulnerability is fixed in 4.34.0.","provenance":"source","from":"CVE.org"},"cvss":{"score":8.8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00435,"percentile":0.38615,"provenance":"source"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"references":[{"url":"https://github.com/go-acme/lego/security/advisories/GHSA-qqx8-2xmm-jrv8","tags":["x_refsource_CONFIRM"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-40611","tags":["vdb-entry","x_refsource_REDHAT"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2460233","tags":["issue-tracking","x_refsource_REDHAT"]},{"url":"https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-40611.json","tags":["x_sadp-csaf-vex"]},{"url":"https://access.redhat.com/errata/RHSA-2026:21772","tags":["vendor-advisory","x_refsource_REDHAT"]}],"priority":{"score":13.9,"factors":[{"name":"EPSS percentile","points":7.72},{"name":"CVSS severity","points":6.16}]},"vendorSlug":"go-acme","affectedVersions":[{"vendor":"go-acme","product":"lego","versions":["< 4.34.0"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total","timestamp":"2026-04-21T19:17:50.782641Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"github.com/go-acme/lego/v4","vulnerableRanges":["<4.34.0"],"patched":["4.34.0"],"from":["GHSA-qqx8-2xmm-jrv8","GO-2026-5593"],"provenance":"source"},{"ecosystem":"Go","package":"github.com/go-acme/lego/v3","vulnerableRanges":["<=3.9.0"],"patched":[],"from":["GHSA-qqx8-2xmm-jrv8"],"provenance":"source"},{"ecosystem":"Go","package":"github.com/go-acme/lego","vulnerableRanges":["<=2.7.2"],"patched":[],"from":["GHSA-qqx8-2xmm-jrv8"],"provenance":"source"}],"summary":{"text":"Lego, the Let's Encrypt client and ACME library written in Go, has a path traversal flaw in its webroot HTTP-01 challenge provider, which fails to restrict challenge token paths to the intended webroot directory. An attacker who can act as a malicious ACME server can supply a crafted challenge token containing \"../\" sequences, causing lego to write attacker-influenced content, or delete files, at any path writable by the lego process, with exploitation requiring user interaction on the client side.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:49:42Z"},"euvd":{"id":"EUVD-2026-24219","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2025-54799","published":"2025-08-07","fixed":"4.25.2","kev":false,"link":{"from":"CVE-2025-54799","to":"CVE-2026-40611","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Go:github.com/go-acme/lego/v4","fromFixed":"4.25.2","toFixed":"4.34.0","daysApart":257}]}},{"cve":"CVE-2026-40611","published":"2026-04-21","fixed":"4.34.0","kev":false}],"package":"Go:github.com/go-acme/lego/v4"}}