How to use curl behind a McAfee Web Gateway?

curl seems to get some URLs just fine, while others get blocked with a response that indicates authentication is required and a valid cookie is missing.

I can download the same URL in Chrome. No proxy is configured in Chrome.


From what I've learned browsing StackOverflow the last few minutes, there are a few ways to try check if someone is using curl rather than a browser. Common ways include checking if the "browser" has javascript support, checking the user-agent and looking for missing request fields.

I attempted to use curl to access http://yahoo.com which returned a "Will be right back..." webpage. But, I then used wget with a user-agent borrowed from Firefox and I got the regular webpage. Try using wget to see if it makes a difference.