Email not sending Lucee 5.3.5.92

Emails fail to send on version Lucee 5.3.5.92. The server will not even verify on this version. Here is the error message.

Verification of mail server [outbound.mailhop.org] failed:
can’t connect to mail server

I downgraded to version 5.3.4.80 and the same mail server verifies. But when trying to send a test email from the Web - Services - Mail it fails because there is no FROM address. There was not a from address box in the UI just a blank box which I assumed to be the TO address box.

Sounds like two different bugs to me.

I tried this on a on code version of the SMTP server and one defined on the system. It made no difference. But it might be noteworthy that I used the OTHER mail server connection.

Windows 10 Pro
OpenJDK 11.0.1
Jetty 9.4.26
Lucee: 5.3.5.92 & 5.3.4.80

Error message from the 5.3.4.80 version. Neither version sends anything out the wire. I first started looking for packets via Wireshark. The process never gets that far.

smtp
lucee.runtime.exp.NativeException: smtp
at javax.mail.Session.getService(Session.java:806)
at javax.mail.Session.getTransport(Session.java:728)
at javax.mail.Session.getTransport(Session.java:668)
at javax.mail.Session.getTransport(Session.java:648)
at lucee.runtime.net.smtp.SMTPConnectionPool$SessionAndTransport.(SMTPConnectionPool.java:165)
at lucee.runtime.net.smtp.SMTPConnectionPool.getSessionAndTransport(SMTPConnectionPool.java:56)
at lucee.runtime.net.smtp.SMTPClient.createMimeMessage(SMTPClient.java:446)
at lucee.runtime.net.smtp.SMTPClient._send(SMTPClient.java:814)
at lucee.runtime.spooler.mail.MailSpoolerTask.execute(MailSpoolerTask.java:115)
at lucee.runtime.spooler.SpoolerTaskSupport._execute(SpoolerTaskSupport.java:107)
at lucee.runtime.spooler.SpoolerEngineImpl.execute(SpoolerEngineImpl.java:590)
at lucee.runtime.spooler.SpoolerEngineImpl$TaskThread.run(SpoolerEngineImpl.java:528)
Caused by: lucee.runtime.net.mail.MailException: smtp
… 12 more

Turns out it was the OpenJDK 11.0.1 version at least for 5.3.4.80. Updated to OpenJDK 11.0.6_10 and it started working.

Lucee 5.3.5.92 fails with the error below. The test has the same bug in both version. I will file a report on that one.

smtp
lucee.runtime.exp.NativeException: smtp
at javax.mail.Session.getService(Session.java:806)
at javax.mail.Session.getTransport(Session.java:728)
at javax.mail.Session.getTransport(Session.java:668)
at javax.mail.Session.getTransport(Session.java:648)
at lucee.runtime.net.smtp.SMTPConnectionPool$SessionAndTransport.(SMTPConnectionPool.java:165)
at lucee.runtime.net.smtp.SMTPConnectionPool.getSessionAndTransport(SMTPConnectionPool.java:56)
at lucee.runtime.net.smtp.SMTPClient.createMimeMessage(SMTPClient.java:445)
at lucee.runtime.net.smtp.SMTPClient._send(SMTPClient.java:813)
at lucee.runtime.spooler.mail.MailSpoolerTask.execute(MailSpoolerTask.java:115)
at lucee.runtime.spooler.SpoolerTaskSupport._execute(SpoolerTaskSupport.java:107)
at lucee.runtime.spooler.SpoolerEngineImpl.execute(SpoolerEngineImpl.java:590)
at lucee.runtime.spooler.SpoolerEngineImpl$TaskThread.run(SpoolerEngineImpl.java:528)
Caused by: lucee.runtime.net.mail.MailException: smtp
… 12 more

alas, this is also know problem…

https://luceeserver.atlassian.net/browse/LDEV-2561
https://luceeserver.atlassian.net/browse/LDEV-1720

if you can help the lucee dev’s reproduce the problem, that would be great

Thanks for the info. I will read over the issues and see if I can debug why soon. I must have working email so it is a showstopper.

Same issue here on 5.3.5.92 after upgrading from 5.3.4.80
I’ll try to do more debugging next week.

Issue persits in Lucee 5.3.6.53-RC

I looked at the code. The smtp errors are a generic error when Java tries to connect. The problem is taking place in the Java JRE code. You might want to try an SMTP connection test website. My first guess is something with SSL certificate going wrong. Or is anyone trying the default port 25 and getting the error?

The -Dmail.debug=true can be added to setenv. It is supposed to work for Windows service or linux. It does not work for Lucee express in Windows.

maybe the first step is to upgrade to the latest 1.65 version of java mail?

https://luceeserver.atlassian.net/browse/LDEV-2618

https://eclipse-ee4j.github.io/mail/docs/CHANGES.txt

That is possible also.
I am looking at code when I have time. Right now it doesn’t seem “Other” mail servers in Admin can verify if SSL or TLS is used. Trying code to fix that. Also seeing if it is possible to add more code to Verify for more debug messages in case of problem.

1 Like

I think it’s a class loader type problem, the change logs include some fixes for such problems

We’re also having this same issue, but we’re using OpenJDK11.0.6_10 . Is there any fix in the works? We started experiencing the error after upgrading to lucee 5.3.5.92 from 5.3.5.80. Restoring Lucee 5.3.5.80 resolved the issue, so we’re stuck there until it’s resolved.

Some of the other people here have looked in to it more. I have not. It will become a show shopper for me in a few months.

If you read all of the comments here and on the tickets it appears to have something to do with JavaMail. The version being used is old which appears to be the case with a lot of the included jar files.

Keeping up on jar releases would be a full time job.

I have the issue when I try to verify asimple NON-SSL, NON-TLS server on port 25 without username/passwort. Just an internal, open relay fails.

So it has nothing to do with SSL certificates.

there’s been a fix for verify in the admin in the latest 5.3.7 snapshots, can you could try it out?

Please update [LDEV-2873] - Lucee with your results.

I have also raised the broader issue with sending email with @micstriit and it’s on his radar, the java mail in Lucee is rather old (1.4.7), upgrading to the latest version 1.6.5 [LDEV-2618] - Lucee is flagged for the next sprint

2 Likes

I installed latest Lucee 5.3.7.34-RC and the problem still persits.

Which mail server are you using?

Cisco Ironport. Configured to allow mail-relay for that servers IP.
I’ve got two instances of Lucee, on that machine, and the other one works well, while the Lucee update breaks the mail-connection.
I’m running Adopt JDK 8 on Windows.

The behavior with Microsoft SMTP configured for anonymous mail-relay.
Works on Lucee 5.3.4.80 fails on Lucee 5.3.7.34-RC