hm_editor
by huimeicloud
Overview
This MCP server integrates an advanced medical record editor with AI capabilities, enabling structured document content management, data element manipulation, revision tracking, watermarking, and dynamic generation of charts and tabular data. It also provides search functionalities for medical staff, ICD codes, and geographical data, and supports PDF generation.
Installation
node index.jsEnvironment Variables
- DEEPSEEK_API_KEY
- MODEL_NAME
- BASE_URL
- NODE_ENV
- PORT
Security Notes
1. **Critical: Remote Code Execution (RCE) / Cross-Client Command Injection via MCP WebSocket**: The `mcp-server.js` `tools/call` endpoint allows an authenticated user to specify a `sessionId` in the arguments, which is then used to send arbitrary tool calls (method and arguments) to *any* connected WebSocket client associated with that `sessionId`. There is no validation to ensure the provided `sessionId` belongs to the calling client, posing a severe risk of remote arbitrary code execution on other users' active editor instances. For example, `insertDataAtCursor` or `setDocContent` could be exploited to inject malicious HTML/JavaScript. 2. **Potential RCE via PDF Generation**: The `/getPdfPath` endpoint in `src/print.js` takes `req.body.html` directly as input for `wkhtmltopdf`. If the HTML content is untrusted and contains known vulnerabilities for web rendering engines, this could lead to Remote Code Execution on the server where `wkhtmltopdf` is executed. 3. **Hardcoded Credentials**: `DEEPSEEK_API_KEY` is expected as an environment variable, but its management outside of `.env` files (e.g., if committed to a repository) could expose sensitive credentials. 4. **File System Operations**: Direct file system operations (read/write/delete) are performed for mock data and PDF generation. While `path.join` is used to mitigate some directory traversal risks, the overall attack surface through these operations requires careful input sanitization to prevent unintended file manipulation.
Similar Servers
mineru-tianshu
Enterprise-grade AI data preprocessing platform for converting diverse unstructured multi-modal data (documents, images, audio, video, bioinformatics formats) into structured Markdown and JSON formats, leveraging GPU acceleration and a robust task management system with user authentication and MCP protocol integration.
pluggedin-app
A testing environment for MCP (Model Control Protocol) servers, allowing interaction through a chat interface powered by LLMs and an AI agent using the LangChain ReAct framework.
fhir-mcp-server
The FHIR MCP Server acts as a bridge between AI/LLM tools and FHIR APIs, enabling seamless search, retrieval, and analysis of clinical information.
hm_editor
This MCP server integrates an advanced medical record editor with AI capabilities, enabling structured document content management, data element manipulation, revision tracking, watermarking, and dynamic generation of charts and tabular data. It also provides search functionalities for medical staff, ICD codes, and geographical data, and supports PDF generation.