Vulnerability DatabaseGHSA-xh92-rqrq-227v

GHSA-xh92-rqrq-227v
JavaScript vulnerability analysis and mitigation

Overview

The Mastra Docs MCP Server package (@mastra/mcp-docs-server), a Typescript framework for building AI agents and assistants, contains a Directory Traversal vulnerability in versions 0.13.8 through 0.13.20-alpha.0. The vulnerability was discovered on September 24, 2025, and has been assigned CVE-2025-61685. The vulnerability affects the documentation context server component used in AI-powered IDEs (GitHub Advisory).

Technical details

The vulnerability stems from a bypass of the path traversal security check in the readMdxContent function. While the code implements an initial security check to prevent path traversal for reading file contents, this protection is circumvented by subsequent logic in the findNearestDirectory function, which processes directory suggestions without proper path validation. The vulnerability has been assigned a CVSS v3.1 score of 6.5 (Medium) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N, indicating network accessibility with low attack complexity (GitHub Advisory).

Impact

The vulnerability allows attackers to list contents of arbitrary directories on the user's filesystem, including sensitive locations such as the user's home directory. This exposure can reveal the presence of sensitive tools (.BurpSuite), configuration files (.config), cloud credentials (.aws/, .gcp/), and private project directories, potentially providing valuable information for planning further targeted attacks (GitHub Advisory).

Mitigation and workarounds

The vulnerability has been fixed in version 0.13.20. The recommended fixes include halting execution immediately when readMdxContent detects a path traversal attempt and implementing defense-in-depth by applying path validation logic to the findNearestDirectory function. Users are advised to upgrade to the patched version 0.17.0 or later (GitHub Advisory).

Additional resources


SourceThis report was generated using AI

Related JavaScript vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-55182CRITICAL10
  • JavaScriptJavaScript
  • react-server-dom-webpack
NoYesDec 03, 2025
CVE-2025-66032HIGH8.7
  • JavaScriptJavaScript
  • @anthropic-ai/claude-code
NoYesDec 03, 2025
CVE-2025-66412HIGH8.5
  • JavaScriptJavaScript
  • @angular/compiler
NoYesDec 01, 2025
CVE-2025-66415MEDIUM6.9
  • JavaScriptJavaScript
  • @fastify/reply-from
NoYesDec 01, 2025
CVE-2025-66404MEDIUM6.4
  • JavaScriptJavaScript
  • mcp-server-kubernetes
NoYesDec 03, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management