更新时间:2023-02-24 11:39:56
我已经通过
Net
标签
刷新页面
右键单击要模拟的URL请求
选择cURL复制
In particular, I am attempting to replicate the behavior of firefox when I set it to use a proxy for https traffic.
From my tests, it appears that Firefox sends a CONNECT request to the proxy, while the following curl command directly sends GET to the proxy.
curl --proxy-basic mydomain.com:8001 https://www.google.com
How can I make curl behave like firefox for testing purposes with respect to the proxy for HTTPS connections?
EDIT1: The issue is not with the User-Agent, because I am not trying to fool the proxy into thinking I am firefox, only to help the proxy function the way it would with Firefox.
I've done this through Firebug.
Once you've installed firebug, follow this steps:
Net
tabRefresh the page
Right-click the URL request you want to simulate
Choose copy as cURL