BlockSecCA/unc-filesystem-mcp
If you are the rightful owner of unc-filesystem-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.
The UNC Filesystem MCP is a server designed to handle filesystem operations with proper support for UNC paths on Windows, addressing specific bugs in the built-in Claude Desktop filesystem server.
UNC Filesystem MCP
MCP server for filesystem operations with proper UNC path support on Windows.
Why?
The built-in Claude Desktop filesystem server has bugs with network paths:
- Drive letter resolution is asymmetric: Mapped drives (e.g.,
Z:) get resolved to their UNC equivalent at config load time, but incoming requests are compared literally. Result: access denied. - UNC subdirectory matching fails: Even when
\\server\shareis in the allowed list, accessing\\server\share\subfolderis rejected.
This server normalizes both sides of the path comparison, so mapped drives and UNC subdirectories work correctly.
Installation
Option 1: MCPB Package (Recommended)
- Download
unc-filesystem-mcp.mcpbfrom releases - Double-click to install in Claude Desktop
- Use the folder picker to add allowed directories
- Restart Claude Desktop
Option 2: Manual Setup
git clone https://github.com/BlockSecCA/unc-filesystem-mcp.git
cd unc-filesystem-mcp
npm install
npm run build
Add to claude_desktop_config.json:
{
"mcpServers": {
"unc-fs": {
"command": "node",
"args": [
"C:/path/to/unc-filesystem-mcp/dist/index.js",
"\\\\server\\share",
"Z:\\",
"C:\\Users\\Me\\Documents"
]
}
}
}
Tools
| Tool | Description |
|---|---|
read_file | Read file contents with optional head/tail line limits |
write_file | Create or overwrite files |
edit_file | Replace unique text in file, returns unified diff |
list_directory | List directory contents with [FILE]/[DIR] prefixes |
search_files | Recursive glob-based file search |
get_file_info | File/directory metadata (size, dates, permissions) |
list_allowed_directories | Show configured allowed paths |
Building from Source
npm install
npm run build # Compile TypeScript
npm run pack # Create .mcpb package (requires @anthropic-ai/mcpb)
How It Works
The fix is in path normalization. Both the configured allowed directories and incoming request paths are normalized to the same format before comparison:
- Backslashes → forward slashes
- Lowercase for case-insensitive matching
- UNC paths preserved as-is
- Local paths resolved to absolute
This ensures Z:\subfolder matches against //server/share/ when Z: is mapped to \\server\share.
License
MIT - Carlos - BlockSecCA