Postfix + PHPMailer, works on CentOS 6.5, not on 7.

General support questions
Post Reply
sblantipodi
Posts: 252
Joined: 2009/07/10 09:43:13
Contact:

Postfix + PHPMailer, works on CentOS 6.5, not on 7.

Post by sblantipodi » 2014/07/13 17:57:58

Hi,
I'm switching my current config from CentOS 6.5 to CentOS 7.

On my current configuration I have postfix, dovecot and I use PHPMailer to send mail from some PHP script.
All this, works awesome on CentOS 6.5.

Installing the same things on CentOS 7 works partially.
I can send email from phpmail, I can send mail using client like thunderbird, I can use roundcubemail without problem but on CentOS 7
PHPMailer does not send emails.

When PHPMailer try to send email my maillog say:
Jul 13 19:15:07 nets postfix/smtpd[1364]: connect from MYDOMAIN[MYIP]
Jul 13 19:15:07 nets postfix/smtpd[1364]: SSL_accept error from MYDOMAIN[MYIP]: 0
Jul 13 19:15:07 nets postfix/smtpd[1364]: warning: TLS library problem: 1364:error:14094418:SSL routines:SSL3_READ_BYTES:tlsv1 alert unknown ca:s3_pkt.c:1257:SSL alert number 48:
Jul 13 19:15:07 nets postfix/smtpd[1364]: lost connection after CONNECT from MYDOMAIN[MYIP]
Jul 13 19:15:07 nets postfix/smtpd[1364]: disconnect from MYDOMAIN[MYIP]
Any idea on how to solve this problem?
Thanks!

sblantipodi
Posts: 252
Joined: 2009/07/10 09:43:13
Contact:

Re: Postfix + PHPMailer, works on CentOS 6.5, not on 7.

Post by sblantipodi » 2014/07/13 18:10:07

I think that the problem is related to the fact that my certificates are not signed by an authority but they are self signed.
Is there a way to avoid this problem without submitting my certificate to an authority?

sblantipodi
Posts: 252
Joined: 2009/07/10 09:43:13
Contact:

Re: Postfix + PHPMailer, works on CentOS 6.5, not on 7.

Post by sblantipodi » 2014/07/14 12:43:42

I add some info trying to solve this problem and trying to get help.
the function that create problem is:

if(!stream_socket_enable_crypto($this->smtp_conn, true, STREAM_CRYPTO_METHOD_TLS_CLIENT)) {
return false;
}

Post Reply