7.2
HIGH CVSS 3.1
CVE-2024-45747
GeoServer Server-Side Template Injection Remote Code Execution
Description

### 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.

INFO

Published Date :

Aug. 19, 2026, 7:31 p.m.

Last Modified :

Aug. 19, 2026, 7:31 p.m.

Remotely Exploit :

Yes !

Source :

github-security-advisories
Affected Products

The following products are affected by CVE-2024-45747 vulnerability. Even if cvefeed.io is aware of the exact versions of the products that are affected, the information is not represented in the table below.

ID Vendor Product Action
1 Osgeo geoserver
CVSS Scores
The Common Vulnerability Scoring System is a standardized framework for assessing the severity of vulnerabilities in software and systems. We collect and displays CVSS scores from various sources for each CVE.
Score Version Severity Vector Exploitability Score Impact Score Source
CVSS 3.1 HIGH github
Solution
Update GeoServer to version 2.27.0 or later to address template injection.
  • Update GeoServer to 2.27.0 or higher.
  • Configure new application properties for FreeMarker.
  • Restrict access to template objects.
  • Limit access to getter methods.
CWE - Common Weakness Enumeration

While CVE identifies specific instances of vulnerabilities, CWE categorizes the common flaws or weaknesses that can lead to vulnerabilities. CVE-2024-45747 is associated with the following CWEs:

Common Attack Pattern Enumeration and Classification (CAPEC)

Common Attack Pattern Enumeration and Classification (CAPEC) stores attack patterns, which are descriptions of the common attributes and approaches employed by adversaries to exploit the CVE-2024-45747 weaknesses.

We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).

Results are limited to the first 15 repositories due to potential performance issues.

The following list is the news that have been mention CVE-2024-45747 vulnerability anywhere in the article.

EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days. Following chart shows the EPSS score history of the vulnerability.