You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Filesystem MPC Server rejects lowercase drive letters in paths #1987
Describe the bug
The filesystem MPC Server incorrectly treats paths with lowercase drive letters as outside the allowed directory scope, even though the path is valid on Windows. This results in an "access denied" error, despite the target path being inside the allowed directory.
To Reproduce
Steps to reproduce the behavior:
Use the create_directory , directory_tree operation with a path like:
{
"path": "g:\\GitHub\\obsidian\\Temp"
}
Observe the error:
Error: Access denied - path outside allowed directories:
g:\GitHub\obsidian\Temp not in G:\GitHub\obsidian
Retry the same operation with the drive letter capitalized:
{
"path": "G:\\GitHub\\obsidian\\Temp"
}
This time, the directory is created successfully.
Expected behavior
Since Windows paths are case-insensitive, both "g:" and "G:" should be treated the same. The server should allow the operation if the actual path is within the allowed root, regardless of drive letter case.
Additional context
This behavior appears to be caused by a case-sensitive string comparison in the server’s path validation logic. Normalizing the paths or performing case-insensitive comparison (at least for the drive letter) should resolve this inconsistency on Windows systems.
I created a temporary fork so I could get the Filesystem server working for myself in Windsurf. This commit seemed to get things working properly for me.
I believe this fix would also resolve reported issues: #470, #1820, #1033, #1838
I will submit a Pull Request shortly on this repo.
Activity
DanOverflow commentedon Jun 14, 2025
I created a temporary fork so I could get the Filesystem server working for myself in Windsurf. This commit seemed to get things working properly for me.
I believe this fix would also resolve reported issues: #470, #1820, #1033, #1838
I will submit a Pull Request shortly on this repo.
domdomegg commentedon Aug 9, 2025
Thanks for reporting this! Going to merge this into #470 for clearer tracking.