Test local filesystem MCP servers for path-traversal containment and search speed
Compare filesystem and code-editing MCP servers on symlink escape prevention, ripgrep integration, and partial-file edit reliability.
Key criteria for evaluating filesystem MCP servers
- 01
Verify canonical realpath containment checks
Naive prefix string checks fail on symlinks or case-insensitive drives; audit realpath verification on every read and write.
- 02
Ensure .gitignore and node_modules exclusion
Recursive directory tools that traverse build artifacts or .git objects freeze agents and leak environment files.
- 03
Compare line-numbered ranged reads
Agents edit far more accurately when file read tools return explicit line numbers and byte-capped slices.
- 04
Check atomic write and diff preview support
Top servers support dry-run unified diff previews and atomic temp-file writes to prevent half-written source files.
How it works in practice
Security & editing test
Test 4 filesystem MCP servers on 50 multi-hunk file edits + 12 symlink escape vectors pointing to ~/.ssh.
Audit & benchmark table
fs-sandbox-mcp v2.1: 0/12 escapes allowed, 97% clean multi-hunk edits, respects .gitignore. legacy-fs-mcp v0.6: 2/12 symlink escapes succeeded, 79% clean edits, scans node_modules.
Canonical symlink resolution and .gitignore-aware search are non-negotiable before granting local workspace access.
Questions and answers
How can a filesystem MCP server leak files outside an allowed directory?
If a server validates paths before resolving symbolic links—or mishandles parent directory creation—an agent or malicious repo symlink can read ~/.aws or ~/.ssh.
Why does .gitignore support matter for speed benchmarks?
Without .gitignore filtering, a single search tool call across node_modules or .venv can stall for 20+ seconds and overflow output limits.
Do benchmarks test Windows path separators as well as POSIX?
Yes, path normalization and drive-letter traversal checks run across Linux, macOS, and Windows path conventions.
Related tasks in this category
See all in MCP Server Benchmarks & Tool Reliability-
Benchmark PostgreSQL MCP servers on SQL accuracy, schema discovery, and read-only safety
Compare official, community, and vendor Postgres MCP servers on multi-join accuracy, timeout protection, and transaction read-only enforcement.
-
Compare GitHub and GitLab MCP servers on tool-call precision and context efficiency
Official Git MCP servers expose dozens of tools that can overwhelm small context windows. Compare lean vs full-featured connectors.
-
Compare Slack and team chat MCP servers on thread context retrieval and post safety
Find chat MCP connectors that resolve user IDs cleanly, preserve nested thread replies, and block accidental channel-wide @here blasts.
-
Rank Jira and Linear MCP servers for ticket triage, custom fields, and state sync
Compare issue-tracker MCP connectors on JQL/GraphQL query precision, custom field validation, and duplicate ticket prevention.
-
Benchmark Qdrant, Pinecone, and pgvector MCP servers on hybrid retrieval recall
Compare semantic and hybrid search MCP connectors on metadata filter translation, reranking support, and chunk token budgeting.
-
Assess Kubernetes and Docker MCP servers on cluster diagnostics and blast-radius safety
Compare container and K8s MCP connectors on CrashLoopBackOff diagnosis, pod log streaming caps, and RBAC write protection.