cve.bz

CVE-2024-31996 xwiki xwiki: Code Injection

9.8 criticalExploit referenceEPSS 2.1%Fix available

Critical (9.8) in xwiki xwiki. EPSS 2.1% estimated probability of exploitation activity in the next 30 days. Fixed in org.xwiki.commons:xwiki-commons-velocity 14.10.19, 15.5.4, 15.9-rc-1.

On this page
XWiki Platform is a generic wiki platform. Starting in version 3.0.1 and prior to versions 4.10.19, 15.5.4, and 15.10-rc-1, the HTML escaping of escaping tool that is used in XWiki doesn't escape `{`, which, when used in certain places, allows XWiki syntax injection and thereby remote code execution. The vulnerability has been fixed in XWiki 14.10.19, 15.5.5, and 15.9 RC1. Apart from upgrading, there is no generic workaround. However, replacing `$escapetool.html` by `$escapetool.xml` in XWiki documents fixes the vulnerability. In a standard XWiki installation, the maintainers are only aware of the document `Panels.PanelLayoutUpdate` that exposes this vulnerability, patching this document is thus a workaround. Any extension could expose this vulnerability and might thus require patching, too.

Severity

CVSS 3.1

9.8 critical
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS
2.1% (unchanged from 2.1% a week ago; 2.1% 30 days ago) estimated probability of exploitation activity in the next 30 days; 82nd percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: PoC · Automatable: yes · Technical impact: total, assessed 2024-06-03. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWEs
CWE-94 Improper Control of Generation of Code (Code Injection)
CWE-95 Improper Neutralization of Directives in Dynamically Evaluated Code (Eval Injection)
OWASP Top 10
A05:2025 Injection
Published
Modified
NVD analysis
Analyzed
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2024-31996 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2024-31996?via=ask-ai-copy and https://cve.bz/cve/CVE-2024-31996?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2024-31996 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
xwiki:xwikifrom 3.0.1 before 14.10.19
xwiki:xwikifrom 15.0 before 15.5.4
xwiki:xwikifrom 15.6 before 15.9

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-hf43-47q4-fhq5Mavenorg.xwiki.commons:xwiki-commons-velocity>=3.0.1 <14.10.1914.10.19
GHSA-hf43-47q4-fhq5Mavenorg.xwiki.commons:xwiki-commons-velocity>=15.0-rc-1 <15.5.415.5.4
GHSA-hf43-47q4-fhq5Mavenorg.xwiki.commons:xwiki-commons-velocity>=15.6-rc-1 <15.9-rc-115.9-rc-1

Attack patterns (CAPEC)

  • CAPEC-35 Leverage Executable Code in Non-Executable Files Likelihood: High · Severity: Very High
  • CAPEC-77 Manipulating User-Controlled Variables Likelihood: High · Severity: Very High
  • CAPEC-242 Code Injection Likelihood: High · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON