mcp-language-server
by isaacphi
Overview
Serves as an MCP (Model Context Protocol) gateway, enabling LLMs to interact with Language Servers (LSPs) for codebase navigation, semantic analysis, and code editing operations.
Installation
mcp-language-server --workspace /path/to/yourproject/ --lsp goplsEnvironment Variables
- LOG_LEVEL
- LOG_COMPONENT_LEVELS
- LOG_FILE
- LSP_CONTEXT_LINES
Security Notes
CRITICAL: The server exposes tools like 'edit_file' and 'rename_symbol' that directly accept 'filePath' arguments from MCP clients (potentially LLMs). The source code does NOT appear to sanitize or confine these 'filePath' arguments to the configured '--workspace' directory. This creates a critical vulnerability where a malicious or unconstrained LLM could perform arbitrary file writes, deletions, or renames on the host system outside the intended workspace. Similarly, 'definition', 'references', 'diagnostics', and 'hover' tools, which also accept 'filePath', could lead to arbitrary file reads and information disclosure. The 'lspCommand' to run the underlying Language Server is specified at startup, making it a configuration risk rather than a direct runtime injection vulnerability.
Similar Servers
mcpo
Exposes Model Context Protocol (MCP) tools as OpenAPI-compatible HTTP servers.
cclsp
Integrate LLM-based coding agents with Language Server Protocol (LSP) servers to enable robust code navigation, symbol resolution, and refactoring across various programming languages.
mcp-shark
Aggregate multiple Model Context Protocol (MCP) servers into a single unified interface with a powerful monitoring UI.
modular-mcp
A proxy server that efficiently manages and loads large tool collections from multiple Model Context Protocol (MCP) servers on-demand for LLMs, reducing context overhead.