转:http://blog.csdn.net/messageloop3/article/details/9966727

在iOS端如何使用Charles用作http调试

After noticing that the caching in iPad Safari seemed a little funky, I made an effort to decipher some of the logic used by the browser cache. I didn’t get very far, but in the process I figured out how to route my iPad HTTP traffic through a web debugger on my laptop. It turns out it was very easy to do (although I’m sure there is a more complicated way to go about it).

What follows is a simple step-by-step for connecting your iPad to an HTTP debugging proxy. The main requirement is that your desktop/laptop and iPad be on the same wireless network. Then it’s just a matter of telling your iPad to use your desktop as an HTTP proxy.

I’m going to walk through how to do this on a Mac with the highly recommended HTTP proxy appCharles, but the same basic steps should also work for a Windows HTTP debugger such as Fiddler. (Update: Fiddler users, see Eric Lawrence’s comment below.) Additionally, the steps are the same for connecting your iPhone or iPod Touch.

1. Get your system IP address for your desktop

The easiest way to do this on a Mac is to Spotlight your way to the “Network Utility” app. Make sure you’re on your Wi-Fi network and take note of the IP address. This is your desktop’s local IP.

2. Tell your iPad about your desktop IP

On your iPad, go to Settings > Wi-Fi and click the arrow next your Wi-Fi connection. Under “HTTP Proxy”, select the Manual button and enter your desktop’s IP address in the Server field. Then enter “8888″ in the Port field. Close out.

3. Configure Charles

Open Charles and select Proxy > Proxy Settings. Under the Proxies tab, make sure the HTTP proxy value is set to 8888. Then click the “Mac OS X” tab and check “Enable Mac OS X Proxy” and “Use HTTP Proxy”. Click OK.

4. Start capturing HTTP traffic

Click the Record button in Charles and then load a web page in iPad Safari. You should see the following alert asking you if you want to allow your iPad to connect to Charles. Select “Allow”.

Now all of your HTTP traffic in iPad Safari should be recorded by Charles.

When you’re finished doing all of your fun HTTP debugging, don’t forget to turn off the HTTP proxy in the Wi-Fi settings of your iPad.

在iOS端如何使用Charles用作http调试相关推荐

  1. IOS端 vux中scroll滚动自动回弹到顶部或者左侧的解决办法

    IOS端 vux中scroll滚动自动回弹到顶部或者左侧的解决办法 问题表象 在滑动的时候,偶发性出现自动回弹到顶部的现象,通过onScroll回调发现scrollTop为-1造成回弹,开始寻找为什么 ...

  2. ios手机如何安装charles抓包工具证书

    ios手机如何安装charles抓包工具证书 安装证书前提,已经下载好charles 1.打开手机设置–WiFi–配置代理–点击手动–填写(服务器,端口号)–点击存储 不知道服务器和端口号,在char ...

  3. iOS端URL编码和解码过程

    一.URL含义 1.URL定义 URL 是Uniform Resource Locator 的缩写,统一资源定位符,对可以从互联网上得到的资源的位置和访问方法的一种简洁的表示,是互联网上标准资源的地址 ...

  4. iOS、Android连接Charles代理(Mac版)

    iOS.Android连接Charles代理(Mac版) 1.软件Charles的下载 网址:https://www.charlesproxy.com/ 选择下载Mac OS版本就行了,待安装完成后 ...

  5. iOS端矢量图解决方案汇总

    Python实战社群 Java实战社群 长按识别下方二维码,按需求添加 扫码关注添加客服 进Python社群▲ 扫码关注添加客服 进Java社群▲ 作者 | 小猪  来源 | 小猪的博客 https: ...

  6. iOS端Socket连接、发送数据(一)

    一.Socket的应用 IM即时通讯是通过Socket的方式实现长连接,可运用于 (1)直播聊天室.礼物 (2)微信.QQ等即时聊天 (3)游戏对话.技能等 二.SOCKET原理 套接字(socket ...

  7. unity android模糊ios清晰,Unity NGUI UI 在iOS端的锯齿、模糊、颗粒感问题

    一般我们在Unity项目中,都是美术给到图片,然后程序直接导入Unity,Android端给图片设置为 RBGA Compressed ETC2 8bit,iOS端给图片设置为 RBGA Compre ...

  8. ios端 input输入框遮挡问题解决

    ios端 input输入框遮挡问题解决 参考文章: (1)ios端 input输入框遮挡问题解决 (2)https://www.cnblogs.com/yhweb/p/8873239.html (3) ...

  9. h5 解决ios端输入框失去焦点后页面不回弹或者底部留白问题

    h5 解决ios端输入框失去焦点后页面不回弹或者底部留白问题 参考文章: (1)h5 解决ios端输入框失去焦点后页面不回弹或者底部留白问题 (2)https://www.cnblogs.com/bl ...

最新文章

  1. CentOS 6.3+Python 2.7.10安装pycurl遇到的问题汇总
  2. win7系统如何提高电脑运行速度
  3. 开关电源中的磁性元件书籍_总结丨PFC开关电源的效率优化措施
  4. 安卓学习日志 Day15 — 数据库基础
  5. python并发编程gevent模块以及猴子补丁学习
  6. 计算机通信机房消防要求,消防专用电话的设置场所及设计要求
  7. PCB绘制成长日记1
  8. KEPServer EX6的Modbus、MQTT和REST Server一站式配置整理说明
  9. 再战双十一,阿里这回真的“上天”了!
  10. 哈利波特分院考试(HP)
  11. hdu 1859 最小长方形
  12. 2021十大手表品牌TOP排行榜
  13. 使用adb命令操作多台设备
  14. C/C++:实现精灵游戏
  15. js 斐波那契—卢卡斯数列 例子 以及 变态青蛙
  16. 在C语言中,int型数据的取值范围?
  17. TX轻量应用级云服务器安装win7 win10
  18. Windows批量修改文件名后缀
  19. 一个查询汉字古写法的网站(有甲骨文、金文、小篆)
  20. 优雅解析民族代码java_那些高端、优雅的注解是怎么实现的4 -- 使用Annotaion Processing Tool 解析注解...

热门文章

  1. 算法er的尽头会是To B吗?
  2. 尹伊:用敏捷开发思维来成长!
  3. 英伟达GPU“屠榜”,谷歌TPU“退赛”,MLPerf最新推理榜单出炉
  4. Softmax和Cross-entropy是什么关系?
  5. CNN结构设计技巧:兼顾速度精度与工程实现
  6. 腾讯优图10篇AAAI论文解析,涉及数学速算批改、视频识别和语义分割 | 附下载...
  7. 【每日一算法】二叉树的最大深度
  8. 数据统计之用户总量统计
  9. 集成学习之Bagging
  10. 尚硅谷学Javaweb,关于正则表达式笔记