CVE-2025-58768: DeepChat's Mermaid rendering has XSS leading to RCE
DeepChat is a smart assistant uses artificial intelligence. Prior to version 0.3.5, in the Mermaid chart rendering component, there is a risky operation of directly using innerHTML to set user content. Therefore, any malicious content rendered via Mermaid will directly trigger the exploit chain, leading to command execution. This vulnerability is primarily caused by a failure to fully address the existing XSS issue in the project, leading to another exploit chain. The exploit chain is consistent with the report GHSA-hqr4-4gfc-5p2j, executing arbitrary JavaScript code via XSS and arbitrary commands via exposed IPC. Version 0.3.5 contains an updated fix.
Affected Software
Event History
Frequently Asked Questions
What is the severity of CVE-2025-58768?
CVE-2025-58768 has a high severity due to the potential for cross-site scripting (XSS) attacks.
How do I fix CVE-2025-58768?
To fix CVE-2025-58768, update DeepChat to version 0.3.5 or later where the vulnerable Mermaid chart rendering component is addressed.
What vulnerability does CVE-2025-58768 exploit?
CVE-2025-58768 exploits the use of `innerHTML` to render unverified user content, leading to XSS vulnerabilities.
What are the affected versions of DeepChat for CVE-2025-58768?
DeepChat versions prior to 0.3.5 are affected by CVE-2025-58768.
Is user data at risk due to CVE-2025-58768?
Yes, user data may be at risk due to malicious content being rendered that can exploit the vulnerability in CVE-2025-58768.