Burp验证码识别插件

发布时间 2023-11-06 14:06:15作者: Mr-Ryan

Captcha-killer验证码识别插件分享

0x01 下载安装插件

项目地址

https://github.com/f0ng/captcha-killer-modified

插件下载地址

https://github.com/f0ng/captcha-killer-modified/releases

下载并安装插件

  1. 下载插件 captcha-killer-modified-0.24.2-jdk8.jar
  2. 安装插件,Extensions-->Add-->Select file


    Errors为空,表示插件导入成功

0x04 验证码识别服务安装

项目地址

https://github.com/sml2h3/ddddocr
https://github.com/sml2h3/ocr_api_server

运行环境

python <= 3.9
Windows/Linux/Macos..

安装ddddocr

python3 -m pip install ddddocr -i https://mirrors.ustc.edu.cn/pypi/web/simple

安装ocr_api_server

git clone https://github.com/sml2h3/ocr_api_server.git

cd ocr_api_server

python3 -m pip install -r requirements.txt -i https://mirrors.ustc.edu.cn/pypi/web/simple

python3 -m pip install Pillow==9.5.0 -i https://mirrors.ustc.edu.cn/pypi/web/simple

启动ocr_api_server

python3 ocr_server.py --port 9898 --ocr

插件配置及使用

  1. 首先获取验证码请求,发送到 captcha panel

  2. 获取验证码图片,点击获取即可获取到验证码

  3. 配置验证码识别接口

    接口url为前面启动服务返回的url



    然后配置 Request template (Host自行修改为启动服务的ip端口):

    POST /ocr/b64 HTTP/1.1
    Host: 198.18.0.1:9898
    User-Agent: python-requests/2.24.0
    Accept-Encoding: gzip, deflate
    Accept: */*
    Connection: close
    Content-Length: 2540
    
    <@BASE64><@IMG_RAW></@IMG_RAW></@BASE64>
    

    配置好之后点击识别即可识别出验证码

    注意: 如果以上使用 IP 没有用的话,就改用 127.0.0.1

验证码爆破实例

  1. 发送登录请求到 Intruder 模块,在 Positions 选项卡下,选择攻击模式为 Pitchfork,给要爆破的密码字段、验证码字段添加标记

  2. Payloads 选项卡下设置攻击 Payload
    payload set 里的 1 设置为密码字典

    payload set 里的 2 设置为 Extension-generated ,也就是插件生成

  3. 开始爆破,可以看到返回密码错误而不是验证码错误