Vulnerability · Published Apr 21, 2026 · Assigned by GitHub_M
CVE-2026-40611Lego: Arbitrary File Write via Path Traversal in Webroot HTTP-01 Provider
High 8.8
In plain English
A high-severity path traversal in lego from go-acme. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 36% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
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.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | golang-github-xenolf-lego | no fix listed | DEBIAN-CVE-2026-40611 |
| Debian:13 | golang-github-xenolf-lego | no fix listed | DEBIAN-CVE-2026-40611 |
| Debian:14 | golang-github-xenolf-lego | 4.35.2-1 | DEBIAN-CVE-2026-40611 |
| Go | github.com/go-acme/lego | no fix listed | GHSA-qqx8-2xmm-jrv8 |
| Go | github.com/go-acme/lego/v3 | no fix listed | GHSA-qqx8-2xmm-jrv8 |
| Go | github.com/go-acme/lego/v4 | 4.34.0 | GHSA-qqx8-2xmm-jrv8 |
| Go | github.com/go-acme/lego/v4 | 4.34.0 | GO-2026-5593 |
| Ubuntu:22.04:LTS | golang-github-xenolf-lego | no fix listed | UBUNTU-CVE-2026-40611 |
| Ubuntu:25.10 | golang-github-xenolf-lego | no fix listed | UBUNTU-CVE-2026-40611 |
| Ubuntu:26.04:LTS | golang-github-xenolf-lego | no fix listed | UBUNTU-CVE-2026-40611 |
| Ubuntu:26.10 | golang-github-xenolf-lego | no fix listed | UBUNTU-CVE-2026-40611 |
Affected products (as reported)
Weakness: CWE-22 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
References
- https://github.com/go-acme/lego/security/advisories/GHSA-qqx8-2xmm-jrv8 x_refsource_CONFIRM
- https://access.redhat.com/security/cve/CVE-2026-40611 vdb-entry, x_refsource_REDHAT
- RHBZ#2460233 issue-tracking, x_refsource_REDHAT
- https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-40611.json x_sadp-csaf-vex
- https://access.redhat.com/errata/RHSA-2026:21772 vendor-advisory, x_refsource_REDHAT