CVE-2026-42138
Analyzed Analyzed - Analysis Complete
Unauthenticated SVG File Upload XSS in Dify

Publication date: 2026-05-04

Last updated on: 2026-05-11

Assigner: GitHub, Inc.

Description
Dify is an open-source LLM app development platform. Prior to version 1.13.1, using the method POST /api/files/upload, any unauthenticated user can upload an SVG file with XSS. The method POST /v1/files/upload, which requires authentication through the application API, is also vulnerable. This issue has been patched in version 1.13.1.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-05-04
Last Modified
2026-05-11
Generated
2026-06-16
AI Q&A
2026-05-05
EPSS Evaluated
2026-06-14
NVD
Affected Vendors & Products
Showing 1 associated CPE
Vendor Product Version / Range
langgenius dify to 1.13.1 (exc)
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-79 The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
Attack-Flow Graph
AI Quick Actions
Instant insights powered by AI
Executive Summary

This vulnerability exists in Dify, an open-source LLM app development platform, prior to version 1.13.1. It allows any unauthenticated user to upload an SVG file containing malicious code via the POST /api/files/upload method, leading to Cross-Site Scripting (XSS). Additionally, the authenticated method POST /v1/files/upload is also vulnerable. The issue has been fixed in version 1.13.1.

Impact Analysis

The vulnerability can allow attackers to execute malicious scripts in the context of the affected application by uploading SVG files with embedded XSS payloads. This can lead to unauthorized actions, data theft, session hijacking, or other malicious activities without requiring authentication.

Mitigation Strategies

To mitigate this vulnerability, you should upgrade Dify to version 1.13.1 or later, where the issue has been patched.

Chat Assistant
Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-42138. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70
EPSS Chart