- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我阅读了所有关于这个主题的帖子,使用 genymotion 设置 charles 的说明都是一样的:
http://rexstjohn.com/using-genymotion-charles-proxy/
In your Genymotion Android emulator…
Settings -> Wifi -> Press and hold your active network
Select “Modify Network”
Select “Show Advanced Options”
Select “Proxy Settings -> Manual”
Set your Proxy to: 10.0.3.2 (Genymotion’s special code for the local workstation)
Set your Port to: 8888
Press Save
我的设置是:
我不确定说明是否过时,但我遇到的问题是从我的 genymotion 模拟器流出的流量记录在 Charles 代理中,但它只是没有到达我的本地主机服务器。我没有在我的服务器和我的应用程序之间使用任何 SSL 加密。
这是我在 genymotion wifi 屏幕中的设置:
这就是我的 Charles 代理的样子 - 您可以看到它正在“连接到远程主机”。它永远连接,然后最终在我的 Android 应用程序端给我一个 503 错误,没有任何返回:
如果我关闭 Charles Proxy,该应用程序可以毫无问题地连接到我的本地主机服务器,并且所有调用都会成功返回。我认为这与阻止我的应用程序与我的本地主机服务器通信的 Charles 有关。
在 Postman 中,如果我尝试查询与我的 Android 应用程序尝试查询的相同的 url,它会成功运行并且结果也成功地记录在 Charles 中:
http://localhost:8443/ + my api endpoint **OR** http://localhost.charlesproxy.com:8443/ + my api endpoint
在 Postman 中查询和在我的 android 应用程序中查询之间的唯一区别是我的应用程序点击了这个 url 10.0.3.2 而不是因为我正在使用模拟器:
http://10.0.3.2:8443/ + my api endpoint
我还在我的访问控制设置中添加了 10.0.3.2:
我可以进入我的 android genymotion 模拟器互联网浏览器并搜索像 www.msn.com 这样的网站,它会成功返回并在 Charles 中记录结果,但我不是在寻找或准备支付 50 美元购买记录我的安卓浏览器流量的工具。我需要它与我的 android 应用程序一起使用,以便我可以调试我的应用程序。我不确定如何解决这个问题,这里有人知道我是否遗漏了什么吗?
编辑:
如果有人想知道,我已经阅读了这篇关于 Charles 的关于本地主机流量未出现在 Charles 的常见问题解答的帖子:
https://www.charlesproxy.com/documentation/faqs/
但我不能将 Genymotion 使用的 10.0.3.2 更改为 http://localhost.charlesproxy.com/相反,所以我认为这不会解决我的问题。
最佳答案
所以我现在正在使用 Genymotion 模拟器和 Charles,实际上我设法让 Charles 记录本地主机流量。
类似于我通过 Postman 查询的方式:
http://localhost.charlesproxy.com:8443/ + my api endpoint
我只是将所有 api 端点的主机部分更改为:http://localhost.charlesproxy.com:8443/
并且它起作用了。
关于android - Genymotion 的 Charles Proxy 停止 10.0.3.2 localhost 流量,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36894298/
谁能解释一下 localhost:5000 之间的区别和其他本地主机。 谢谢你。 最佳答案 localhost:5000 正在访问端口 5000 上的 localhost。 例如,如果您从浏览器访问它
假设本地 Python 脚本正在运行网络服务器。 有没有办法设置别名,以便http://localwebapp/等于 http://localhost:1234/ ? 编辑:或至少 http://lo
我对网络开发完全陌生。所以我总是看到“localhost”之类的东西并问自己:那是什么? 我感觉知道什么是“主持人”了。执行某事的东西。所以我的 Mac 是其上运行的所有内容的主机。那么“localh
我正在学习 xmpp 编程,我使用 sudo apt-get install ejabberd 在我的 ubuntu 15.10 上安装了 ejabberd,然后我通过添加管理员用户 ejabberd
是否总是可以 ping localhost 并解析为 127.0.0.1? 我知道 Windows Vista、XP、Ubuntu 和 Debian 都这样做,但每个人都这样做吗? 最佳答案 任何正确
我们在同一台计算机上使用客户端/服务器 RMI 通信(因此所有 ip 都应该是本地主机)。 我们启动注册表(使用默认端口1099) registry = LocateRegistry.createRe
我已经在 windows/system32/drivers/etc/ 中验证了我的主机文件其中有一个 localhost 的条目,但它不会去任何地方。我必须在 URL 中有一个端口号:http://1
我的主机上有一个守护程序在某个端口(即 8008)上运行,我的代码通常通过联系 localhost:8008 与守护程序交互。 我现在已经将我的代码容器化了,但还没有将守护进程容器化。如何将容器上的
在 SMTP 中,HELO 命令之后应该是什么,它有什么作用? 我在我的应用程序中发送电子邮件,我想知道我是否应该使用 localhost、发件人地址的域名 (me@example.com)、应用程序
我遇到无法打开本地主机Web应用程序的问题,因为Microsoft Edge会将URL http://localhost:3000重定向到https://localhost:3000。因此,我得到了错
一直在尝试设置我想用于登录的 Facebook 应用程序,以允许我在 Mac 的本地主机上测试它。 Facebook 抛出错误“应用程序域:http://localhost 不是有效域。”当我尝试将站
我在 MacOS 10.15 上使用 minikube 1.4.0 版和 Kubernetes 1.16.0 版。 我正在开发一些依赖于外部服务的授权/认证代码。在对服务的 API 调用中,我需要提供
当我用谷歌搜索这个问题时,我注意到这是 nginx 的一个常见问题。但是我从来没有在我的机器上使用过 nginx。我使用 MAMP,偶尔使用 Python Bottle。 现在,无论我的 MAMP/P
我在本地运行 Squid,我想通过在 localhost:3000 上运行的 Ruby 服务器通过 Squid 进行访问。 如果我尝试访问 localhost:3000,我会收到以下消息: The f
我使用 VS 2012 默认模板创建了 MVC4 移动应用程序。使用 http://localhost/mvcapplication1/ 在桌面浏览器中运行良好但是当我尝试在 WP8 Emulator
如何将默认的 xampp localhost c:xampp/htdoc 更改为另一个文件夹,即 c:/alan?当我使用 IP 地址时,我应该能够在 C:/alan 中查看我的网站文件。 感谢您帮助
我正在使用带有centos版本6(Fedora)的Vmware。我正在使用hadoop 1.0.4版本。我的 http://localhost:50070 地址显示为“无法连接”,但是 http://
我正在运行带有 apache 2.4.38 和 Maria DB 10.1.38 + PHP 7.3.3 的 Windows Server 2016 有时,我可以看到(使用 netstat)从 127
尝试通过 SSH 连接到本地主机时的调试信息 ssh root@localhost -vvv 输出 OpenSSH_6.6.1、OpenSSL 1.0.1f 2014 年 1 月 6 日debug1:
我正在使用 Node 和 Laravel 编写一个应用程序。我正在运行小型 laravel 本地服务器,该服务器解析为 http://localhost:8000 。我还在 localhost:300
我是一名优秀的程序员,十分优秀!