diff --git a/wp-includes/class-http.php b/wp-includes/class-http.php index 692b499778..8360abcb03 100644 --- a/wp-includes/class-http.php +++ b/wp-includes/class-http.php @@ -347,6 +347,17 @@ class WP_Http { */ $options['verify'] = apply_filters( 'https_ssl_verify', $options['verify'] ); + // Check for proxies. + $proxy = new WP_HTTP_Proxy(); + if ( $proxy->is_enabled() && $proxy->send_through_proxy( $url ) ) { + $options['proxy'] = new Requests_Proxy_HTTP( $proxy->host() . ':' . $proxy->port() ); + + if ( $proxy->use_authentication() ) { + $options['proxy']->user = $proxy->username(); + $options['proxy']->pass = $proxy->password(); + } + } + try { $requests_response = Requests::request( $url, $headers, $data, $type, $options ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 3ffda2fb2c..8f9637005c 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.6-beta2-38053'; +$wp_version = '4.6-beta2-38054'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.