• Resolved williamliang

    (@williamliang)


    We are preparing to use WP Mail SMTP to send emails through Yahoo SMTP, following the instructions to use Yahoo’s app password. However, when testing with a test mail, we encountered the following error message:
    Connection failed. Error #2: stream_socket_client(): Peer certificate CN=dcp2.secserverpros.com' did not match expected CN=smtp.mail.yahoo.com’ [/home/batag/public_html/wp-includes/PHPMailer/SMTP.php line 397]
    The error occurred in the following code: $connection = stream_socket_client( $host . ‘:’ . $port, $errno, $errstr, $timeout, STREAM_CLIENT_CONNECT, $socket_context );
    Perhaps this is due to the website and email server being hosted by different web hosting providers. How can we resolve this issue?
    Thank you!

Viewing 1 replies (of 1 total)
  • Hi @williamliang,

    Thanks for reaching out.

    Please kindly know, that the error message you shared is server-related. It indicates certificate verification failure on your server. Please, check this troubleshooting guide for more information:?https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting#certificate-verification-failure.

    When you get a chance, could you please contact your hosting support and ask them to look into the issue? You can provide them with the same error message you shared. They should be able to resolve the issue.

    I apologize that we can’t provide an exact solution to this, but I hope the suggestion above helps point you in the right direction.

    Thanks ??

Viewing 1 replies (of 1 total)
  • The topic ‘Peer certificate CN did not match’ is closed to new replies.