fiddler android app https 安卓app https 安卓 浏览器 https

在配置了捕获https流量的配置后,一直没能突破捕获手机app https类型的流量。

每次都返回:

 After the client received notice of the established CONNECT, it failed to send any data. 
大概意思是当客户端接收到建立链接的通知后没有发送任何数据。

这次我们来突破一下

第一步:


第二步:

CertMaker for iOS and Android

地址在这里:https://www.telerik.com/fiddler/add-ons
certMaker for iOS and Android 安装后重启fiddler

第三步:
导出fiddler根证书,安装到手机

导出的证书放到手机根目录下
打开手机  系统设置--->安全和隐私--->从SD卡安装证书


第四步:
最关键的一步来了,之前一直卡在了这里。可能根据版本不同,修改方法不同
新版本已经内置了 fiddlerScript插件,这个插件可以修改fiddler脚本。
旧版本需要额外下载fiddlerScript Editor才可以实现编辑的目的。




总的来说有两处需要修改
(1)找到 OnBeforeResponse 函数
如果有这么一段:
   if (oSession.HTTPMethodIs("CONNECT") && oSession.responseCode == 200)
    {
        if (oSession.oResponse.headers.ExistsAndEquals("Connection", "close"))
        {
            oSession.oResponse.headers.Remove("Connection");
        }
    }
一定要去掉,或者注释掉。
(2)还是找到  OnBeforeResponse 函数
如果没有这么一段:
if (oSession.oRequest["User-Agent"].indexOf("Android")> -1 && oSession.HTTPMethodIs("CONNECT")) 
{
        oSession.oResponse.headers["Connection"] = "Keep-Alive"; 
}
一定要加上。

修改完后,其最终效果如下:
 static function OnBeforeResponse(oSession: Session) {
        if (m_Hide304s && oSession.responseCode == 304) {
            oSession["ui-hide"] = "true";
        }
       
        if (oSession.oRequest["User-Agent"].indexOf("Android")> -1 && oSession.HTTPMethodIs("CONNECT")) {
            oSession.oResponse.headers["Connection"] = "Keep-Alive"; 
        }
        
    }
终于完活了。

在搞定捕获app的https流量后,又经历了手机浏览器https流量不能捕获的问题。恶心啊。我用的小米手机,原来小米手机自带浏览器不走系统的代理。
下了个uc就可以了 。



猜你喜欢

转载自blog.csdn.net/wang740209668/article/details/79269606