Go · Servers and applications
GHSA-gx7w-56w6-g48x
Caddy: Remote Admin Authorization Bypass on PKI Endpoints via Prefix-Based Path Matching
- Severity
- Medium 4.3
- Published
- 13 May 2026
- Last changed
- 24 Jul 2026
- Added to UpHeron
- 22 Oct 2026
- Fixed in
- 2.11.3
- Attack
- Over the network · Needs a user account · No user action needed
- Attacker can
- Read some data
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N- Also known as
- GO-2026-5408
- Sources
- OSV.dev and GitHub, Project advisories (GitHub)
Description
Caddy's remote admin access control performs path authorization using prefix matching:
- admin.go: strings.HasPrefix(r.URL.Path, allowedPath)
This allows a client certificate authorized only for /pki/ca/prod to access sibling PKI resources whose paths merely share the same prefix, such as /pki/ca/prod-backup.
This is an authorization bug in Caddy's source code, not a misconfiguration issue. The configured policy is more restrictive than the behavior that Caddy actually enforces.
In RemoteAdmin.enforceAccessControls(), allowed paths are checked like this:
This does not enforce a path-segment boundary.
So if the allowed path is:
/pki/ca/prod
then all of the following are treated as authorized:
- /pki/ca/prod-backup
- /pki/ca/prod1
- /pki/ca/prodanything
For PKI admin endpoints, the CA ID is taken directly from the request path:
- modules/caddypki/adminapi.go:164
Affected software
| Software | Affected versions |
|---|---|
CaddyServers and applications · github:caddyserver/caddy |
|
CaddyGo · osv:Go:github.com/caddyserver/caddy/v2 |
|
About Caddy
open source web server
- Share of websites with a known web server
- 1.3%W3Techs, Nov 2026
- Docker Hub pulls
- 770,668,265Docker Hub, 15 Nov 2026
- GitHub stars
- 79,049GitHub, 15 Nov 2026
- Forks
- 5,264GitHub, 15 Nov 2026
- Latest release
- v2.11.9GitHub, 15 Nov 2026
- Released
- 5 Nov 2026GitHub
- License
- Apache Software License 2.0Wikidata
- Written in
- GoWikidata
- First published on GitHub
- 13 Jan 2015GitHub
Website Source code Docker image
Vulnerabilities in Caddy
- In our list
- 30
- Published in the last 12 months
- 23
- Critical, last 12 months
- 0
- High, last 12 months
- 9
- Known exploited
- 1
- GHSA-f278-mgc7-46j3php_fastcgi authorization bypass via dot-segments in the request pathMedium 5.9 4 Nov 2026
- GHSA-jf74-f69g-hcj9file_server exposes private keys when the data directory falls back to ./caddyMedium 4 Nov 2026
- GHSA-69hv-5jfc-mvmvrewrite re-decodes {http.matchers.file.remainder}, bypassing path-based deny rulesMedium 4 Nov 2026
- GHSA-25cw-38mq-q7m6file matcher resolves /file/./ to a regular file, bypassing suffix path rulesMedium 4 Nov 2026
- GHSA-r766-rf9f-588hHost and :authority values with dot segments or slashes escape a {host}-based rootHigh 4 Nov 2026
- CVE-2026-55458Caddy has an RFC 7230 §6.1 compliance issue / Hop-by-hop headers that leak throughLow 2.9 13 Oct 2026
References
- GitHub Advisory Database https://github.com/advisories/GHSA-gx7w-56w6-g48x
- OSV.dev https://osv.dev/vulnerability/GO-2026-5408
- github.com https://github.com/caddyserver/caddy/security/advisories/GHSA-gx7w-56w6-g48x