Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. mermaid
  4. ›
  5. CVE-2026-71438

CVE-2026-71438: Mermaid configuration APIs allow prototype pollution

August 6, 2026

Mermaid’s configuration setters (mermaid.initialize, mermaidAPI.setConfig, and mermaidAPI.updateSiteConfig) merge the caller-supplied configuration object into Mermaid’s internal config using the assignWithDepth deep-merge helper that is vulnerable to prototype pollution.

Because these APIs are intended to receive trusted configuration supplied by the application integrating Mermaid, Mermaid assesses the practical risk as low. The vulnerability is only reachable if an application forwards attacker-controlled data directly into one of these configuration entry points, which is outside their documented usage.

User-controlled configuration (e.g. configuration in diagram code using %%{init: {}}%% or YAML frontmatter) are already protected from prototype pollution.

References

  • github.com/advisories/GHSA-c4c3-pg64-4m4v
  • github.com/mermaid-js/mermaid/commit/2cd6dcf735533b323507e3e889ffdea870540b43
  • github.com/mermaid-js/mermaid/commit/c34b07a0815842327e70794d69b0c8c5a1e2a956
  • github.com/mermaid-js/mermaid/pull/8022
  • github.com/mermaid-js/mermaid/releases/tag/mermaid%4011.16.1
  • github.com/mermaid-js/mermaid/releases/tag/v10.9.8
  • github.com/mermaid-js/mermaid/security/advisories/GHSA-c4c3-pg64-4m4v
  • nvd.nist.gov/vuln/detail/CVE-2026-71438

Code Behaviors & Features

Detect and mitigate CVE-2026-71438 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 10.9.8, all versions starting from 11.0.0-alpha.1 before 11.16.1

Fixed versions

  • 10.9.8
  • 11.16.1

Solution

Upgrade to versions 10.9.8, 11.16.1 or above.

Impact 7.7 HIGH

CVSS:3.1/AV:L/AC:L/PR:H/UI:R/S:C/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')

Source file

npm/mermaid/CVE-2026-71438.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sat, 08 Aug 2026 00:17:29 +0000.