* @param string $caller The method making this request, for profiling
* @return string|bool (bool)false on failure or a string on success
*/
- public static function request( $method, $url, $options = array(), $caller = __METHOD__ ) {
+ public static function request( $method, $url, $options = [], $caller = __METHOD__ ) {
wfDebug( "HTTP: $method: $url\n" );
$options['method'] = strtoupper( $method );
} else {
$errors = $status->getErrorsByType( 'error' );
$logger = LoggerFactory::getInstance( 'http' );
- $logger->warning( $status->getWikiText(), array( 'caller' => $caller ) );
+ $logger->warning( $status->getWikiText( null, null, 'en' ),
+ [ 'error' => $errors, 'caller' => $caller, 'content' => $req->getContent() ] );
return false;
}
}
* @param string $url
* @param array $options
* @param string $caller The method making this request, for profiling
- * @return string
+ * @return string|bool false on error
*/
- public static function get( $url, $options = array(), $caller = __METHOD__ ) {
+ public static function get( $url, $options = [], $caller = __METHOD__ ) {
$args = func_get_args();
if ( isset( $args[1] ) && ( is_string( $args[1] ) || is_numeric( $args[1] ) ) ) {
// Second was used to be the timeout
// And third parameter used to be $options
wfWarn( "Second parameter should not be a timeout.", 2 );
$options = isset( $args[2] ) && is_array( $args[2] ) ?
- $args[2] : array();
+ $args[2] : [];
$options['timeout'] = $args[1];
$caller = __METHOD__;
}
* @param string $url
* @param array $options
* @param string $caller The method making this request, for profiling
- * @return string
+ * @return string|bool false on error
*/
- public static function post( $url, $options = array(), $caller = __METHOD__ ) {
+ public static function post( $url, $options = [], $caller = __METHOD__ ) {
return Http::request( 'POST', $url, $options, $caller );
}
* @return bool
*/
public static function isLocalURL( $url ) {
- global $wgCommandLineMode, $wgLocalVirtualHosts, $wgConf;
+ global $wgCommandLineMode, $wgLocalVirtualHosts;
if ( $wgCommandLineMode ) {
return false;
}
// Extract host part
- $matches = array();
+ $matches = [];
if ( preg_match( '!^http://([\w.-]+)[/:].*$!', $url, $matches ) ) {
$host = $matches[1];
// Split up dotwise
$domain = $domainPart . '.' . $domain;
}
- if ( in_array( $domain, $wgLocalVirtualHosts )
- || $wgConf->isLocalVHost( $domain )
- ) {
+ if ( in_array( $domain, $wgLocalVirtualHosts ) ) {
return true;
}
}
$uri
);
}
+
+ /**
+ * Gets the relevant proxy from $wgHTTPProxy/http_proxy (when set).
+ *
+ * @return mixed The proxy address or an empty string if not set.
+ */
+ public static function getProxy() {
+ global $wgHTTPProxy;
+
+ if ( $wgHTTPProxy ) {
+ return $wgHTTPProxy;
+ }
+
+ $envHttpProxy = getenv( "http_proxy" );
+ if ( $envHttpProxy ) {
+ return $envHttpProxy;
+ }
+
+ return "";
+ }
}
/**
protected $sslVerifyCert = true;
protected $caInfo = null;
protected $method = "GET";
- protected $reqHeaders = array();
+ protected $reqHeaders = [];
protected $url;
protected $parsedUrl;
protected $callback;
*/
protected $cookieJar;
- protected $headerList = array();
+ protected $headerList = [];
protected $respVersion = "0.9";
protected $respStatus = "200 Ok";
- protected $respHeaders = array();
+ protected $respHeaders = [];
public $status;
* @param Profiler $profiler An instance of the profiler for profiling, or null
*/
protected function __construct(
- $url, $options = array(), $caller = __METHOD__, $profiler = null
+ $url, $options = [], $caller = __METHOD__, $profiler = null
) {
global $wgHTTPTimeout, $wgHTTPConnectTimeout;
$this->setUserAgent( $options['userAgent'] );
}
- $members = array( "postData", "proxy", "noProxy", "sslVerifyHost", "caInfo",
- "method", "followRedirects", "maxRedirects", "sslVerifyCert", "callback" );
+ $members = [ "postData", "proxy", "noProxy", "sslVerifyHost", "caInfo",
+ "method", "followRedirects", "maxRedirects", "sslVerifyCert", "callback" ];
foreach ( $members as $o ) {
if ( isset( $options[$o] ) ) {
* @return void
*/
public function proxySetup() {
- global $wgHTTPProxy;
-
// If there is an explicit proxy set and proxies are not disabled, then use it
if ( $this->proxy && !$this->noProxy ) {
return;
// local URL and proxies are not disabled
if ( Http::isLocalURL( $this->url ) || $this->noProxy ) {
$this->proxy = '';
- } elseif ( $wgHTTPProxy ) {
- $this->proxy = $wgHTTPProxy;
- } elseif ( getenv( "http_proxy" ) ) {
- $this->proxy = getenv( "http_proxy" );
+ } else {
+ $this->proxy = Http::getProxy();
}
}
* @return array
*/
public function getHeaderList() {
- $list = array();
+ $list = [];
if ( $this->cookieJar ) {
$this->reqHeaders['Cookie'] =
$this->proxySetup(); // set up any proxy as needed
if ( !$this->callback ) {
- $this->setCallback( array( $this, 'read' ) );
+ $this->setCallback( [ $this, 'read' ] );
}
if ( !isset( $this->reqHeaders['User-Agent'] ) ) {
class CurlHttpRequest extends MWHttpRequest {
const SUPPORTS_FILE_POSTS = true;
- protected $curlOptions = array();
+ protected $curlOptions = [];
protected $headerText = "";
/**
$this->curlOptions[CURLOPT_HTTP_VERSION] = CURL_HTTP_VERSION_1_0;
$this->curlOptions[CURLOPT_WRITEFUNCTION] = $this->callback;
- $this->curlOptions[CURLOPT_HEADERFUNCTION] = array( $this, "readHeader" );
+ $this->curlOptions[CURLOPT_HEADERFUNCTION] = [ $this, "readHeader" ];
$this->curlOptions[CURLOPT_MAXREDIRS] = $this->maxRedirects;
$this->curlOptions[CURLOPT_ENCODING] = ""; # Enable compression
$this->curlOptions[CURLOPT_HEADER] = true;
} elseif ( $this->method == 'POST' ) {
$this->curlOptions[CURLOPT_POST] = true;
- $this->curlOptions[CURLOPT_POSTFIELDS] = $this->postData;
+ $postData = $this->postData;
+ // Don't interpret POST parameters starting with '@' as file uploads, because this
+ // makes it impossible to POST plain values starting with '@' (and causes security
+ // issues potentially exposing the contents of local files).
+ // The PHP manual says this option was introduced in PHP 5.5 defaults to true in PHP 5.6,
+ // but we support lower versions, and the option doesn't exist in HHVM 5.6.99.
+ if ( defined( 'CURLOPT_SAFE_UPLOAD' ) ) {
+ $this->curlOptions[CURLOPT_SAFE_UPLOAD] = true;
+ } elseif ( is_array( $postData ) ) {
+ // In PHP 5.2 and later, '@' is interpreted as a file upload if POSTFIELDS
+ // is an array, but not if it's a string. So convert $req['body'] to a string
+ // for safety.
+ $postData = wfArrayToCgi( $postData );
+ }
+ $this->curlOptions[CURLOPT_POSTFIELDS] = $postData;
+
// Suppress 'Expect: 100-continue' header, as some servers
// will reject it with a 417 and Curl won't auto retry
// with HTTP 1.0 fallback
MediaWiki\suppressWarnings();
if ( !curl_setopt( $curlHandle, CURLOPT_FOLLOWLOCATION, true ) ) {
wfDebug( __METHOD__ . ": Couldn't set CURLOPT_FOLLOWLOCATION. " .
- "Probably safe_mode or open_basedir is set.\n" );
+ "Probably open_basedir is set.\n" );
// Continue the processing. If it were in curl_setopt_array,
// processing would have halted on its entry
}
}
if ( version_compare( PHP_VERSION, '5.6.0', '<' ) ) {
- if ( strval( ini_get( 'open_basedir' ) ) !== '' || wfIniGetBool( 'safe_mode' ) ) {
- wfDebug( "Cannot follow redirects in safe mode\n" );
+ if ( strval( ini_get( 'open_basedir' ) ) !== '' ) {
+ wfDebug( "Cannot follow redirects when open_basedir is set\n" );
return false;
}
}
class PhpHttpRequest extends MWHttpRequest {
- private $fopenErrors = array();
+ private $fopenErrors = [];
/**
* @param string $url
* @throws DomainException
*/
protected function getCertOptions() {
- $certOptions = array();
- $certLocations = array();
+ $certOptions = [];
+ $certLocations = [];
if ( $this->caInfo ) {
- $certLocations = array( 'manual' => $this->caInfo );
+ $certLocations = [ 'manual' => $this->caInfo ];
} elseif ( version_compare( PHP_VERSION, '5.6.0', '<' ) ) {
// @codingStandardsIgnoreStart Generic.Files.LineLength
// Default locations, based on
// PHP 5.6+ gets the CA location from OpenSSL as long as it is not set manually,
// so we should leave capath/cafile empty there.
// @codingStandardsIgnoreEnd
- $certLocations = array_filter( array(
+ $certLocations = array_filter( [
getenv( 'SSL_CERT_DIR' ),
getenv( 'SSL_CERT_PATH' ),
'/etc/pki/tls/certs/ca-bundle.crt', # Fedora et al
'/etc/pki/tls/certs/ca-bundle.trust.crt',
'/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem',
'/System/Library/OpenSSL', # OSX
- ) );
+ ] );
}
foreach ( $certLocations as $key => $cert ) {
*/
public function errorHandler( $errno, $errstr ) {
$n = count( $this->fopenErrors ) + 1;
- $this->fopenErrors += array( "errno$n" => $errno, "errstr$n" => $errstr );
+ $this->fopenErrors += [ "errno$n" => $errno, "errstr$n" => $errstr ];
}
public function execute() {
}
// Set up PHP stream context
- $options = array(
- 'http' => array(
+ $options = [
+ 'http' => [
'method' => $this->method,
'header' => implode( "\r\n", $this->getHeaderList() ),
'protocol_version' => '1.1',
// Curl options in case curlwrappers are installed
'curl_verify_ssl_host' => $this->sslVerifyHost ? 2 : 0,
'curl_verify_ssl_peer' => $this->sslVerifyCert,
- ),
- 'ssl' => array(
+ ],
+ 'ssl' => [
'verify_peer' => $this->sslVerifyCert,
'SNI_enabled' => true,
'ciphers' => 'HIGH:!SSLv2:!SSLv3:-ADH:-kDH:-kECDH:-DSS',
'disable_compression' => true,
- ),
- );
+ ],
+ ];
if ( $this->proxy ) {
- $options['http']['proxy'] = $this->urlToTCP( $this->proxy );
+ $options['http']['proxy'] = $this->urlToTcp( $this->proxy );
$options['http']['request_fulluri'] = true;
}
$context = stream_context_create( $options );
- $this->headerList = array();
+ $this->headerList = [];
$reqCount = 0;
$url = $this->url;
- $result = array();
+ $result = [];
if ( $this->profiler ) {
$profileSection = $this->profiler->scopedProfileIn(
}
do {
$reqCount++;
- $this->fopenErrors = array();
- set_error_handler( array( $this, 'errorHandler' ) );
+ $this->fopenErrors = [];
+ set_error_handler( [ $this, 'errorHandler' ] );
$fh = fopen( $url, "r", false, $context );
restore_error_handler();
}
public static function cookieDomains() {
- return array(
- array( false, "org" ),
- array( false, ".org" ),
- array( true, "wikipedia.org" ),
- array( true, ".wikipedia.org" ),
- array( false, "co.uk" ),
- array( false, ".co.uk" ),
- array( false, "gov.uk" ),
- array( false, ".gov.uk" ),
- array( true, "supermarket.uk" ),
- array( false, "uk" ),
- array( false, ".uk" ),
- array( false, "127.0.0." ),
- array( false, "127." ),
- array( false, "127.0.0.1." ),
- array( true, "127.0.0.1" ),
- array( false, "333.0.0.1" ),
- array( true, "example.com" ),
- array( false, "example.com." ),
- array( true, ".example.com" ),
+ return [
+ [ false, "org" ],
+ [ false, ".org" ],
+ [ true, "wikipedia.org" ],
+ [ true, ".wikipedia.org" ],
+ [ false, "co.uk" ],
+ [ false, ".co.uk" ],
+ [ false, "gov.uk" ],
+ [ false, ".gov.uk" ],
+ [ true, "supermarket.uk" ],
+ [ false, "uk" ],
+ [ false, ".uk" ],
+ [ false, "127.0.0." ],
+ [ false, "127." ],
+ [ false, "127.0.0.1." ],
+ [ true, "127.0.0.1" ],
+ [ false, "333.0.0.1" ],
+ [ true, "example.com" ],
+ [ false, "example.com." ],
+ [ true, ".example.com" ],
- array( true, ".example.com", "www.example.com" ),
- array( false, "example.com", "www.example.com" ),
- array( true, "127.0.0.1", "127.0.0.1" ),
- array( false, "127.0.0.1", "localhost" ),
- );
+ [ true, ".example.com", "www.example.com" ],
+ [ false, "example.com", "www.example.com" ],
+ [ true, "127.0.0.1", "127.0.0.1" ],
+ [ false, "127.0.0.1", "localhost" ],
+ ];
}
/**
);
}
+ /**
+ * @covers Http::getProxy
+ */
+ public function testGetProxy() {
+ $this->setMwGlobals( 'wgHTTPProxy', 'proxy.domain.tld' );
+ $this->assertEquals(
+ 'proxy.domain.tld',
+ Http::getProxy()
+ );
+ }
+
/**
* Feeds URI to test a long regular expression in Http::isValidURI
*/
public static function provideURI() {
/** Format: 'boolean expectation', 'URI to test', 'Optional message' */
- return array(
- array( false, '¿non sens before!! http://a', 'Allow anything before URI' ),
+ return [
+ [ false, '¿non sens before!! http://a', 'Allow anything before URI' ],
# (http|https) - only two schemes allowed
- array( true, 'http://www.example.org/' ),
- array( true, 'https://www.example.org/' ),
- array( true, 'http://www.example.org', 'URI without directory' ),
- array( true, 'http://a', 'Short name' ),
- array( true, 'http://étoile', 'Allow UTF-8 in hostname' ), # 'étoile' is french for 'star'
- array( false, '\\host\directory', 'CIFS share' ),
- array( false, 'gopher://host/dir', 'Reject gopher scheme' ),
- array( false, 'telnet://host', 'Reject telnet scheme' ),
+ [ true, 'http://www.example.org/' ],
+ [ true, 'https://www.example.org/' ],
+ [ true, 'http://www.example.org', 'URI without directory' ],
+ [ true, 'http://a', 'Short name' ],
+ [ true, 'http://étoile', 'Allow UTF-8 in hostname' ], # 'étoile' is french for 'star'
+ [ false, '\\host\directory', 'CIFS share' ],
+ [ false, 'gopher://host/dir', 'Reject gopher scheme' ],
+ [ false, 'telnet://host', 'Reject telnet scheme' ],
# :\/\/ - double slashes
- array( false, 'http//example.org', 'Reject missing colon in protocol' ),
- array( false, 'http:/example.org', 'Reject missing slash in protocol' ),
- array( false, 'http:example.org', 'Must have two slashes' ),
+ [ false, 'http//example.org', 'Reject missing colon in protocol' ],
+ [ false, 'http:/example.org', 'Reject missing slash in protocol' ],
+ [ false, 'http:example.org', 'Must have two slashes' ],
# Following fail since hostname can be made of anything
- array( false, 'http:///example.org', 'Must have exactly two slashes, not three' ),
+ [ false, 'http:///example.org', 'Must have exactly two slashes, not three' ],
# (\w+:{0,1}\w*@)? - optional user:pass
- array( true, 'http://user@host', 'Username provided' ),
- array( true, 'http://user:@host', 'Username provided, no password' ),
- array( true, 'http://user:pass@host', 'Username and password provided' ),
+ [ true, 'http://user@host', 'Username provided' ],
+ [ true, 'http://user:@host', 'Username provided, no password' ],
+ [ true, 'http://user:pass@host', 'Username and password provided' ],
# (\S+) - host part is made of anything not whitespaces
// commented these out in order to remove @group Broken
// array( false, 'http://exam:ple.org/', 'hostname can not use colons!' ),
# (:[0-9]+)? - port number
- array( true, 'http://example.org:80/' ),
- array( true, 'https://example.org:80/' ),
- array( true, 'http://example.org:443/' ),
- array( true, 'https://example.org:443/' ),
+ [ true, 'http://example.org:80/' ],
+ [ true, 'https://example.org:80/' ],
+ [ true, 'http://example.org:443/' ],
+ [ true, 'https://example.org:443/' ],
# Part after the hostname is / or / with something else
- array( true, 'http://example/#' ),
- array( true, 'http://example/!' ),
- array( true, 'http://example/:' ),
- array( true, 'http://example/.' ),
- array( true, 'http://example/?' ),
- array( true, 'http://example/+' ),
- array( true, 'http://example/=' ),
- array( true, 'http://example/&' ),
- array( true, 'http://example/%' ),
- array( true, 'http://example/@' ),
- array( true, 'http://example/-' ),
- array( true, 'http://example//' ),
- array( true, 'http://example/&' ),
+ [ true, 'http://example/#' ],
+ [ true, 'http://example/!' ],
+ [ true, 'http://example/:' ],
+ [ true, 'http://example/.' ],
+ [ true, 'http://example/?' ],
+ [ true, 'http://example/+' ],
+ [ true, 'http://example/=' ],
+ [ true, 'http://example/&' ],
+ [ true, 'http://example/%' ],
+ [ true, 'http://example/@' ],
+ [ true, 'http://example/-' ],
+ [ true, 'http://example//' ],
+ [ true, 'http://example/&' ],
# Fragment
- array( true, 'http://exam#ple.org', ), # This one is valid, really!
- array( true, 'http://example.org:80#anchor' ),
- array( true, 'http://example.org/?id#anchor' ),
- array( true, 'http://example.org/?#anchor' ),
+ [ true, 'http://exam#ple.org', ], # This one is valid, really!
+ [ true, 'http://example.org:80#anchor' ],
+ [ true, 'http://example.org/?id#anchor' ],
+ [ true, 'http://example.org/?#anchor' ],
- array( false, 'http://a ¿non !!sens after', 'Allow anything after URI' ),
- );
+ [ false, 'http://a ¿non !!sens after', 'Allow anything after URI' ],
+ ];
}
/**
* HTTP redirects).
*/
public function testRelativeRedirections() {
- $h = MWHttpRequestTester::factory( 'http://oldsite/file.ext', array(), __METHOD__ );
+ $h = MWHttpRequestTester::factory( 'http://oldsite/file.ext', [], __METHOD__ );
# Forge a Location header
- $h->setRespHeaders( 'location', array(
+ $h->setRespHeaders( 'location', [
'http://newsite/file.ext',
'/newfile.ext',
- )
+ ]
);
# Verify we correctly fix the Location
$this->assertEquals(
"Relative file path Location: interpreted as full URL"
);
- $h->setRespHeaders( 'location', array(
+ $h->setRespHeaders( 'location', [
'https://oldsite/file.ext'
- )
+ ]
);
$this->assertEquals(
'https://oldsite/file.ext',
"Location to the HTTPS version of the site"
);
- $h->setRespHeaders( 'location', array(
+ $h->setRespHeaders( 'location', [
'/anotherfile.ext',
'http://anotherfile/hoster.ext',
'https://anotherfile/hoster.ext'
- )
+ ]
);
$this->assertEquals(
'https://anotherfile/hoster.ext',
* @covers CurlHttpRequest::execute
*/
public function provideCurlConstants() {
- return array(
- array( 'CURLAUTH_ANY' ),
- array( 'CURLAUTH_ANYSAFE' ),
- array( 'CURLAUTH_BASIC' ),
- array( 'CURLAUTH_DIGEST' ),
- array( 'CURLAUTH_GSSNEGOTIATE' ),
- array( 'CURLAUTH_NTLM' ),
+ return [
+ [ 'CURLAUTH_ANY' ],
+ [ 'CURLAUTH_ANYSAFE' ],
+ [ 'CURLAUTH_BASIC' ],
+ [ 'CURLAUTH_DIGEST' ],
+ [ 'CURLAUTH_GSSNEGOTIATE' ],
+ [ 'CURLAUTH_NTLM' ],
// array( 'CURLCLOSEPOLICY_CALLBACK' ), // removed in PHP 5.6.0
// array( 'CURLCLOSEPOLICY_LEAST_RECENTLY_USED' ), // removed in PHP 5.6.0
// array( 'CURLCLOSEPOLICY_LEAST_TRAFFIC' ), // removed in PHP 5.6.0
// array( 'CURLCLOSEPOLICY_OLDEST' ), // removed in PHP 5.6.0
// array( 'CURLCLOSEPOLICY_SLOWEST' ), // removed in PHP 5.6.0
- array( 'CURLE_ABORTED_BY_CALLBACK' ),
- array( 'CURLE_BAD_CALLING_ORDER' ),
- array( 'CURLE_BAD_CONTENT_ENCODING' ),
- array( 'CURLE_BAD_FUNCTION_ARGUMENT' ),
- array( 'CURLE_BAD_PASSWORD_ENTERED' ),
- array( 'CURLE_COULDNT_CONNECT' ),
- array( 'CURLE_COULDNT_RESOLVE_HOST' ),
- array( 'CURLE_COULDNT_RESOLVE_PROXY' ),
- array( 'CURLE_FAILED_INIT' ),
- array( 'CURLE_FILESIZE_EXCEEDED' ),
- array( 'CURLE_FILE_COULDNT_READ_FILE' ),
- array( 'CURLE_FTP_ACCESS_DENIED' ),
- array( 'CURLE_FTP_BAD_DOWNLOAD_RESUME' ),
- array( 'CURLE_FTP_CANT_GET_HOST' ),
- array( 'CURLE_FTP_CANT_RECONNECT' ),
- array( 'CURLE_FTP_COULDNT_GET_SIZE' ),
- array( 'CURLE_FTP_COULDNT_RETR_FILE' ),
- array( 'CURLE_FTP_COULDNT_SET_ASCII' ),
- array( 'CURLE_FTP_COULDNT_SET_BINARY' ),
- array( 'CURLE_FTP_COULDNT_STOR_FILE' ),
- array( 'CURLE_FTP_COULDNT_USE_REST' ),
- array( 'CURLE_FTP_PORT_FAILED' ),
- array( 'CURLE_FTP_QUOTE_ERROR' ),
- array( 'CURLE_FTP_SSL_FAILED' ),
- array( 'CURLE_FTP_USER_PASSWORD_INCORRECT' ),
- array( 'CURLE_FTP_WEIRD_227_FORMAT' ),
- array( 'CURLE_FTP_WEIRD_PASS_REPLY' ),
- array( 'CURLE_FTP_WEIRD_PASV_REPLY' ),
- array( 'CURLE_FTP_WEIRD_SERVER_REPLY' ),
- array( 'CURLE_FTP_WEIRD_USER_REPLY' ),
- array( 'CURLE_FTP_WRITE_ERROR' ),
- array( 'CURLE_FUNCTION_NOT_FOUND' ),
- array( 'CURLE_GOT_NOTHING' ),
- array( 'CURLE_HTTP_NOT_FOUND' ),
- array( 'CURLE_HTTP_PORT_FAILED' ),
- array( 'CURLE_HTTP_POST_ERROR' ),
- array( 'CURLE_HTTP_RANGE_ERROR' ),
- array( 'CURLE_LDAP_CANNOT_BIND' ),
- array( 'CURLE_LDAP_INVALID_URL' ),
- array( 'CURLE_LDAP_SEARCH_FAILED' ),
- array( 'CURLE_LIBRARY_NOT_FOUND' ),
- array( 'CURLE_MALFORMAT_USER' ),
- array( 'CURLE_OBSOLETE' ),
- array( 'CURLE_OK' ),
- array( 'CURLE_OPERATION_TIMEOUTED' ),
- array( 'CURLE_OUT_OF_MEMORY' ),
- array( 'CURLE_PARTIAL_FILE' ),
- array( 'CURLE_READ_ERROR' ),
- array( 'CURLE_RECV_ERROR' ),
- array( 'CURLE_SEND_ERROR' ),
- array( 'CURLE_SHARE_IN_USE' ),
+ [ 'CURLE_ABORTED_BY_CALLBACK' ],
+ [ 'CURLE_BAD_CALLING_ORDER' ],
+ [ 'CURLE_BAD_CONTENT_ENCODING' ],
+ [ 'CURLE_BAD_FUNCTION_ARGUMENT' ],
+ [ 'CURLE_BAD_PASSWORD_ENTERED' ],
+ [ 'CURLE_COULDNT_CONNECT' ],
+ [ 'CURLE_COULDNT_RESOLVE_HOST' ],
+ [ 'CURLE_COULDNT_RESOLVE_PROXY' ],
+ [ 'CURLE_FAILED_INIT' ],
+ [ 'CURLE_FILESIZE_EXCEEDED' ],
+ [ 'CURLE_FILE_COULDNT_READ_FILE' ],
+ [ 'CURLE_FTP_ACCESS_DENIED' ],
+ [ 'CURLE_FTP_BAD_DOWNLOAD_RESUME' ],
+ [ 'CURLE_FTP_CANT_GET_HOST' ],
+ [ 'CURLE_FTP_CANT_RECONNECT' ],
+ [ 'CURLE_FTP_COULDNT_GET_SIZE' ],
+ [ 'CURLE_FTP_COULDNT_RETR_FILE' ],
+ [ 'CURLE_FTP_COULDNT_SET_ASCII' ],
+ [ 'CURLE_FTP_COULDNT_SET_BINARY' ],
+ [ 'CURLE_FTP_COULDNT_STOR_FILE' ],
+ [ 'CURLE_FTP_COULDNT_USE_REST' ],
+ [ 'CURLE_FTP_PORT_FAILED' ],
+ [ 'CURLE_FTP_QUOTE_ERROR' ],
+ [ 'CURLE_FTP_SSL_FAILED' ],
+ [ 'CURLE_FTP_USER_PASSWORD_INCORRECT' ],
+ [ 'CURLE_FTP_WEIRD_227_FORMAT' ],
+ [ 'CURLE_FTP_WEIRD_PASS_REPLY' ],
+ [ 'CURLE_FTP_WEIRD_PASV_REPLY' ],
+ [ 'CURLE_FTP_WEIRD_SERVER_REPLY' ],
+ [ 'CURLE_FTP_WEIRD_USER_REPLY' ],
+ [ 'CURLE_FTP_WRITE_ERROR' ],
+ [ 'CURLE_FUNCTION_NOT_FOUND' ],
+ [ 'CURLE_GOT_NOTHING' ],
+ [ 'CURLE_HTTP_NOT_FOUND' ],
+ [ 'CURLE_HTTP_PORT_FAILED' ],
+ [ 'CURLE_HTTP_POST_ERROR' ],
+ [ 'CURLE_HTTP_RANGE_ERROR' ],
+ [ 'CURLE_LDAP_CANNOT_BIND' ],
+ [ 'CURLE_LDAP_INVALID_URL' ],
+ [ 'CURLE_LDAP_SEARCH_FAILED' ],
+ [ 'CURLE_LIBRARY_NOT_FOUND' ],
+ [ 'CURLE_MALFORMAT_USER' ],
+ [ 'CURLE_OBSOLETE' ],
+ [ 'CURLE_OK' ],
+ [ 'CURLE_OPERATION_TIMEOUTED' ],
+ [ 'CURLE_OUT_OF_MEMORY' ],
+ [ 'CURLE_PARTIAL_FILE' ],
+ [ 'CURLE_READ_ERROR' ],
+ [ 'CURLE_RECV_ERROR' ],
+ [ 'CURLE_SEND_ERROR' ],
+ [ 'CURLE_SHARE_IN_USE' ],
// array( 'CURLE_SSH' ), // not present in HHVM 3.3.0-dev
- array( 'CURLE_SSL_CACERT' ),
- array( 'CURLE_SSL_CERTPROBLEM' ),
- array( 'CURLE_SSL_CIPHER' ),
- array( 'CURLE_SSL_CONNECT_ERROR' ),
- array( 'CURLE_SSL_ENGINE_NOTFOUND' ),
- array( 'CURLE_SSL_ENGINE_SETFAILED' ),
- array( 'CURLE_SSL_PEER_CERTIFICATE' ),
- array( 'CURLE_TELNET_OPTION_SYNTAX' ),
- array( 'CURLE_TOO_MANY_REDIRECTS' ),
- array( 'CURLE_UNKNOWN_TELNET_OPTION' ),
- array( 'CURLE_UNSUPPORTED_PROTOCOL' ),
- array( 'CURLE_URL_MALFORMAT' ),
- array( 'CURLE_URL_MALFORMAT_USER' ),
- array( 'CURLE_WRITE_ERROR' ),
- array( 'CURLFTPAUTH_DEFAULT' ),
- array( 'CURLFTPAUTH_SSL' ),
- array( 'CURLFTPAUTH_TLS' ),
+ [ 'CURLE_SSL_CACERT' ],
+ [ 'CURLE_SSL_CERTPROBLEM' ],
+ [ 'CURLE_SSL_CIPHER' ],
+ [ 'CURLE_SSL_CONNECT_ERROR' ],
+ [ 'CURLE_SSL_ENGINE_NOTFOUND' ],
+ [ 'CURLE_SSL_ENGINE_SETFAILED' ],
+ [ 'CURLE_SSL_PEER_CERTIFICATE' ],
+ [ 'CURLE_TELNET_OPTION_SYNTAX' ],
+ [ 'CURLE_TOO_MANY_REDIRECTS' ],
+ [ 'CURLE_UNKNOWN_TELNET_OPTION' ],
+ [ 'CURLE_UNSUPPORTED_PROTOCOL' ],
+ [ 'CURLE_URL_MALFORMAT' ],
+ [ 'CURLE_URL_MALFORMAT_USER' ],
+ [ 'CURLE_WRITE_ERROR' ],
+ [ 'CURLFTPAUTH_DEFAULT' ],
+ [ 'CURLFTPAUTH_SSL' ],
+ [ 'CURLFTPAUTH_TLS' ],
// array( 'CURLFTPMETHOD_MULTICWD' ), // not present in HHVM 3.3.0-dev
// array( 'CURLFTPMETHOD_NOCWD' ), // not present in HHVM 3.3.0-dev
// array( 'CURLFTPMETHOD_SINGLECWD' ), // not present in HHVM 3.3.0-dev
- array( 'CURLFTPSSL_ALL' ),
- array( 'CURLFTPSSL_CONTROL' ),
- array( 'CURLFTPSSL_NONE' ),
- array( 'CURLFTPSSL_TRY' ),
+ [ 'CURLFTPSSL_ALL' ],
+ [ 'CURLFTPSSL_CONTROL' ],
+ [ 'CURLFTPSSL_NONE' ],
+ [ 'CURLFTPSSL_TRY' ],
// array( 'CURLINFO_CERTINFO' ), // not present in HHVM 3.3.0-dev
- array( 'CURLINFO_CONNECT_TIME' ),
- array( 'CURLINFO_CONTENT_LENGTH_DOWNLOAD' ),
- array( 'CURLINFO_CONTENT_LENGTH_UPLOAD' ),
- array( 'CURLINFO_CONTENT_TYPE' ),
- array( 'CURLINFO_EFFECTIVE_URL' ),
- array( 'CURLINFO_FILETIME' ),
- array( 'CURLINFO_HEADER_OUT' ),
- array( 'CURLINFO_HEADER_SIZE' ),
- array( 'CURLINFO_HTTP_CODE' ),
- array( 'CURLINFO_NAMELOOKUP_TIME' ),
- array( 'CURLINFO_PRETRANSFER_TIME' ),
- array( 'CURLINFO_PRIVATE' ),
- array( 'CURLINFO_REDIRECT_COUNT' ),
- array( 'CURLINFO_REDIRECT_TIME' ),
+ [ 'CURLINFO_CONNECT_TIME' ],
+ [ 'CURLINFO_CONTENT_LENGTH_DOWNLOAD' ],
+ [ 'CURLINFO_CONTENT_LENGTH_UPLOAD' ],
+ [ 'CURLINFO_CONTENT_TYPE' ],
+ [ 'CURLINFO_EFFECTIVE_URL' ],
+ [ 'CURLINFO_FILETIME' ],
+ [ 'CURLINFO_HEADER_OUT' ],
+ [ 'CURLINFO_HEADER_SIZE' ],
+ [ 'CURLINFO_HTTP_CODE' ],
+ [ 'CURLINFO_NAMELOOKUP_TIME' ],
+ [ 'CURLINFO_PRETRANSFER_TIME' ],
+ [ 'CURLINFO_PRIVATE' ],
+ [ 'CURLINFO_REDIRECT_COUNT' ],
+ [ 'CURLINFO_REDIRECT_TIME' ],
// array( 'CURLINFO_REDIRECT_URL' ), // not present in HHVM 3.3.0-dev
- array( 'CURLINFO_REQUEST_SIZE' ),
- array( 'CURLINFO_SIZE_DOWNLOAD' ),
- array( 'CURLINFO_SIZE_UPLOAD' ),
- array( 'CURLINFO_SPEED_DOWNLOAD' ),
- array( 'CURLINFO_SPEED_UPLOAD' ),
- array( 'CURLINFO_SSL_VERIFYRESULT' ),
- array( 'CURLINFO_STARTTRANSFER_TIME' ),
- array( 'CURLINFO_TOTAL_TIME' ),
- array( 'CURLMSG_DONE' ),
- array( 'CURLM_BAD_EASY_HANDLE' ),
- array( 'CURLM_BAD_HANDLE' ),
- array( 'CURLM_CALL_MULTI_PERFORM' ),
- array( 'CURLM_INTERNAL_ERROR' ),
- array( 'CURLM_OK' ),
- array( 'CURLM_OUT_OF_MEMORY' ),
- array( 'CURLOPT_AUTOREFERER' ),
- array( 'CURLOPT_BINARYTRANSFER' ),
- array( 'CURLOPT_BUFFERSIZE' ),
- array( 'CURLOPT_CAINFO' ),
- array( 'CURLOPT_CAPATH' ),
+ [ 'CURLINFO_REQUEST_SIZE' ],
+ [ 'CURLINFO_SIZE_DOWNLOAD' ],
+ [ 'CURLINFO_SIZE_UPLOAD' ],
+ [ 'CURLINFO_SPEED_DOWNLOAD' ],
+ [ 'CURLINFO_SPEED_UPLOAD' ],
+ [ 'CURLINFO_SSL_VERIFYRESULT' ],
+ [ 'CURLINFO_STARTTRANSFER_TIME' ],
+ [ 'CURLINFO_TOTAL_TIME' ],
+ [ 'CURLMSG_DONE' ],
+ [ 'CURLM_BAD_EASY_HANDLE' ],
+ [ 'CURLM_BAD_HANDLE' ],
+ [ 'CURLM_CALL_MULTI_PERFORM' ],
+ [ 'CURLM_INTERNAL_ERROR' ],
+ [ 'CURLM_OK' ],
+ [ 'CURLM_OUT_OF_MEMORY' ],
+ [ 'CURLOPT_AUTOREFERER' ],
+ [ 'CURLOPT_BINARYTRANSFER' ],
+ [ 'CURLOPT_BUFFERSIZE' ],
+ [ 'CURLOPT_CAINFO' ],
+ [ 'CURLOPT_CAPATH' ],
// array( 'CURLOPT_CERTINFO' ), // not present in HHVM 3.3.0-dev
// array( 'CURLOPT_CLOSEPOLICY' ), // removed in PHP 5.6.0
- array( 'CURLOPT_CONNECTTIMEOUT' ),
- array( 'CURLOPT_CONNECTTIMEOUT_MS' ),
- array( 'CURLOPT_COOKIE' ),
- array( 'CURLOPT_COOKIEFILE' ),
- array( 'CURLOPT_COOKIEJAR' ),
- array( 'CURLOPT_COOKIESESSION' ),
- array( 'CURLOPT_CRLF' ),
- array( 'CURLOPT_CUSTOMREQUEST' ),
- array( 'CURLOPT_DNS_CACHE_TIMEOUT' ),
- array( 'CURLOPT_DNS_USE_GLOBAL_CACHE' ),
- array( 'CURLOPT_EGDSOCKET' ),
- array( 'CURLOPT_ENCODING' ),
- array( 'CURLOPT_FAILONERROR' ),
- array( 'CURLOPT_FILE' ),
- array( 'CURLOPT_FILETIME' ),
- array( 'CURLOPT_FOLLOWLOCATION' ),
- array( 'CURLOPT_FORBID_REUSE' ),
- array( 'CURLOPT_FRESH_CONNECT' ),
- array( 'CURLOPT_FTPAPPEND' ),
- array( 'CURLOPT_FTPLISTONLY' ),
- array( 'CURLOPT_FTPPORT' ),
- array( 'CURLOPT_FTPSSLAUTH' ),
- array( 'CURLOPT_FTP_CREATE_MISSING_DIRS' ),
+ [ 'CURLOPT_CONNECTTIMEOUT' ],
+ [ 'CURLOPT_CONNECTTIMEOUT_MS' ],
+ [ 'CURLOPT_COOKIE' ],
+ [ 'CURLOPT_COOKIEFILE' ],
+ [ 'CURLOPT_COOKIEJAR' ],
+ [ 'CURLOPT_COOKIESESSION' ],
+ [ 'CURLOPT_CRLF' ],
+ [ 'CURLOPT_CUSTOMREQUEST' ],
+ [ 'CURLOPT_DNS_CACHE_TIMEOUT' ],
+ [ 'CURLOPT_DNS_USE_GLOBAL_CACHE' ],
+ [ 'CURLOPT_EGDSOCKET' ],
+ [ 'CURLOPT_ENCODING' ],
+ [ 'CURLOPT_FAILONERROR' ],
+ [ 'CURLOPT_FILE' ],
+ [ 'CURLOPT_FILETIME' ],
+ [ 'CURLOPT_FOLLOWLOCATION' ],
+ [ 'CURLOPT_FORBID_REUSE' ],
+ [ 'CURLOPT_FRESH_CONNECT' ],
+ [ 'CURLOPT_FTPAPPEND' ],
+ [ 'CURLOPT_FTPLISTONLY' ],
+ [ 'CURLOPT_FTPPORT' ],
+ [ 'CURLOPT_FTPSSLAUTH' ],
+ [ 'CURLOPT_FTP_CREATE_MISSING_DIRS' ],
// array( 'CURLOPT_FTP_FILEMETHOD' ), // not present in HHVM 3.3.0-dev
// array( 'CURLOPT_FTP_SKIP_PASV_IP' ), // not present in HHVM 3.3.0-dev
- array( 'CURLOPT_FTP_SSL' ),
- array( 'CURLOPT_FTP_USE_EPRT' ),
- array( 'CURLOPT_FTP_USE_EPSV' ),
- array( 'CURLOPT_HEADER' ),
- array( 'CURLOPT_HEADERFUNCTION' ),
- array( 'CURLOPT_HTTP200ALIASES' ),
- array( 'CURLOPT_HTTPAUTH' ),
- array( 'CURLOPT_HTTPGET' ),
- array( 'CURLOPT_HTTPHEADER' ),
- array( 'CURLOPT_HTTPPROXYTUNNEL' ),
- array( 'CURLOPT_HTTP_VERSION' ),
- array( 'CURLOPT_INFILE' ),
- array( 'CURLOPT_INFILESIZE' ),
- array( 'CURLOPT_INTERFACE' ),
- array( 'CURLOPT_IPRESOLVE' ),
+ [ 'CURLOPT_FTP_SSL' ],
+ [ 'CURLOPT_FTP_USE_EPRT' ],
+ [ 'CURLOPT_FTP_USE_EPSV' ],
+ [ 'CURLOPT_HEADER' ],
+ [ 'CURLOPT_HEADERFUNCTION' ],
+ [ 'CURLOPT_HTTP200ALIASES' ],
+ [ 'CURLOPT_HTTPAUTH' ],
+ [ 'CURLOPT_HTTPGET' ],
+ [ 'CURLOPT_HTTPHEADER' ],
+ [ 'CURLOPT_HTTPPROXYTUNNEL' ],
+ [ 'CURLOPT_HTTP_VERSION' ],
+ [ 'CURLOPT_INFILE' ],
+ [ 'CURLOPT_INFILESIZE' ],
+ [ 'CURLOPT_INTERFACE' ],
+ [ 'CURLOPT_IPRESOLVE' ],
// array( 'CURLOPT_KEYPASSWD' ), // not present in HHVM 3.3.0-dev
- array( 'CURLOPT_KRB4LEVEL' ),
- array( 'CURLOPT_LOW_SPEED_LIMIT' ),
- array( 'CURLOPT_LOW_SPEED_TIME' ),
- array( 'CURLOPT_MAXCONNECTS' ),
- array( 'CURLOPT_MAXREDIRS' ),
+ [ 'CURLOPT_KRB4LEVEL' ],
+ [ 'CURLOPT_LOW_SPEED_LIMIT' ],
+ [ 'CURLOPT_LOW_SPEED_TIME' ],
+ [ 'CURLOPT_MAXCONNECTS' ],
+ [ 'CURLOPT_MAXREDIRS' ],
// array( 'CURLOPT_MAX_RECV_SPEED_LARGE' ), // not present in HHVM 3.3.0-dev
// array( 'CURLOPT_MAX_SEND_SPEED_LARGE' ), // not present in HHVM 3.3.0-dev
- array( 'CURLOPT_NETRC' ),
- array( 'CURLOPT_NOBODY' ),
- array( 'CURLOPT_NOPROGRESS' ),
- array( 'CURLOPT_NOSIGNAL' ),
- array( 'CURLOPT_PORT' ),
- array( 'CURLOPT_POST' ),
- array( 'CURLOPT_POSTFIELDS' ),
- array( 'CURLOPT_POSTQUOTE' ),
- array( 'CURLOPT_POSTREDIR' ),
- array( 'CURLOPT_PRIVATE' ),
- array( 'CURLOPT_PROGRESSFUNCTION' ),
+ [ 'CURLOPT_NETRC' ],
+ [ 'CURLOPT_NOBODY' ],
+ [ 'CURLOPT_NOPROGRESS' ],
+ [ 'CURLOPT_NOSIGNAL' ],
+ [ 'CURLOPT_PORT' ],
+ [ 'CURLOPT_POST' ],
+ [ 'CURLOPT_POSTFIELDS' ],
+ [ 'CURLOPT_POSTQUOTE' ],
+ [ 'CURLOPT_POSTREDIR' ],
+ [ 'CURLOPT_PRIVATE' ],
+ [ 'CURLOPT_PROGRESSFUNCTION' ],
// array( 'CURLOPT_PROTOCOLS' ), // not present in HHVM 3.3.0-dev
- array( 'CURLOPT_PROXY' ),
- array( 'CURLOPT_PROXYAUTH' ),
- array( 'CURLOPT_PROXYPORT' ),
- array( 'CURLOPT_PROXYTYPE' ),
- array( 'CURLOPT_PROXYUSERPWD' ),
- array( 'CURLOPT_PUT' ),
- array( 'CURLOPT_QUOTE' ),
- array( 'CURLOPT_RANDOM_FILE' ),
- array( 'CURLOPT_RANGE' ),
- array( 'CURLOPT_READDATA' ),
- array( 'CURLOPT_READFUNCTION' ),
+ [ 'CURLOPT_PROXY' ],
+ [ 'CURLOPT_PROXYAUTH' ],
+ [ 'CURLOPT_PROXYPORT' ],
+ [ 'CURLOPT_PROXYTYPE' ],
+ [ 'CURLOPT_PROXYUSERPWD' ],
+ [ 'CURLOPT_PUT' ],
+ [ 'CURLOPT_QUOTE' ],
+ [ 'CURLOPT_RANDOM_FILE' ],
+ [ 'CURLOPT_RANGE' ],
+ [ 'CURLOPT_READDATA' ],
+ [ 'CURLOPT_READFUNCTION' ],
// array( 'CURLOPT_REDIR_PROTOCOLS' ), // not present in HHVM 3.3.0-dev
- array( 'CURLOPT_REFERER' ),
- array( 'CURLOPT_RESUME_FROM' ),
- array( 'CURLOPT_RETURNTRANSFER' ),
+ [ 'CURLOPT_REFERER' ],
+ [ 'CURLOPT_RESUME_FROM' ],
+ [ 'CURLOPT_RETURNTRANSFER' ],
// array( 'CURLOPT_SSH_AUTH_TYPES' ), // not present in HHVM 3.3.0-dev
// array( 'CURLOPT_SSH_HOST_PUBLIC_KEY_MD5' ), // not present in HHVM 3.3.0-dev
// array( 'CURLOPT_SSH_PRIVATE_KEYFILE' ), // not present in HHVM 3.3.0-dev
// array( 'CURLOPT_SSH_PUBLIC_KEYFILE' ), // not present in HHVM 3.3.0-dev
- array( 'CURLOPT_SSLCERT' ),
- array( 'CURLOPT_SSLCERTPASSWD' ),
- array( 'CURLOPT_SSLCERTTYPE' ),
- array( 'CURLOPT_SSLENGINE' ),
- array( 'CURLOPT_SSLENGINE_DEFAULT' ),
- array( 'CURLOPT_SSLKEY' ),
- array( 'CURLOPT_SSLKEYPASSWD' ),
- array( 'CURLOPT_SSLKEYTYPE' ),
- array( 'CURLOPT_SSLVERSION' ),
- array( 'CURLOPT_SSL_CIPHER_LIST' ),
- array( 'CURLOPT_SSL_VERIFYHOST' ),
- array( 'CURLOPT_SSL_VERIFYPEER' ),
- array( 'CURLOPT_STDERR' ),
- array( 'CURLOPT_TCP_NODELAY' ),
- array( 'CURLOPT_TIMECONDITION' ),
- array( 'CURLOPT_TIMEOUT' ),
- array( 'CURLOPT_TIMEOUT_MS' ),
- array( 'CURLOPT_TIMEVALUE' ),
- array( 'CURLOPT_TRANSFERTEXT' ),
- array( 'CURLOPT_UNRESTRICTED_AUTH' ),
- array( 'CURLOPT_UPLOAD' ),
- array( 'CURLOPT_URL' ),
- array( 'CURLOPT_USERAGENT' ),
- array( 'CURLOPT_USERPWD' ),
- array( 'CURLOPT_VERBOSE' ),
- array( 'CURLOPT_WRITEFUNCTION' ),
- array( 'CURLOPT_WRITEHEADER' ),
+ [ 'CURLOPT_SSLCERT' ],
+ [ 'CURLOPT_SSLCERTPASSWD' ],
+ [ 'CURLOPT_SSLCERTTYPE' ],
+ [ 'CURLOPT_SSLENGINE' ],
+ [ 'CURLOPT_SSLENGINE_DEFAULT' ],
+ [ 'CURLOPT_SSLKEY' ],
+ [ 'CURLOPT_SSLKEYPASSWD' ],
+ [ 'CURLOPT_SSLKEYTYPE' ],
+ [ 'CURLOPT_SSLVERSION' ],
+ [ 'CURLOPT_SSL_CIPHER_LIST' ],
+ [ 'CURLOPT_SSL_VERIFYHOST' ],
+ [ 'CURLOPT_SSL_VERIFYPEER' ],
+ [ 'CURLOPT_STDERR' ],
+ [ 'CURLOPT_TCP_NODELAY' ],
+ [ 'CURLOPT_TIMECONDITION' ],
+ [ 'CURLOPT_TIMEOUT' ],
+ [ 'CURLOPT_TIMEOUT_MS' ],
+ [ 'CURLOPT_TIMEVALUE' ],
+ [ 'CURLOPT_TRANSFERTEXT' ],
+ [ 'CURLOPT_UNRESTRICTED_AUTH' ],
+ [ 'CURLOPT_UPLOAD' ],
+ [ 'CURLOPT_URL' ],
+ [ 'CURLOPT_USERAGENT' ],
+ [ 'CURLOPT_USERPWD' ],
+ [ 'CURLOPT_VERBOSE' ],
+ [ 'CURLOPT_WRITEFUNCTION' ],
+ [ 'CURLOPT_WRITEHEADER' ],
// array( 'CURLPROTO_ALL' ), // not present in HHVM 3.3.0-dev
// array( 'CURLPROTO_DICT' ), // not present in HHVM 3.3.0-dev
// array( 'CURLPROTO_FILE' ), // not present in HHVM 3.3.0-dev
// array( 'CURLPROTO_SFTP' ), // not present in HHVM 3.3.0-dev
// array( 'CURLPROTO_TELNET' ), // not present in HHVM 3.3.0-dev
// array( 'CURLPROTO_TFTP' ), // not present in HHVM 3.3.0-dev
- array( 'CURLPROXY_HTTP' ),
+ [ 'CURLPROXY_HTTP' ],
// array( 'CURLPROXY_SOCKS4' ), // not present in HHVM 3.3.0-dev
- array( 'CURLPROXY_SOCKS5' ),
+ [ 'CURLPROXY_SOCKS5' ],
// array( 'CURLSSH_AUTH_DEFAULT' ), // not present in HHVM 3.3.0-dev
// array( 'CURLSSH_AUTH_HOST' ), // not present in HHVM 3.3.0-dev
// array( 'CURLSSH_AUTH_KEYBOARD' ), // not present in HHVM 3.3.0-dev
// array( 'CURLSSH_AUTH_NONE' ), // not present in HHVM 3.3.0-dev
// array( 'CURLSSH_AUTH_PASSWORD' ), // not present in HHVM 3.3.0-dev
// array( 'CURLSSH_AUTH_PUBLICKEY' ), // not present in HHVM 3.3.0-dev
- array( 'CURLVERSION_NOW' ),
- array( 'CURL_HTTP_VERSION_1_0' ),
- array( 'CURL_HTTP_VERSION_1_1' ),
- array( 'CURL_HTTP_VERSION_NONE' ),
- array( 'CURL_IPRESOLVE_V4' ),
- array( 'CURL_IPRESOLVE_V6' ),
- array( 'CURL_IPRESOLVE_WHATEVER' ),
- array( 'CURL_NETRC_IGNORED' ),
- array( 'CURL_NETRC_OPTIONAL' ),
- array( 'CURL_NETRC_REQUIRED' ),
- array( 'CURL_TIMECOND_IFMODSINCE' ),
- array( 'CURL_TIMECOND_IFUNMODSINCE' ),
- array( 'CURL_TIMECOND_LASTMOD' ),
- array( 'CURL_VERSION_IPV6' ),
- array( 'CURL_VERSION_KERBEROS4' ),
- array( 'CURL_VERSION_LIBZ' ),
- array( 'CURL_VERSION_SSL' ),
- );
+ [ 'CURLVERSION_NOW' ],
+ [ 'CURL_HTTP_VERSION_1_0' ],
+ [ 'CURL_HTTP_VERSION_1_1' ],
+ [ 'CURL_HTTP_VERSION_NONE' ],
+ [ 'CURL_IPRESOLVE_V4' ],
+ [ 'CURL_IPRESOLVE_V6' ],
+ [ 'CURL_IPRESOLVE_WHATEVER' ],
+ [ 'CURL_NETRC_IGNORED' ],
+ [ 'CURL_NETRC_OPTIONAL' ],
+ [ 'CURL_NETRC_REQUIRED' ],
+ [ 'CURL_TIMECOND_IFMODSINCE' ],
+ [ 'CURL_TIMECOND_IFUNMODSINCE' ],
+ [ 'CURL_TIMECOND_LASTMOD' ],
+ [ 'CURL_VERSION_IPV6' ],
+ [ 'CURL_VERSION_KERBEROS4' ],
+ [ 'CURL_VERSION_LIBZ' ],
+ [ 'CURL_VERSION_SSL' ],
+ ];
}
/**