craftcms/cms · Security
CraftCMS stored XSS in Quick Post widget error message
- GHSA ID
- GHSA-3wxg-w96j-8hq9
- CVE ID
- CVE-2023-33194
- Severity
- low
- Published
- Updated
- CVSS
- 3.7 · CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:L/I:N/A:L
- CVSS v3
- 3.7 · CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:L/I:N/A:L
Description
Summary
The platform does not filter input and encode output in Quick Post validation error message, which can deliver an XSS payload.
Details
Old CVE fixed the XSS in label HTML but didn’t fix it when clicking save.
PoC
-
Login at admin
-
Go to setting
-
Create a Section
-
On Entry page, click Edit label
-
Inject the XSS payload into the label and save
-
On the admin dashboard choose new widget -> Quick Post
-
In Quick Post, click save with blank slug; The XSS will be executed
"errors":{"title":["alert('nono') cannot be blank."],"slug":["Slug cannot be blank."]
Fixed in https://github.com/craftcms/cms/commit/9d0cd0bda7c8a830a3373f8c0f06943e519ac888
CWEs
- CWE-79 · Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
- CWE-80 · Improper Neutralization of Script-Related HTML Tags in a Web Page (Basic XSS)
References
- https://github.com/craftcms/cms/security/advisories/GHSA-3wxg-w96j-8hq9 ↗
- https://github.com/craftcms/cms/releases/tag/4.4.6 ↗
- https://nvd.nist.gov/vuln/detail/CVE-2023-33194 ↗
- https://github.com/craftcms/cms/commit/9d0cd0bda7c8a830a3373f8c0f06943e519ac888 ↗
- https://github.com/advisories/GHSA-3wxg-w96j-8hq9 ↗