Skip to content
XSS Write-up Intermediate

CVE-2025-63872: SVG-Based XSS in DeepSeek Chat V3.2

DeepSeek Chat's web interface inserted model-generated SVG fragments into the DOM without sanitising event attributes or scriptable constructs. An attacker could achieve arbitrary JavaScript execution in the victim's browser simply by having them view a crafted message.

medium.com

Published on medium.com

A client-side XSS vulnerability allowing JavaScript execution through model-generated SVG content.

Vinit Kundu, on medium.com

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

The chat interface rendered model-generated SVG directly into the page without sanitising event attributes, scriptable elements or external references.

Impact

Successful exploitation could allow arbitrary JavaScript execution in the DeepSeek Chat domain, potentially leading to session compromise, CSRF actions, UI manipulation and data exfiltration, with no user interaction beyond viewing the message.

What the attacker needed

Victim views a crafted message; no vendor patch available

The fix

The vendor should sanitise SVG with an SVG-safe sanitiser, strip event attributes and scriptable elements, apply a strict Content Security Policy, and consider rasterising or sandboxing SVG rendering; no patch is available.

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.

A web page can include pictures described in a format called SVG. Unlike ordinary images, SVG files can contain small programs, and browsers will run them. DeepSeek Chat displayed SVG text produced by the AI model without cleaning it first, so a message could carry a hidden program that runs in the reader's browser.

What is XSS?

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.

Similar reports

View all

Same bug class and techniques, clearest first.

Cross-site scripting (XSS)

The lesson behind this report.

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.