Reflected XSS in /api/icon/getDynamicIcon due to unsanitized SVG input.
The endpoint generates SVG images for text icons (type=8). The content query parameter is inserted directly into the SVG tag without XML escaping. Since the response Content-Type is image/svg+xml, injecting unescaped tags allows breaking the XML structure and executing JavaScript.
Payload: test</text><script>alert(window.origin)</script><text>
Open any note and click Change Icon -> Dynamic (Text).
Change color and paste the payload into the Custom field and click on this icon.
Intercept and send the request or get path from devtools
The JavaScript payload executes afted open URL.
Arbitrary JavaScript execution in the user's session context if the SVG is loaded directly. It also prevents using legitimate characters like < or > in icon text.
Tested version:
{
"cwe_ids": [
"CWE-79"
],
"github_reviewed": true,
"github_reviewed_at": "2026-01-21T01:00:44Z",
"nvd_published_at": "2026-01-19T20:15:49Z",
"severity": "LOW"
}