CVE-2023-26140: Excalidraw Cross-site Scripting in canvas element links

CVE-2023-26140 · Severity: low · CVSS 3.1 · Published 2023-08-16

Excalidraw is a popular open-source drawing application. The library improperly sanitizes URLs attached to canvas elements, allowing attackers to inject malicious scripts. Users who share drawings containing malicious links with others could enable attackers to steal data or perform actions on behalf of victims.

Technologies: Excalidraw, @excalidraw/excalidraw (npm). Vendors: Excalidraw, npm.

Quick answers

Is CVE-2023-26140 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2023-26140 being exploited in the wild.
How severe is CVE-2023-26140?
Low severity, with a CVSS score of 3.1, published 16 August 2023.
Which products and versions are affected?
Excalidraw prior to 0.15.3; @excalidraw/excalidraw (npm) SEMVER:introduced=0,fixed=0.15.3.
Is there a fix for CVE-2023-26140?
Yes. @excalidraw/excalidraw (npm): upgrade to 0.15.3 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2023-26140 attacked?
It is attacked over the network.
Am I affected by CVE-2023-26140?
Check whether you run Excalidraw or @excalidraw/excalidraw (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • @excalidraw/excalidraw (npm): upgrade to 0.15.3 or later
    npm install @excalidraw/excalidraw@0.15.3

Technical details

This is a Cross-site Scripting (CWE-79) vulnerability in @excalidraw/excalidraw prior to version 0.15.3, caused by improper neutralization of URLs in canvas element links. The vulnerability requires network access and user interaction (the victim must open a shared drawing with a malicious link). An attacker can craft a drawing with a specially-crafted URL that executes arbitrary JavaScript in the victim's browser, allowing data exfiltration or session hijacking. The vulnerability is only exploitable when untrusted user input is accepted in drawings that are shared with others. A patch is available in version 0.15.3 and later.

Affected products

  • Excalidraw excalidraw prior to 0.15.3

Identifiers

  • CVE-2023-26140
  • GHSA-v7v8-gjv7-ffmr

Timeline

  • 2023-08-16: disclosed
  • 2023-08-16: patched: Version 0.15.3 released with patch

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.