Silverstripe cross-site scripting (XSS) attack in elemental "Content blocks in use" report
The advisory, in context
An elemental block can include an XSS payload, which can be executed when viewing the "Content blocks in use" report.
The vulnerability is specific to that report and is a result of failure to cast input prior to including it in the grid field.
References
Affected packages
Start with the recorded fix for your release branch. Check your installed version and test compatibility before upgrading. Fixing this advisory does not rule out other vulnerabilities in the release.
From 2.1.2 before 5.3.12
Fixed in 5.3.12
108 explicitly affected versions
2.1.2, 3.0.0, 3.0.0-beta1, 3.0.0-beta2, 3.0.0-beta3, 3.0.0-rc1, 3.0.0-rc2, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.1.3, 4.0.0, 4.0.0-beta1, 4.0.1, 4.0.2, 4.0.3, 4.0.4, 4.0.5, 4.1.0, 4.1.1, 4.10.0, 4.10.0-beta1, 4.10.0-rc1, 4.10.1, 4.10.2, 4.11.0, 4.11.0-beta1, 4.11.0-rc1, 4.11.1, 4.11.2, 4.11.3, 4.11.4, 4.11.5, 4.11.6, 4.11.7, 4.11.8, 4.11.9, 4.2.0, 4.2.0-beta1, 4.2.1, 4.3.0, 4.3.1, 4.3.2, 4.4.0, 4.4.0-rc1, 4.4.1, 4.5.0, 4.6.0, 4.6.0-beta1, 4.6.0-beta2, 4.6.0-rc1, 4.7.0, 4.7.1, 4.8.0, 4.8.0-beta1, 4.8.0-rc1, 4.8.1, 4.8.2, 4.8.3, 4.9.0, 4.9.0-beta1, 4.9.0-rc1, 4.9.1, 4.9.2, 4.9.3, 4.9.4, 5.0.0, 5.0.0-alpha1, 5.0.0-alpha2, 5.0.0-alpha3, 5.0.0-beta1, 5.0.0-beta2, 5.0.0-rc1, 5.0.1, 5.0.2, 5.0.3, 5.0.4, 5.1.0, 5.1.0-beta1, 5.1.0-rc1, 5.1.1, 5.1.2, 5.1.3, 5.1.4, 5.1.5, 5.2.0, 5.2.0-beta1, 5.2.0-rc1, 5.2.1, 5.2.2, 5.2.3, 5.2.4, 5.3.0, 5.3.0-beta1, 5.3.0-rc1, 5.3.1, 5.3.10, 5.3.11, 5.3.2, 5.3.3, 5.3.4, 5.3.5, 5.3.6, 5.3.7, 5.3.8, 5.3.9
View affected-version evidence
{
"ranges": [
{
"events": [
{
"introduced": "2.1.2"
},
{
"fixed": "5.3.12"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"2.1.2",
"3.0.0",
"3.0.0-beta1",
"3.0.0-beta2",
"3.0.0-beta3",
"3.0.0-rc1",
"3.0.0-rc2",
"3.0.1",
"3.0.2",
"3.1.0",
"3.1.1",
"3.1.2",
"3.1.3",
"4.0.0",
"4.0.0-beta1",
"4.0.1",
"4.0.2",
"4.0.3",
"4.0.4",
"4.0.5",
"4.1.0",
"4.1.1",
"4.10.0",
"4.10.0-beta1",
"4.10.0-rc1",
"4.10.1",
"4.10.2",
"4.11.0",
"4.11.0-beta1",
"4.11.0-rc1",
"4.11.1",
"4.11.2",
"4.11.3",
"4.11.4",
"4.11.5",
"4.11.6",
"4.11.7",
"4.11.8",
"4.11.9",
"4.2.0",
"4.2.0-beta1",
"4.2.1",
"4.3.0",
"4.3.1",
"4.3.2",
"4.4.0",
"4.4.0-rc1",
"4.4.1",
"4.5.0",
"4.6.0",
"4.6.0-beta1",
"4.6.0-beta2",
"4.6.0-rc1",
"4.7.0",
"4.7.1",
"4.8.0",
"4.8.0-beta1",
"4.8.0-rc1",
"4.8.1",
"4.8.2",
"4.8.3",
"4.9.0",
"4.9.0-beta1",
"4.9.0-rc1",
"4.9.1",
"4.9.2",
"4.9.3",
"4.9.4",
"5.0.0",
"5.0.0-alpha1",
"5.0.0-alpha2",
"5.0.0-alpha3",
"5.0.0-beta1",
"5.0.0-beta2",
"5.0.0-rc1",
"5.0.1",
"5.0.2",
"5.0.3",
"5.0.4",
"5.1.0",
"5.1.0-beta1",
"5.1.0-rc1",
"5.1.1",
"5.1.2",
"5.1.3",
"5.1.4",
"5.1.5",
"5.2.0",
"5.2.0-beta1",
"5.2.0-rc1",
"5.2.1",
"5.2.2",
"5.2.3",
"5.2.4",
"5.3.0",
"5.3.0-beta1",
"5.3.0-rc1",
"5.3.1",
"5.3.10",
"5.3.11",
"5.3.2",
"5.3.3",
"5.3.4",
"5.3.5",
"5.3.6",
"5.3.7",
"5.3.8",
"5.3.9"
]
}References
- https://github.com/silverstripe/silverstripe-elemental/security/advisories/GHSA-x8xm-c7p8-2pj2
- https://nvd.nist.gov/vuln/detail/CVE-2025-25197
- https://github.com/silverstripe/silverstripe-elemental/pull/1345
- https://github.com/silverstripe/silverstripe-elemental/commit/34ff4ed498ccab94cc5f55ef9a56c37f491eda1d
- https://github.com/FriendsOfPHP/security-advisories/blob/master/dnadesign/silverstripe-elemental/CVE-2025-25197.yaml
- https://github.com/silverstripe/silverstripe-elemental
- https://www.silverstripe.org/download/security-releases/cve-2025-25197