mcp-proxy
Bypasses Claude Desktop sandbox network restrictions by providing tools to fetch any URL, execute network-capable CLI commands (yt-dlp, curl, ffmpeg), and read files created by those tools.
README
mcp-proxy
MCP server that bypasses Claude Desktop sandbox network restrictions.
Claude Desktop runs in a restricted sandbox that blocks many network operations and CLI tools that need internet access. This MCP server provides three tools that run outside the sandbox, enabling Claude to:
- Fetch any URL (API calls, web scraping, downloads)
- Execute network-capable CLI tools (yt-dlp, curl, ffmpeg, etc.)
- Read files created by those tools (subtitle files, downloads, etc.)
Installation
Quick Install (via GitHub)
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"proxy": {
"command": "npx",
"args": ["-y", "github:CodefiLabs/claude-desktop-skills-proxy"]
}
}
}
Restart Claude Desktop for changes to take effect. The server will be automatically downloaded and run.
Local Development
git clone https://github.com/CodefiLabs/claude-desktop-skills-proxy.git
cd claude-desktop-skills-proxy
npm install
npm run build
Then configure Claude Desktop to use the local build:
{
"mcpServers": {
"proxy": {
"command": "node",
"args": ["/path/to/claude-desktop-skills-proxy/dist/index.js"]
}
}
}
Tools
proxy_fetch
Make HTTP requests to any URL. Supports all common HTTP methods.
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
url |
string | Yes | The URL to fetch |
method |
string | No | HTTP method: GET, POST, PUT, DELETE, PATCH, HEAD (default: GET) |
headers |
object | No | Custom HTTP headers as key-value pairs |
body |
string | No | Request body for POST/PUT/PATCH |
timeout |
number | No | Timeout in milliseconds (default: 30000) |
approve |
string | No | Domain approval: "once" or "always" |
Example - Simple GET:
{
"url": "https://api.github.com/users/octocat"
}
Example - POST with headers:
{
"url": "https://api.example.com/data",
"method": "POST",
"headers": {
"Content-Type": "application/json",
"Authorization": "Bearer token123"
},
"body": "{\"key\": \"value\"}"
}
Example - Approve new domain:
{
"url": "https://newsite.com/api",
"approve": "always"
}
network_exec
Execute CLI commands that require network access. Uses secure spawn() instead of shell execution.
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
command |
string | Yes | The command to execute (e.g., "yt-dlp", "curl") |
args |
array | No | Command arguments as array |
cwd |
string | No | Working directory |
env |
object | No | Additional environment variables |
timeout |
number | No | Timeout in milliseconds (default: 60000) |
approve |
string | No | Command approval: "once" or "always" |
Example - Download video with yt-dlp:
{
"command": "yt-dlp",
"args": ["--output", "video.mp4", "https://youtube.com/watch?v=dQw4w9WgXcQ"],
"cwd": "/Users/kk/Downloads",
"approve": "always"
}
Example - Fetch with curl:
{
"command": "curl",
"args": ["-s", "https://api.ipify.org?format=json"],
"approve": "once"
}
Example - Convert video with ffmpeg:
{
"command": "ffmpeg",
"args": ["-i", "input.mp4", "-c:v", "libx264", "output.mp4"],
"cwd": "/Users/kk/Videos",
"timeout": 300000
}
read_file
Read files from the host filesystem. Useful for reading files created by network_exec (e.g., subtitle files from yt-dlp).
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
path |
string | Yes | Absolute path to the file to read |
encoding |
string | No | "utf8" (default) or "base64" for binary files |
maxSize |
number | No | Maximum file size in bytes (default: 5MB) |
Example - Read subtitle file:
{
"path": "/tmp/video.en.vtt"
}
Example - Read binary file as base64:
{
"path": "/tmp/image.png",
"encoding": "base64"
}
Workflow for yt-dlp subtitles:
- Download subtitles with
network_exec:{ "command": "yt-dlp", "args": ["--write-auto-sub", "--skip-download", "-o", "/tmp/%(id)s", "VIDEO_ID"], "approve": "always" } - Read the subtitle file with
read_file:{ "path": "/tmp/VIDEO_ID.en.vtt" }
Blocked paths: Sensitive files like ~/.ssh/*, ~/.aws/*, /etc/shadow, .env files, and credential files are blocked for security.
Approval Flow
When accessing a new domain or running a new command, the tool returns a needs_approval status:
{
"status": "needs_approval",
"domain": "example.com",
"message": "Domain \"example.com\" is not in your allowlist. To proceed, call proxy_fetch again with approve: \"once\" for this request only, or approve: \"always\" to remember this domain."
}
Approval options:
"once"- Allow for this single request only"always"- Add to allowlist and remember for future requests
Once approved with "always", subsequent requests to that domain/command work automatically.
Security
Blocked Domains (SSRF Protection)
The following domains are always blocked to prevent Server-Side Request Forgery attacks:
localhost,127.0.0.1,::1- Loopback addresses169.254.169.254- AWS metadata endpoint10.*,172.16-31.*,192.168.*- Private IP rangesfe80:*,fc00:*,fd00:*- IPv6 private/link-local
Blocked Commands
These commands are blocked for security:
- Destructive:
rm,rmdir,del,mv - Privilege escalation:
sudo,su,doas - Permissions:
chmod,chown,chgrp - System:
mkfs,fdisk,dd,format - Package managers:
apt,brew,yum, etc. - Shells:
bash,sh,zsh, etc. - Network abuse:
nc,netcat,telnet
Argument Validation
Shell operators are blocked in command arguments to prevent injection:
;,|,&&,||- Command chaining>,<- Redirects$(,`,${- Command/variable substitution
Rate Limiting
Requests are rate-limited to prevent abuse:
- 60 requests per minute per domain/command
- Automatic cooldown with retry-after information
Configuration
Configuration is stored at ~/.config/mcp-proxy/config.json:
{
"allowedDomains": ["api.github.com", "example.com"],
"blockedDomains": ["localhost", "127.0.0.1", "..."],
"allowedCommands": ["yt-dlp", "curl", "ffmpeg"],
"blockedCommands": ["rm", "sudo", "..."]
}
The file is created automatically on first use. User-approved domains/commands are added to the allowlists. Security blocklists cannot be overridden.
Development
# Build
npm run build
# Watch mode
npm run watch
# Test with MCP Inspector
npx @modelcontextprotocol/inspector node dist/index.js
License
MIT
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。