1.安装
a.可以从官网下载:https://www.charlesproxy.com/download/,根据自己的电脑平台选择适合自己的下载
b.Mac 下推荐一个网站:http://xclient.info/,可以查找到charles 进行下载,均为破解版。
c.破解方式:1.下载后将charles.jar文件复制到对应的文件中。mac下路径为:/Applications/Charles.app/Contents/Java/ 。
2.使用SN.txt中的序列码,进行注册成功
2.使用方式—手机党
a.打开charles后,选择proxy -> proxySettings ->Proxies,可以根据自己的喜好设置你的端口号。比如我设置的8801

b.使你需要抓包的手机设置服务器和端口号:服务器为电脑的ip,端口号设置为charles 设置的端口号

3.此时charles 会弹出连接的弹框

4.点击Allow,就可以进行抓包了
打开你需要测试的app,以移动工作站为例
3.PC端
a.直接选择 代理对用的浏览器

b.点击你需要测试的网页

4.界面介绍
a.Structure

b.Sequence

扫帚:清除当前session的数据
红点:亮着:表示录制开始;灰色:表示录制结束
乌龟:灰色:网速限制关闭;亮着:网速限制打开
六边形:灰色:断点不可用;亮着:断点可用
c.各功能使用
BreakpointSetting:对某个接口或一系列接口进行断点设置
在各字段中输入需要设置断点的接口
对于一系列接口需要使用通配符进行设置
可以对request或repsonse 进行设置(断点断在request还是response)

SSLSetting:针对https的连接无法连接上,设置对应的ssl 即可

Mapping Remote:经本地的地址修改为远程服务器的地址


Local Remote:修改为本地的设置的结果,将response 修改的数据 使用本地文件设置
Rewrite :可以修改接口的请求头,返回值等
网友评论