CVE-2026-84939 GHSA-27j2-h3m2-8237 freemarker: Path traversal in template loading via malformed locale (2.3.31 -> 2.3.35) - #1142
Merged
vharseko merged 1 commit intoSep 25, 2026
Conversation
Bumps org.freemarker:freemarker from 2.3.31 to 2.3.35. --- updated-dependencies: - dependency-name: org.freemarker:freemarker dependency-version: 2.3.35 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
vharseko
approved these changes
Sep 25, 2026
vharseko
deleted the
dependabot/maven/org.freemarker-freemarker-2.3.35
branch
September 25, 2026 08:50
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bumps
org.freemarker:freemarkerfrom 2.3.31 to 2.3.35 (freemarker.versionin the rootpom.xml), clearing Dependabot alert #324.Advisory
CVE-2026-84939 / GHSA-27j2-h3m2-8237 — Path traversal (CWE-23) in the FreeMarker template loading mechanism. If an attacker can pass an arbitrary malformed locale identifier to FreeMarker and localized lookup is enabled (the default), the localized template name built from that locale can escape the intended template path. What can be read is still bounded by the configured
TemplateLoader:FileTemplateLoaderstays inside itsbaseDir, a class-loader based loader can reach only what the class loader can load, a servlet-context loader only what the web application context exposes. 2.3.35 fixes the lookup (apache/freemarker@83953d9); disabling localized lookup mitigates older versions.AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N)org.freemarker:freemarker>= 2.2.0, <= 2.3.34Impact on OpenAM
Low. FreeMarker ships in the WAR (
openam-server-only) and is used by the OAuth2 provider to render its HTML pages (authorization consent, device code verification,form_postresponse) throughorg.forgerock.oauth2.restlet.TemplateFactory. That factory builds a singleConfigurationwith aMultiTemplateLoaderover Restlet'sContextTemplateLoader("clap:///")and aClassTemplateLoader, and loads templates withconfig.getTemplate(name)— i.e. with the configuration's default locale (the JVM default). No request-controlled locale reaches FreeMarker, so the attacker-supplied locale the advisory requires is not available, and both loaders are confined to class-path resources anyway. The ClickFreemarkerTemplateServiceis referenced only in Javadoc. The bump takes the shipped library out of the vulnerable range.Change
freemarker.version:2.3.31→2.3.35in the rootpom.xml.org.restlet.ext.freemarkeralready excludes its own FreeMarker, so the managed version is the one that ends up in the WAR. No code or behaviour change.References