MCP Gateway
Overview
Akto MCP Gateway is a security and governance layer that sits between MCP (Model Context Protocol) clients and MCP servers. It enables organizations to implement guardrail protection, security policies, and guardrails for all MCP server requests while maintaining seamless connectivity to the original MCP servers.
Key Features
Guardrail Protection: Real-time scanning and blocking of malicious requests
Security Guardrails: Enforce organizational security policies and compliance requirements
Request Monitoring: Complete visibility into all MCP communications
Transparent Proxying: Zero-configuration changes required on MCP servers
Performance Optimization: Intelligent caching and request optimization
Architecture
Cloud setup
How It Works
Request Interception: MCP clients send requests to the Akto gateway endpoint instead of directly to MCP servers
Security Analysis: Each request undergoes guardrail detection and policy validation
Policy Enforcement: Requests are evaluated against configured guardrails
Request Forwarding: Validated requests are forwarded to the original MCP server
Response Processing: Server responses are analyzed and returned to the client
Configuration
Basic Setup
To use Akto MCP Gateway, simply prepend your original MCP server URL with the Akto gateway endpoint. All existing authentication and credentials for your original MCP server remain unchanged.
Gateway URL Format:
Where the original MCP server URL is transformed by:
Replacing
://with/Example:
https://mcp.example.com/api→https/mcp.example.com/api
Configuration Examples
SSE-based MCP Server
Original configuration:
With Akto gateway:
WebSocket MCP Server
Original configuration:
With Akto gateway:
Important Notes
All original authentication credentials (API keys, tokens, etc.) remain the same
The gateway transparently forwards authentication headers to the original server
No changes required on the MCP server side
The gateway URL supports both HTTP/HTTPS and WebSocket protocols
Advanced Configuration
Custom Guardrails
Define custom security policies and guardrails:
Guardrails Profiles
Configure guardrail detection sensitivity and rules:
Security Features
1. Guardrails
SQL Injection Prevention: Detects and blocks SQL injection attempts
Command Injection Protection: Prevents malicious command execution
Path Traversal Defense: Blocks unauthorized file system access
Data Exfiltration Prevention: Monitors and controls data egress
2. Access Control
Authentication: API key-based authentication for all gateway requests
Authorization: Role-based access control for different MCP operations
IP Whitelisting: Restrict access to approved IP addresses
Session Management: Secure session handling with automatic timeout
3. Data Protection
Encryption in Transit: TLS 1.3 for all communications
PII Detection: Automatic identification and protection of sensitive data
Data Masking: Real-time redaction of sensitive information
Audit Logging: Comprehensive logging of all requests and responses
Monitoring & Analytics
Dashboard Metrics
Request volume and trends
Guardrail detection statistics
Blocked request analysis
Performance metrics (latency, throughput)
Error rates and patterns
Alerts & Notifications
Configure alerts for security events:
API Reference
Gateway Endpoints
Health Check
Response Format
Best Practices
Regular Policy Updates: Keep security policies and guardrails up-to-date
Monitor Alert Fatigue: Fine-tune detection rules to reduce false positives
Performance Optimization: Use caching for frequently accessed resources
Backup Configuration: Maintain fallback options for critical MCP servers
Regular Audits: Review logs and analytics for security insights
Troubleshooting Common Issues
Connection Timeout
Verify network connectivity to Akto gateway
Check firewall rules and gateway settings
Validate API key and authentication
Request Blocked
Review security detection logs for specific violations
Check guardrail configurations
Verify request content against security policies
Performance Degradation
Monitor gateway latency metrics
Optimize guardrail rules for efficiency
Consider geographic gateway distribution
Get Support for your Akto setup
There are multiple ways to request support from Akto. We are 24X7 available on the following:
In-app
intercomsupport. Message us with your query on intercom in Akto dashboard and someone will reply.Join our discord channel for community support.
Contact
help@akto.iofor email support.Contact us here.
Last updated