Impact
The vulnerability allows an attacker to upload any SVG file that contains malicious embedded scripts without sanitization. When a user opens or views the uploaded SVG, the script executes in that user’s browser session, enabling the attacker to run arbitrary JavaScript in the context of the hosting web application. This can lead to theft of session cookies, defacement, credential theft, or redirection to phishing sites, as the injected code has the same privileges as the victim’s browser. The weakness is identified as CWE‑79, a flaw involving improper handling of untrusted script content.
Affected Systems
All installations of the langgenius Dify platform running versions earlier than 1.13.1 are affected. Both the publicly accessible file upload endpoint POST /api/files/upload and the authenticated API endpoint POST /v1/files/upload are vulnerable, so guests and authenticated users alike can upload malicious SVGs that are later stored and served back to users.
Risk and Exploitability
With a CVSS score of 6.9 the flaw is considered moderate in severity. No EPSS score is available and the issue is not listed in the CISA KEV catalog. The likely attack vector is an unauthenticated or authenticated web or API request over the network; an attacker can simply upload a crafted SVG file and then entice or force a victim to view the file, thereby triggering the stored XSS payload.
OpenCVE Enrichment