* Don't set SO_KEEPALIVE on the socket. This is most likely useless
in our case since the TCP keepalive time is usually much higher than
the IMAP timeout.
+ * Set X.509 certificate purpose to 'SSL Server' for SSL_verify=YES.
-- Guilhem Moulin <guilhem@guilhem.org> Wed, 09 Sep 2015 00:44:35 +0200
or $self->_ssl_error("Can't load verify locations");
}
Net::SSLeay::CTX_set_verify($ctx, Net::SSLeay::VERIFY_PEER());
+ Net::SSLeay::CTX_set_purpose($ctx, Net::SSLeay::X509_PURPOSE_SSL_SERVER())
+ or $self->_ssl_error("Can't set purpose");
}
else {
Net::SSLeay::CTX_set_verify($ctx, Net::SSLeay::VERIFY_NONE());