executing-plans
executing-plans
Use when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available
intercepting-mobile-traffic-with-burpsuite使用 Burp Suite 代理拦截和分析移动应用的 HTTP/HTTPS 流量,以识别不安全的 API 通信、 认证缺陷、数据泄露和服务器端漏洞。适用于移动应用渗透测试、API 安全评估或 评估客户端-服务器通信模式。适合移动流量拦截、Burp Suite 移动代理、API 安全测试 或移动 HTTPS 分析相关请求。
Independent GitHub snapshot · Automated classification · Original documentation governs
适用于以下情况:
不适用场景:不得拦截未获授权应用的流量——未经授权的流量拦截违反计算机欺诈法律。
Burp Suite > Proxy > Options > Proxy Listeners:
- 绑定地址:所有接口(或特定 IP)
- 绑定端口:8080
- 启用"Support invisible proxying"
验证监听器是否激活,并记录工作站在共享网络上的 IP 地址。
Android:
设置 > Wi-Fi > [网络] > 高级 > 手动代理
- 主机名:<burp_workstation_ip>
- 端口:8080
iOS:
设置 > Wi-Fi > [网络] > 配置代理 > 手动
- 服务器:<burp_workstation_ip>
- 端口:8080
Android(API 24 以下):
# 从 Proxy > Options > Import/Export CA Certificate 导出 Burp CA
# 传输到设备并通过 设置 > 安全 > 从存储安装 进行安装
Android(API 24+ / Android 7+): 针对 API 24+ 的应用默认不信任用户安装的 CA。解决方案:
# 方案 A:修改应用的 network_security_config.xml(需要重新打包 APK)
# 添加到 res/xml/network_security_config.xml:
# <network-security-config>
# <debug-overrides>
# <trust-anchors>
# <certificates src="user" />
# </trust-anchors>
# </debug-overrides>
# </network-security-config>
# 方案 B:作为系统 CA 安装(需 root 设备)
openssl x509 -inform DER -in burp-ca.der -out burp-ca.pem
HASH=$(openssl x509 -inform PEM -subject_hash_old -in burp-ca.pem | head -1)
cp burp-ca.pem "$HASH.0"
adb push "$HASH.0" /system/etc/security/cacerts/
adb shell chmod 644 /system/etc/security/cacerts/$HASH.0
# 方案 C:Magisk 模块(MagiskTrustUserCerts)
iOS:
1. 在 Safari 中访问 http://<burp_ip>:8080
2. 下载 Burp CA 证书
3. 设置 > 通用 > VPN 与设备管理 > 安装描述文件
4. 设置 > 通用 > 关于本机 > 证书信任设置 > 启用完全信任
配置好代理后,打开目标应用并浏览其功能:
Burp Suite > Proxy > HTTP History:查看所有捕获的请求和响应。
重点分析区域:
将拦截的请求转发到 Repeater 进行手动测试:
右键请求 > Send to Repeater
测试类别:
- 认证绕过:删除/修改认证令牌
- IDOR:修改用户 ID、对象引用
- 注入:参数中的 SQL 注入、NoSQL 注入
- 频率限制:快速重放请求评估暴力破解防御
- 业务逻辑:修改请求中的价格、数量、权限
右键请求 > Do active scan(仅 Professional 版)
扫描器检查项:
- SQL 注入(基于错误、盲注、时间盲注)
- XSS(反射型、存储型)
- 命令注入
- 路径遍历
- XML/JSON 注入
- 认证缺陷
如果由于证书固定无法看到流量:
# 基于 Frida 的通用绕过
frida -U -f com.target.app -l ssl-pinning-bypass.js
# Objection 绕过
objection --gadget com.target.app explore
ios sslpinning disable # 或
android sslpinning disable
| 术语 | 定义 |
|---|---|
| MITM 代理 | 中间人代理,终止并重新建立 TLS 连接以检查加密流量 |
| 证书固定(Certificate Pinning) | 客户端验证,在操作系统信任库之外限制可接受的服务器证书 |
| 网络安全配置(Network Security Config) | Android XML 配置,控制应用信任锚点、明文流量策略和证书固定 |
| 透明代理(Invisible Proxying) | Burp 功能,处理不发送 CONNECT 请求的非代理感知客户端 |
| IDOR | 不安全直接对象引用(Insecure Direct Object Reference)——无需授权检查即可通过操纵标识符访问资源 |