# CVE-2026-45721: xyproto Algernon remote code execution via handler.lua path traversal

Source: https://junglewise.ai/threats/cve-2026-45721-xyproto-algernon-remote-code-execution-via-handler-lua-path  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-05-26. Updated: 2026-05-26  
License: CC BY 4.0 with a link back

CVE-2026-45721 · Severity: critical · CVSS 9 · Published 2026-05-26

Algernon is a standalone web server and application engine. A vulnerability in how the server searches for configuration files allows it to execute scripts found outside of the intended web directory. If an attacker or another process can place a specific script file in a parent directory on the server's host, they can achieve full remote code execution and gain complete control over the server and its data without needing to log in.

Technologies: [github.com/xyproto/algernon (Go)](https://junglewise.ai/threats/technologies/github-com-xyproto-algernon), [Xyproto Algernon](https://junglewise.ai/threats/technologies/algernon). Vendors: [Go](https://junglewise.ai/threats/vendors/go), [Xyproto](https://junglewise.ai/threats/vendors/xyproto).

## Quick answers

**Is CVE-2026-45721 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-45721 being exploited in the wild.

**How severe is CVE-2026-45721?** Critical severity, with a CVSS score of 9, published 26 May 2026.

**Which products and versions are affected?** github.com/xyproto/algernon (Go) <= 1.17.6, SEMVER:introduced=0,fixed=1.17.7; Xyproto Algernon < 1.17.7, <= 1.17.6.

**Is there a fix for CVE-2026-45721?** Yes. github.com/xyproto/algernon (Go): upgrade to 1.17.7 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-45721 attacked?** It is attacked over the network, in a hosted service.

**Am I affected by CVE-2026-45721?** Check whether you run github.com/xyproto/algernon (Go) or Xyproto Algernon at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- github.com/xyproto/algernon (Go): upgrade to 1.17.7 or later

  ```sh
  go get github.com/xyproto/algernon@v1.17.7
  ```


## Technical details

The vulnerability exists in the 'DirPage' function within 'engine/dirhandler.go'. When a requested URL resolves to a directory without an index file, the server performs an unbounded upward search (up to 100 iterations) for a file named 'handler.lua'. Because the loop does not stop at the configured server root, it can reach the filesystem root (/ or drive letter). If such a file is found, it is executed in a Lua interpreter with full access to the Algernon API, including 'os.execute' and 'io.popen'. This occurs before authentication checks are finalized, allowing an unauthenticated remote attacker to trigger the execution of a malicious script if they can place it in any parent directory of the web root.

## Affected products

- xyproto Algernon < 1.17.7

## Identifiers

- CVE-2026-45721
- GHSA-xwcr-wm99-g9jc
- GO-2026-5772

## Timeline

- 2026-05-12: advisory: GitHub Security Advisory published
- 2026-05-26: disclosed: CVE-2026-45721 published to NVD
- 2026-05-26: patched: Fixed in version 1.17.7

## References

- [https://github.com/xyproto/algernon/security/advisories/GHSA-xwcr-wm99-g9jc](https://github.com/xyproto/algernon/security/advisories/GHSA-xwcr-wm99-g9jc)

## Related threats

- [Algernon URL-prefix authorization bypass on case-insensitive filesystems](https://junglewise.ai/threats/cve-2026-68548-algernon-is-a-small-self-contained-pure-go-web-server-prior-to)
- [xyproto Algernon source disclosure via NTFS filename manipulation](https://junglewise.ai/threats/cve-2026-52792-xyproto-algernon-source-disclosure-via-ntfs-filename-manipulation)
- [GO-2026-5300 - Algernon: Auto-refresh SSE event server binds to all interfaces with Access-Control-Allow-Origin: * and…](https://junglewise.ai/threats/go-2026-5300-algernon-auto-refresh-sse-event-server-binds-to-all-459dcf1f)
- [xyproto Algernon path traversal and RCE via Host header](https://junglewise.ai/threats/cve-2026-48126-xyproto-algernon-path-traversal-and-rce-via-host-header)
- [xyproto Algernon permissive CORS policy in SSE event server](https://junglewise.ai/threats/cve-2026-46431-xyproto-algernon-permissive-cors-policy-in-sse-event-server)
