[wp-trac] [WordPress Trac] #37614: WP_PROXY_BYPASS_HOSTS has no effect inside curl transport, if http_proxy or https_proxy is set on the system

WordPress Trac noreply at wordpress.org
Fri Aug 12 04:58:22 UTC 2016


#37614: WP_PROXY_BYPASS_HOSTS has no effect inside curl transport, if http_proxy or
https_proxy is set on the system
--------------------------+-----------------------------
 Reporter:  fliespl       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Future Release
Component:  HTTP API      |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:
--------------------------+-----------------------------
Changes (by dd32):

 * milestone:  Awaiting Review => Future Release


Comment:

 Thanks @fliespl for your report. I've confirmed that both WordPress 4.5
 (WP_HTTP) and 4.6/trunk (using Requests) have this issue.

 The issue as I see it, is that cURL is using the
 `http_proxy`/`https_proxy` environmental variable in the first place,
 which it shouldn't be in our environment.
 Changing this however will potentially mean that some configurations which
 have expected these environmental variables to be respected will break. I
 feel like I'm okay with that.

 @rmccue What's your thoughts here? This isn't a regression in the switch
 to Requests, but will need to be filed as an upstream bug for Requests
 regardless.  An additional `curl_setopt($this->handle, CURLOPT_PROXY,
 null);` in the `Requests_Transport_cURL::__constructor()` does work around
 this, and should allow properly defined proxies to work. Or is Requests
 designed to respect these environment variables?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/37614#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list