验证码识别与解决 / CAPTCHA Solver
name: captcha-solver
by bombfuock · published 2026-03-22
$ claw add gh:bombfuock/bombfuock-captcha-solver---
name: captcha-solver
description: 验证码识别与解决 - 本地OCR识别 + 第三方API / CAPTCHA Recognition and Solving - Local OCR + Third-party APIs
metadata:
version: 1.0.0
---
# 验证码识别与解决 / CAPTCHA Solver
自动识别和解决各类验证码 / Automatically recognize and solve various CAPTCHAs
支持类型 / Supported Types
本地OCR识别 / Local OCR (免费/Free)
API解决 / API Solving (付费/APIs)
使用方法 / Usage
# 识别图片验证码
python solve.py --image captcha.png
# 解决reCaptcha
python solve.py --recaptcha "site_key" --url "page_url"
# 滑动验证码
python solve.py --slide background.png --template slider.png配置 / Configuration
本地OCR
# 默认使用Tesseract
TESSERACT_CMD = "/usr/bin/tesseract"
LANG = "eng+chi_sim" # 支持中英文API服务 (可选)
# 2Captcha
API_2CAPTCHA = "your_api_key"
# Anti-Captcha
API_ANTI_CAPTCHA = "your_api_key"算法 / Algorithms
1. 图像预处理
2. 字符分割
3. 字符识别
4. 滑动验证码
示例 / Examples
简单文本识别
from solver import CaptchaSolver
solver = CaptchaSolver()
result = solver.solve_image("captcha.png")
print(result) # 输出识别的字符滑动验证码
result = solver.solve_slide(bg_img, slider_img)
print(result) # 输出滑动距离reCaptcha
result = solver.solve_recaptcha(site_key, page_url)
print(result) # 输出token服务对比 / Service Comparison
| 服务 | 价格 | 成功率 | 速度 |
|------|------|--------|------|
| 本地OCR | 免费 | 60-80% | 快 |
| 2Captcha | $2.99/1000 | 95%+ | 慢 |
| Anti-Captcha | $2.00/1000 | 95%+ | 中 |
注意事项 / Notes
1. 优先使用本地OCR,失败再调用API
2. 遵守网站使用条款
3. 不要用于非法用途
More tools from the same signal band
Order food/drinks (点餐) on an Android device paired as an OpenClaw node. Uses in-app menu and cart; add goods, view cart, submit order (demo, no real payment).
Sign plugins, rotate agent credentials without losing identity, and publicly attest to plugin behavior with verifiable claims and authenticated transfers.
The philosophical layer for AI agents. Maps behavior to Spinoza's 48 affects, calculates persistence scores, and generates geometric self-reports. Give your...