A better solution (avoid patch WP core).
add these lines on $wpms_options inside wp_mail_smtp.php
'ssl' => array(
'verify_peer' => false,
'verify_peer_name' => false
)
The result should be
global $wpms_options; // This is horrible, should be cleaned up at some point
$wpms_options = array (
'mail_from' => '',
'mail_from_name' => '',
'mailer' => 'smtp',
'mail_set_return_path' => 'false',
'smtp_host' => 'localhost',
'smtp_port' => '25',
'smtp_ssl' => 'none',
'smtp_auth' => false,
'smtp_user' => '',
'smtp_pass' => '',
'ssl' => array(
'verify_peer' => false,
'verify_peer_name' => false
)
);
HTH
Lota