{"id":"CVE-2024-31997","aliases":["GHSA-c2gg-4gq4-jv5j"],"url":"https://o3.security/vulnerability/CVE-2024-31997","summary":"XWiki Platform remote code execution from account through UIExtension parameters","details":"### Impact\nParameters of UI extensions are always interpreted as Velocity code and executed with programming rights. Any user with edit right on any document like the user's own profile can create UI extensions. This allows remote code execution and thereby impacts the confidentiality, integrity and availability of the whole XWiki installation.\n\nTo reproduce, edit your user profile with the object editor and add a UIExtension object with the following values:\n```\nExtension Point ID: org.xwiki.platform.panels.Applications\nExtension ID: platform.panels.myFakeApplication\nExtension parameters: \nlabel=I got programming right: $services.security.authorization.hasAccess('programming')\ntarget=Main.WebHome\ntargetQueryString=\nicon=icon:bomb\nExtension Scope: \"Current User\".\n```\n\nSave the document and open any document. If an application entry with the text \"I got programming right: true\" is displayed, the attack succeeded, if the code in \"label\" is displayed literally, the XWiki installation isn't vulnerable.\n\n### Patches\nThis vulnerability has been patched in XWiki 14.10.19, 15.5.4 and 15.9-RC1.\n\n### Workarounds\nWe're not aware of any workarounds apart from upgrading.\n\n### References\n* https://jira.xwiki.org/browse/XWIKI-21335\n* https://github.com/xwiki/xwiki-platform/commit/171e7c7d0e56deaa7b3678657ae26ef95379b1ea\n","published":"2024-04-10T21:55:43.475Z","modified":"2026-08-12T15:15:57.314273Z","cvss":{"score":9.9,"severity":"CRITICAL","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H"},"epss":{"score":0.73925,"percentile":0.99455,"asOf":"2026-09-17"},"cisaKev":null,"exploitsKnown":2,"affectedPackages":[{"ecosystem":"Maven","name":"org.xwiki.platform:xwiki-platform-uiextension-api","fixedVersion":"14.10.19"},{"ecosystem":"Maven","name":"org.xwiki.platform:xwiki-platform-uiextension-api","fixedVersion":"15.5.4"},{"ecosystem":"Maven","name":"org.xwiki.platform:xwiki-platform-uiextension-api","fixedVersion":"15.9-rc-1"}],"fix":{"url":"https://github.com/xwiki/xwiki-platform/commit/171e7c7d0e56deaa7b3678657ae26ef95379b1ea","label":"xwiki/xwiki-platform@171e7c7"},"references":[{"type":"WEB","url":"https://jira.xwiki.org/browse/XWIKI-21335"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/31xxx/CVE-2024-31997.json"},{"type":"ADVISORY","url":"https://github.com/xwiki/xwiki-platform/security/advisories/GHSA-c2gg-4gq4-jv5j"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-31997"},{"type":"FIX","url":"https://github.com/xwiki/xwiki-platform/commit/171e7c7d0e56deaa7b3678657ae26ef95379b1ea"},{"type":"FIX","url":"https://github.com/xwiki/xwiki-platform/commit/1b2574eb966457ca4ef34e557376b8751d1be90d"},{"type":"FIX","url":"https://github.com/xwiki/xwiki-platform/commit/56748e154a9011f0d6239bec0823eaaeab6ec3f7"},{"type":"PACKAGE","url":"https://github.com/xwiki/xwiki-platform"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-08-12T15:15:57.314273Z"}}