mcp
Verified Safeby pulseengine
Overview
A robust Rust framework for building Model Context Protocol (MCP) servers, enabling AI assistants to securely interact with external systems through defined tools, resources, and prompts.
Installation
cargo run --example hello-worldEnvironment Variables
- RUST_LOG
- MCP_AUTH_API_KEY_ADMIN_1
- MCP_API_KEY
- MCP_SECURITY_PROFILE
- MCP_JWT_SECRET
- MCP_MASTER_KEY_B64
- OTEL_EXPORTER_OTLP_ENDPOINT
- OTEL_SERVICE_NAME
Security Notes
The framework is designed with strong security principles, offering comprehensive features: - **Authentication:** Supports API keys (hashed/salted), JWTs, session management, and OAuth. Different storage options (memory, file, environment) for keys with explicit file permissions. - **Authorization:** Role-based access control. - **Input Validation:** Built-in mechanisms for detecting and sanitizing SQL injection, XSS, command injection, and path traversal attempts, configurable request limits. - **Transport Security:** Configurable CORS, HTTPS enforcement (via middleware/transport options, though TLS certificate management requires external setup). - **Observability:** Audit logging, metrics, and tracing aid in detecting and responding to security incidents. - **Code Quality:** Written in Rust, which inherently prevents many common memory-safety vulnerabilities. Uses established cryptographic primitives (AES-GCM, SHA256, PBKDF2). The main security consideration is ensuring proper configuration and secure implementation of custom backends, as the framework provides the tools, but their effective use depends on the developer. No direct 'eval' or malicious patterns found in the server's Rust codebase.
Similar Servers
tmcp
Build Model Context Protocol (MCP) servers for AI agents, providing schema-agnostic tools, resources, and prompts, with optional OAuth 2.1 authentication and distributed session management.
rust-mcp-sdk
A high-performance, asynchronous Rust SDK for building Model Context Protocol (MCP) servers and clients, simplifying protocol handling, enabling tool-based interactions, and supporting multiple transports and authentication methods.
rust-mcp-schema
Provides a type-safe Rust implementation of the Model Context Protocol (MCP) schema for building LLM applications and integrating with external data sources and tools. It facilitates serialization and deserialization of MCP messages.
boilerplate-mcp-server
This boilerplate provides a production-ready foundation for developing custom Model Context Protocol (MCP) servers in TypeScript to connect AI assistants with external APIs and data sources, exemplified by an IP geolocation lookup tool.