# CVE-2025-61685: Mastra Docs MCP Server `@mastra/mcp-docs-server` Leads to Information Exposure

- Severity: Medium 6.5 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.59%, higher than 49% of CVEs (2026-12-01)
- Published: 2025-09-24T20:05:15.000Z
- Modified: 2026-10-19T16:10:00.260Z
- Also known as: GHSA-xh92-rqrq-227v
- Weaknesses: CWE-548
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Mastra is a Typescript framework for building AI agents and assistants. Versions 0.13.8 through 0.13.20-alpha.0 are vulnerable to a Directory Traversal attack that results in the disclosure of directory listings. The code contains a security check to prevent path traversal for reading file contents, but this check is effectively bypassed by subsequent logic that attempts to find directory suggestions. An attacker can leverage this flaw to list the contents of arbitrary directories on the user's filesystem, including the user's home directory, exposing sensitive information about the file system's structure. This issue is fixed in version 0.13.20.

(As written by CVE List.)

## Affected

- mastra-ai mastra: <= 0.13.8, < 0.13.20
- @mastra/mcp-docs-server (npm): before 0.17.0

## Every score

- GitHub_M: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N`
- GitHub: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N`

## References

- <https://github.com/mastra-ai/mastra/security/advisories/GHSA-xh92-rqrq-227v> (web)
- <https://github.com/mastra-ai/mastra/commit/7f2b528ba82db512d68832d2f8ad6cbc8bb46cd4> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2025-61685> (advisory)
- <https://github.com/mastra-ai/mastra> (package)

## Sources

- CVE List: [CVE-2025-61685](https://www.cve.org/CVERecord?id=CVE-2025-61685), CVE Terms of Use, modified 2025-10-06
- GitHub Advisory Database: [GHSA-xh92-rqrq-227v](https://github.com/advisories/GHSA-xh92-rqrq-227v), CC-BY-4.0, modified 2025-10-13
- NVD: [CVE-2025-61685](https://nvd.nist.gov/vuln/detail/CVE-2025-61685), Public domain, modified 2026-10-19

---

Page: https://cve.day/CVE-2025-61685 · Whole record: https://cve.day/CVE-2025-61685.json · Rebuilt by cve.day 2026-11-25T22:59:05.509Z
