我正在使用 Charles Proxy 来监控 tomcat 服务中的流量,阅读文档后我在 catalina.bat 中添加一行:
设置JAVA_OPTS=%JAVA_OPTS% -agentpath:C:\yjpagent.dll -Dhttps.proxyHost=127.0.0.1 -Dhttps.proxyPort=8888 -Dhttp.proxyHost=127.0.0.1 -Dhttp.proxyPort=8888
但是 Charles 代理在服务运行时没有显示任何内容。
知道我应该做什么吗?
提前致谢。
更改此:
-Dhttps.proxyHost=127.0.0.1 -Dhttp.proxyHost=127.0.0.1
致:
-Dhttps.proxyHost=localhost.charlesproxy.com -Dhttp.proxyHost=localhost.charlesproxy.com
文档:这里
如果这对你不起作用。将以下内容添加到文件中
/etc/hosts
127.0.0.1 localhost.charlesproxy.com