I'm using wp_remote_post
to post some info to a secure connection like this
$url = 'https://example.com/path/file.json';
wp_remote_post($url, array(
'sslverify' => false,
'timeout' => 60,
'body' => $body,
));
But I get an error:
SSL: CA certificate set, but certificate verification is disabled
I though sslverify
set to false
should prevent that?
If I set sslverify => true
it works but may cause problems on other servers
Here's the complete wp_error object:
WP_Error Object
(
[errors:WP_Error:private] => Array
(
[http_request_failed] => Array
(
[0] => SSL: CA certificate set, but certificate verification is disabled
)
)
[error_data:WP_Error:private] => Array
(
)
)
Maybe it's related but on Apache 2.2 it works while on Apache 2.4 it doesn't
Looks like your Apache 2.2 and 2.4 configurations are different. On 2.4 you probably have SSLVerifyClient set to required which would cause it to act like what you are describing. You'd need to set it to none: http://httpd.apache.org/docs/current/mod/mod_ssl.html#SSLVerifyClient
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With