godmakereth/vibe-coding-tw/proxychains

Claude Code and agent skill by godmakereth/vibe-coding-tw

Trust tier 3
  • community
  • ext:[{"type":"config","description":"Configuration overrides"}]
Source check pending

Checking that the SKILL.md file is still in the repository.

Auto-detect network issues and force proxy usage with proxychains4. Use this skill when encountering connection timeouts, DNS failures, or blocked network access. Default proxy is http://127.0.0.1:9910

Install

npx vskill@latest install godmakereth/vibe-coding-tw/proxychains

Semi-extensibleMentions customization, but needs skill-specific knowledge. Read the extensible skills standard

SKILL.md

Proxychains Network Proxy Skill

自動使用代理解決網路問題 - 當遇到網路連線失敗、超時或訪問受限時,自動使用 proxychains4 強制走代理。

When to Use This Skill

觸發條件(自動應用):

  • ❌ Connection timeout errors
  • ❌ DNS resolution failures
  • ❌ "Connection refused" errors
  • ❌ HTTP 403/451 blocked access
  • ❌ GitHub/PyPI/npm 等國外資源訪問失敗
  • ❌ curl/wget/git/pip 等命令失敗

Claude 應該:

  1. 檢測到網路錯誤後,自動在命令前新增 proxychains4
  2. 使用預設代理配置:http://127.0.0.1:9910
  3. 如果代理失敗,提示使用者檢查代理服務狀態

Quick Reference

基本用法模式
bash
# ❌ 原命令失敗
curl https://github.com/user/repo
# ✅ 使用代理重試
proxychains4 curl https://github.com/user/repo
常見場景自動應用

場景 1: Git 操作失敗

bash
# 原命令
git clone https://github.com/user/repo.git
# 自動改為
proxychains4 git clone https://github.com/user/repo.git

場景 2: Python pip 安裝失敗

bash
# 原命令
pip install requests
# 自動改為
proxychains4 pip install requests

場景 3: npm/yarn 安裝失敗

bash
# 原命令
npm install package-name
# 自動改為
proxychains4 npm install package-name

場景 4: wget/curl 下載失敗

bash
# 原命令
wget https://example.com/file.tar.gz
# 自動改為
proxychains4 wget https://example.com/file.tar.gz

場景 5: Docker 拉取映象失敗

bash
# 原命令
docker pull image:tag
# 自動改為
proxychains4 docker pull image:tag

場景 6: SSH 連線失敗

bash
# 原命令
ssh user@remote-host
# 自動改為
proxychains4 ssh user@remote-host

配置詳情

預設代理配置

本地代理地址: http://127.0.0.1:9910

配置檔案位置:

  • ~/.proxychains/proxychains.conf (推薦)
  • /etc/proxychains.conf (系統級)
快速配置指令碼

建立使用者級配置(自動使用 127.0.0.1:9910):

bash
mkdir -p ~/.proxychains
cat > ~/.proxychains/proxychains.conf << 'EOF'
# Proxychains configuration
strict_chain
proxy_dns
remote_dns_subnet 224
tcp_read_time_out 15000
tcp_connect_time_out 8000
[ProxyList]
http 127.0.0.1 9910
EOF
環境變數方式(臨時使用)
bash
# 設定代理環境變數
export PROXYCHAINS_SOCKS5_HOST=127.0.0.1
export PROXYCHAINS_SOCKS5_PORT=9910
# 使用
proxychains4 curl https://github.com

工作原理

Proxychains 透過 LD_PRELOAD 機制攔截程式的網路呼叫:

  1. 攔截系統呼叫:Hook socket 相關的 libc 函式
  2. 重定向連線:將所有 TCP 連線重定向到代理伺服器
  3. DNS 代理:透過代理伺服器解析域名
  4. 透明代理:應用程式無需修改

重要限制:

  • 只支援動態連結的程式(statically linked 程式不支援)
  • 只支援 TCP 連線(UDP 不支援)
  • 部分使用特殊網路庫的程式可能不相容

Claude 自動化規則

規則 1: 網路錯誤自動重試
IF 命令返回網路相關錯誤(timeout, connection refused, DNS failure)
THEN 自動使用 proxychains4 重試該命令
規則 2: 已知慢速源強制代理
IF 訪問以下域名/服務:
- github.com
- raw.githubusercontent.com
- pypi.org
- npmjs.org
- registry.npmjs.org
- docker.io
- gcr.io
THEN 直接使用 proxychains4(不等待失敗)
規則 3: 失敗提示
IF proxychains4 命令也失敗
THEN 提示使用者:
1. 檢查代理服務是否執行(127.0.0.1:9910)
2. 檢查 proxychains 配置檔案
3. 嘗試其他代理地址

故障排除

檢查代理服務狀態
bash
# 測試代理是否可用
curl -x http://127.0.0.1:9910 https://www.google.com
# 檢查埠是否監聽
netstat -tunlp | grep 9910
# 或
ss -tunlp | grep 9910
驗證 proxychains 配置
bash
# 測試配置是否正確
proxychains4 curl https://ipinfo.io/json
# 應該顯示代理伺服器的 IP,而不是本機 IP
常見錯誤處理

錯誤 1: "proxychains: command not found"

bash
# 安裝 proxychains4
sudo apt install proxychains4 # Debian/Ubuntu
sudo yum install proxychains-ng # CentOS/RHEL

錯誤 2: "timeout"

bash
# 檢查代理地址配置是否正確
cat ~/.proxychains/proxychains.conf | grep -A 2 "\[ProxyList\]"
# 修改超時時間(在配置檔案中)
tcp_connect_time_out 15000
tcp_read_time_out 30000

錯誤 3: "can't read configuration file"

bash
# 建立配置檔案
mkdir -p ~/.proxychains
cp /etc/proxychains.conf ~/.proxychains/proxychains.conf
# 然後編輯配置

高階用法

多代理鏈
conf
# ~/.proxychains/proxychains.conf
strict_chain # 按順序使用所有代理
[ProxyList]
http 127.0.0.1 9910
socks5 127.0.0.1 1080
動態代理鏈
conf
dynamic_chain # 自動跳過死代理
[ProxyList]
http 127.0.0.1 9910
http 127.0.0.1 8080
socks5 127.0.0.1 1080
隨機代理鏈
conf
random_chain
chain_len = 2 # 隨機選擇 2 個代理
[ProxyList]
http 127.0.0.1 9910
socks5 127.0.0.1 1080
socks5 127.0.0.1 1081
自定義 DNS 伺服器
bash
# 使用自定義 DNS 透過代理解析
export PROXY_DNS_SERVER=8.8.8.8
proxychains4 curl https://example.com

參考資源

  • 官方倉庫: https://github.com/haad/proxychains
  • 配置檔案: references/proxychains.conf (完整示例)
  • 故障排除: references/troubleshooting.md
  • 命令速查: references/quick-reference.md

總結

記住這些原則:

  1. ❌ 遇到網路錯誤 → ✅ 自動加上 proxychains4
  2. 🌐 訪問國外資源 → ✅ 主動使用 proxychains4
  3. 🔧 代理也失敗 → ✅ 提示使用者檢查代理服務

預設代理: http://127.0.0.1:9910


這個技能讓 Claude 在遇到網路問題時自動使用代理,無需使用者手動干預!

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
0

Not refreshed yet.

Extension points

  • configConfiguration overrides

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/godmakereth/vibe-coding-tw/proxychains/badge)](https://verified-skill.com/skills/godmakereth/vibe-coding-tw/proxychains)

Something wrong with this skill or its page? Tell us.