- Posts: 8
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
SMTP configuration without SSL / TLS is using TLS
- accsa
- Topic Author
- Offline
- New Member
In the encoding SMTP options I selected the "disabled" option (I use the spanish version so the name may be different).
The connection to the mailserver is fine and I'm able see the communication logs, but I can't send mails, I'm having this error:
SMTP connect() failed. github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
2016-10-06 18:32:30
SERVER -> CLIENT: 220 Cas1 Microsoft ESMTP MAIL Service ready at Thu, 6 Oct 2016 15:32:30 -0300 2016-10-06 18:32:30
CLIENT -> SERVER: EHLO feedback.arnaldocastro.com.uy 2016-10-06 18:32:30
SERVER -> CLIENT:
250-Cas1 Hello [10.100.100.30]
250-SIZE 36700160
250-PIPELINING
250-DSN
250-ENHANCEDSTATUSCODES
250-STARTTLS
250-X-ANONYMOUSTLS
250-AUTH NTLM LOGIN
250-X-EXPS GSSAPI NTLM
250-8BITMIME
250-BINARYMIME
250-CHUNKING
250 XRDST 2016-10-06 18:32:30
CLIENT -> SERVER: STARTTLS 2016-10-06 18:32:30
SERVER -> CLIENT: 220 2.0.0 SMTP server ready 2016-10-06 18:32:30 SMTP Error: Could not connect to SMTP host. 2016-10-06 18:32:30 CLIENT -> SERVER: QUIT 2016-10-06 18:32:30
SERVER -> CLIENT: 2016-10-06 18:32:30
SMTP ERROR: QUIT command failed: 2016-10-06 18:32:30
SMTP connect() failed. github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
As you can see I've remarked the line which I believe is the problem, the client (limesurvey) is starting the communication with TLS despite I have not selected SMTP TLS encode option.
Any ideas of how can I resolve this problem?, thanks in advance.
- jelo
- Offline
- Platinum Member
- Posts: 5033
- Thank you received: 1257
This looks like an issue in the PHPMailer library.accsa wrote: As you can see I've remarked the line which I believe is the problem, the client (limesurvey) is starting the communication with TLS despite I have not selected SMTP TLS encode option.
What version/build of LimeSurvey is used? What version of PHP is used?Opportunistic TLS
PHPMailer 5.2.10 introduced opportunistic TLS - if it sees that the server is advertising TLS encryption (after you have connected to the server), it enables encryption automatically, even if you have not set SMTPSecure. This might cause issues if the server is advertising TLS with an invalid certificate, but you can turn it off with $mail->SMTPAutoTLS = false;.
I wonder why you want to deactivate TLS. The used mailserver supports TLS encryption as my tests showed.
You might need to change the hostname or the port. Normally I would go for TLS and 465. StartTLS is a bit wacky, since it can be tricked into not encrypting at all. StartTLS is on Port 25.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
- accsa
- Topic Author
- Offline
- New Member
- Posts: 8
- Thank you received: 0
Now I'm using the last version of Limesurvey 2.53+161004. I was using Versión 2.06+ with the same configuration and it was working OK.
I have installed a new server and I updated the version, so I don't know if is something with the new server or with the new version. At the moment I still having the old server (Windows 2012) with version 2.06 working OK just for test, and the new server (CentOS 7).
The PHP version on my new server is PHP 5.6.26 (cli) (built: Sep 17 2016 09:53:52)
I've tried TLS and SSL configurations with port 25, 587 and 465 with no success, now I don't use TLS in order to simplify things avoiding to have certificates problems, on the other hand the communication is internal, so I don't need to encrypt it.
I agree with you, it sounds like a PHPMailer or similar problem but I'm stuck.
- jelo
- Offline
- Platinum Member
- Posts: 5033
- Thank you received: 1257
blog.zwiegnet.com/linux-server/disable-selinux-centos-7/
Since PHP 5.6 certificates get checked on names. If the mailservers hostname and certificate aren't matching it can be the issue too.
You can deactivate this behavior in PHP. Not a good idea.
php.net/manual/en/migration56.openssl.php
Sometimes the CentOS CA bundle is not having all CAs. So even a valid certificate isn't validated by CentOS OpenSSL correctly.
I still don't get how you use the mailserver internally. You state "communication is internal". Is the mailserver under you control too?
How can you be sure with the routing when using the hostname, which I can reach too?
I currently cannot recommend a way to config the phpmailer in the LimeSurvey installation.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
- jelo
- Offline
- Platinum Member
- Posts: 5033
- Thank you received: 1257
Answer from LouisGac was, that i should read the code. So, feel free to open a bugreport or read the code.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
- jelo
- Offline
- Platinum Member
- Posts: 5033
- Thank you received: 1257
Next release of LS will have "Opportunistic TLS" disabled. So you might just wait for the next release and just update to fix your issue.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
- accsa
- Topic Author
- Offline
- New Member
- Posts: 8
- Thank you received: 0
I will post the results as soon as I can.
- jelo
- Offline
- Platinum Member
- Posts: 5033
- Thank you received: 1257
Perhaps you first try the update.accsa wrote: OK, thanks for your help, I'm trying a couple of things.
LimeSurvey 2.54 build 161007
-Fixed issue: TLS handshake used even if no TLS is set in SMTP settings
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
- ibro123
- Offline
- New Member
- Posts: 2
- Thank you received: 0
accsa wrote: I have configured the SMTP options using my mail server.
In the encoding SMTP options I selected the "disabled" option (I use the spanish version so the name may be different).
The connection to the mailserver is fine and I'm able see the communication logs, but I can't send mails, I'm having this error:
SMTP connect() failed. github.com/PHPMailer/PHPMailer/wiki/TroubleshootingTrazado de la salida del SMTP: 2016-10-06 18:32:30
SERVER -> CLIENT: 220 Cas1 Microsoft ESMTP MAIL Service ready at Thu, 6 Oct 2016 15:32:30 -0300 2016-10-06 18:32:30
CLIENT -> SERVER: EHLO feedback.arnaldocastro.com.uy 2016-10-06 18:32:30
SERVER -> CLIENT:
250-Cas1 Hello [10.100.100.30]
250-SIZE 36700160
250-PIPELINING
250-DSN
250-ENHANCEDSTATUSCODES
250-STARTTLS
250-X-ANONYMOUSTLS
250-AUTH NTLM LOGIN
250-X-EXPS GSSAPI NTLM
250-8BITMIME
250-BINARYMIME
250-CHUNKING
250 XRDST 2016-10-06 18:32:30
CLIENT -> SERVER: STARTTLS 2016-10-06 18:32:30
SERVER -> CLIENT: 220 2.0.0 SMTP server ready 2016-10-06 18:32:30 SMTP Error: Could not connect to SMTP host. 2016-10-06 18:32:30 CLIENT -> SERVER: QUIT 2016-10-06 18:32:30
SERVER -> CLIENT: 2016-10-06 18:32:30
SMTP ERROR: QUIT command failed: 2016-10-06 18:32:30
SMTP connect() failed. github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
As you can see I've remarked the line which I believe is the problem, the client (limesurvey) is starting the communication with TLS despite I have not selected SMTP TLS encode option.
Any ideas of how can I resolve this problem?, thanks in advance.
- ibro123
- Offline
- New Member
- Posts: 2
- Thank you received: 0
I use version 2.53+161004.
Unable to send with smtp, crone, of any kind i try...
- accsa
- Topic Author
- Offline
- New Member
- Posts: 8
- Thank you received: 0
To be honest I didn't expect an update so quick, that why I'd said I was going to test a couple of things.
It's good to have this formu, thanks again for your help.
- accsa
- Topic Author
- Offline
- New Member
- Posts: 8
- Thank you received: 0
Do you have any log of the error? what are you using to send mails, your own mail server or an account from other parties?