shravanboorla/recon-methodology
GitHub: shravanboorla/recon-methodology
一套循序渐进的外部攻击面侦察工作流文档,指导从单一域名到截图验证的存活子域名的完整资产测绘流程。
Stars: 0 | Forks: 0
# 🔍 侦察方法论 — 从域名到存活目标
一个循序渐进的侦察工作流,用于映射组织的
外部攻击面,从单个目标域名到一份
已截图验证的存活子域名列表。

## 工作流
| 步骤 | 任务 | 工具/资源 |
|------|------|------------------|
| 1 | 目标选择 | 定义范围 |
| 2 | 相关域名 | [MXToolbox](https://mxtoolbox.com/SuperTool.aspx), [ViewDNS](https://viewdns.info/) |
| 3 | 子域名枚举 | `subfinder`, [Chaos](https://chaos.projectdiscovery.io/) |
| 4 | ASN 查询 | [Hurricane Electric BGP Toolkit](https://bgp.he.net/) |
| 5 | CIDR → IP 范围 | [IPAddressGuide](https://www.ipaddressguide.com/cidr) |
| 6 | 端口/漏洞扫描 | [Shodan](https://www.shodan.io/) |
| 7 | 子域名排序与去重 | — |
| 8 | 过滤存活主机 | `httpx` |
| 9 | GitHub 侦察 | GitHub dorking, `trufflehog`, `gitleaks` |
| 10 | 深度枚举 | `subzy`/`subjack` (takeover), `dirsearch` (brute-force), `katana` (crawl), `secretfinder` (JS secrets) |
| 11 | 可视化侦察 | `eyewitness` |
## 详细步骤
### 1. 目标选择
选择测试范围内的域名/组织。
### 2. 相关域名发现
对 WHOIS 记录进行逆向工程,以查找由
同一组织注册的其他域名。
### 3. 子域名枚举
```
subfinder -d target.com -o subdomains.txt
```
### 4. ASN 识别
通过 BGP.he.net 查询组织的 ASN,以识别其
拥有的 IP 空间。
### 5. CIDR 转换为 IP
将发现的 CIDR 块转换为单个 IP 以便扫描。
### 6. 扫描
使用 Shodan 识别整个 IP 范围内的开放端口、banner 和已知
漏洞。
### 7–8. 排序与存活主机过滤
```
cat subdomains.txt | httpx -o live_subdomains.txt
```
### 9. GitHub 侦察
在 GitHub 中搜索组织的仓库、dorks,以及任何因
失误而提交的泄露 API key、token 或凭证。
```
# 在 org repos 中搜索泄露的 secrets
trufflehog github --org=target-org
# 扫描克隆的 repo 以查找硬编码的 secrets
gitleaks detect --source=./cloned-repo
```
### 10. 深度枚举
```
# Subdomain takeover 检查
subzy run --targets live_subdomains.txt
# Directory brute-force
dirsearch -u https://target.com
# JS 爬取 + secret 提取
katana -u https://target.com -o js_files.txt
python3 secretfinder.py -i js_files.txt -o cli
```
### 11. 可视化侦察
```
eyewitness -f live_subdomains.txt --web
```
## 使用的工具
- [subfinder](https://github.com/projectdiscovery/subfinder)
- [httpx](https://github.com/projectdiscovery/httpx)
- [katana](https://github.com/projectdiscovery/katana)
- [EyeWitness](https://github.com/FortyNorthSecurity/EyeWitness)
- [dirsearch](https://github.com/maurosoria/dirsearch)
- [subzy](https://github.com/LukaSikic/subzy) / [subjack](https://github.com/haccer/subjack)
- [SecretFinder](https://github.com/m4ll0k/SecretFinder)
- [TruffleHog](https://github.com/trufflesecurity/trufflehog)
- [Gitleaks](https://github.com/gitleaks/gitleaks)
## 许可证
本项目仅供教育目的使用。
标签:GitHub, 子域名枚举, 实时处理, 密码管理, 攻击面挖掘, 系统安全, 网络安全, 资产测绘, 运行时操纵, 隐私保护