GHSA-wf6j-gr27-g7ch

Suggest an improvement
Source
https://github.com/advisories/GHSA-wf6j-gr27-g7ch
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/08/GHSA-wf6j-gr27-g7ch/GHSA-wf6j-gr27-g7ch.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-wf6j-gr27-g7ch
Aliases
  • CVE-2024-45747
Published
2026-08-19T19:31:54Z
Modified
2026-08-19T19:56:08Z
Severity
  • 7.2 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H CVSS Calculator
Summary
GeoServer has a Server-Side Template Injection (SSTI) vulnerability in processing FreeMarker templates
Details

Summary

A server-side template injection (SSTI) vulnerability exist that allows an authenticated administrator to upload FreeMarker templates containing malicious content that can execute OS commands and read from or write to arbitrary files on the server. These FreeMarker templates are used in a plain GeoServer instance (no extension or community modules) for WMS GetFeatureInfo HTML and JSON and WMS GetMap KML and GeoRSS output formats.

Details

The org.geoserver.template.TemplateUtils.getSafeConfiguration() method attempts to block access to the class freemarker.template.utility.Execute but it is still possible to gain access to it and other sensitive functionality by chaining a specific sequence of method calls.

Impact

This vulnerability can lead to executing arbitrary code and reading and writing arbitrary files.

Resolution

GeoServer 2.27.0 addresses this vulnerability with several new application properties:

  • GEOSERVER_FREEMARKER_BLOCK_LIST
  • GEOSERVER_FREEMARKER_ALLOW_LIST
  • GEOSERVER_FREEMARKER_API_EXPOSED

These application properties default to restricting the objects template authors can access, and limit access to "getter" methods used to access object properties.

Database specific
{
    "cwe_ids": [
        "CWE-749"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-08-19T19:31:54Z",
    "nvd_published_at": null,
    "severity": "HIGH"
}
References

Affected packages

Maven / org.geoserver:gs-main

Package

Name
org.geoserver:gs-main
View open source insights on deps.dev
Purl
pkg:maven/org.geoserver/gs-main

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
2.27.0

Database specific

source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/08/GHSA-wf6j-gr27-g7ch/GHSA-wf6j-gr27-g7ch.json"

Maven / org.geoserver:gs-wms

Package

Name
org.geoserver:gs-wms
View open source insights on deps.dev
Purl
pkg:maven/org.geoserver/gs-wms

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
2.27.0

Database specific

source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/08/GHSA-wf6j-gr27-g7ch/GHSA-wf6j-gr27-g7ch.json"

Maven / org.geoserver.web:gs-web-app

Package

Name
org.geoserver.web:gs-web-app
View open source insights on deps.dev
Purl
pkg:maven/org.geoserver.web/gs-web-app

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
2.27.0

Database specific

source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/08/GHSA-wf6j-gr27-g7ch/GHSA-wf6j-gr27-g7ch.json"