CVE-2023-26465 - Breaking Through XSS Filters in Pega Platform
A stored cross-site scripting vulnerability existed in Pega Platform's Pulse feature, where markdown syntax and user mentions could be combined to bypass XSS filters. An attacker could execute arbitrary JavaScript in a victim's browser.
Published on secforce.com
Last year we identified an interesting XSS vulnerability involving the clever use of markdown syntax and user mentioning in the Pega Platform. This post delves into details of the PoC, providing a concise yet thorough analysis of how arbitrary JavaScript code could be executed within the application.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the application failed to properly sanitise user-controlled input when combining markdown rendering and user mentions, allowing HTML attribute escaping and nested tags to bypass XSS filters.
Impact
An attacker could execute arbitrary JavaScript in the context of the application, potentially leading to account compromise or data theft.
What the attacker needed
Access to Pega Pulse; ability to post messages with mentions
The fix
The vulnerability was fixed in a later version, as indicated by the security advisory.
How it was found
- Notice that user mentions can escape quotes in anchor tags.
- Observe that limited markdown syntax (images, links) is usable and produces controlled alt text.
- Combine mention-based quote escaping with nested markdown to bypass HTML tag stripping.
- Construct a payload that results in stored XSS.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
This report describes a stored cross-site scripting (XSS) bug. XSS lets an attacker inject malicious JavaScript into a web page that other users view, so the script runs in their browsers. Here, the attacker used special formatting (markdown) and user mentions to sneak the script past the site's filters.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.