CVE-2026-42138: Dify Vulnerable to Stored XSS via SVG-file upload

Published May 4, 2026
·
Updated

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.

Affected Software

2 affected components
Dify dify<1.13.1
LangGenius Dify Node.js<1.13.1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade dify to a version that resolves this vulnerability.

    Fixed in 1.13.1

Event History

May 4, 2026
CVE Published
via MITRE·05:34 PM
Data Sourced
via MITRE·05:34 PM
DescriptionWeakness
Data Sourced
via NVD·06:16 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-42138?

The severity of CVE-2026-42138 is classified as high due to the potential for stored XSS attacks.

2

How do I fix CVE-2026-42138?

To fix CVE-2026-42138, update to Dify version 1.13.1 or later.

3

Who is affected by CVE-2026-42138?

Any user of Dify versions prior to 1.13.1 is affected by CVE-2026-42138.

4

What type of attack is associated with CVE-2026-42138?

CVE-2026-42138 is associated with stored XSS attacks via SVG-file uploads.

5

Can unauthenticated users exploit CVE-2026-42138?

Yes, unauthenticated users can exploit CVE-2026-42138 by uploading malicious SVG files.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203