Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
RE: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connect
Under Control Panel -> Server Administration -> Mail, I setup a smtp connection.
Hostname <office 365 hostname>
Port 587
Use secure: Yes
User <user_email_address>
Password <password>
below error I am getting:
Please let me know how to fix this issue in Liferay7 CE.
Hostname <office 365 hostname>
Port 587
Use secure: Yes
User <user_email_address>
Password <password>
below error I am getting:
Please let me know how to fix this issue in Liferay7 CE.
ERROR [liferay/mail-1][MailEngine:131] null
javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
at sun.security.ssl.InputRecord.handleUnknownRecord(InputRecord.java:710)
at sun.security.ssl.InputRecord.read(InputRecord.java:527)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:973)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1375)
at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:928)
at sun.security.ssl.AppInputStream.read(AppInputStream.java:105)
at com.sun.mail.util.TraceInputStream.read(TraceInputStream.java:97)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:246)
at java.io.BufferedInputStream.read(BufferedInputStream.java:265)
at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:75)
at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:1440)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1260)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:370)
at javax.mail.Service.connect(Service.java:275)
at com.liferay.util.mail.MailEngine._send(MailEngine.java:554)
at com.liferay.util.mail.MailEngine.send(MailEngine.java:354)
at com.liferay.util.mail.MailEngine.send(MailEngine.java:429)
at com.liferay.mail.messaging.MailMessageListener.doMailMessage(MailMessageListener.java:94)
at com.liferay.mail.messaging.MailMessageListener.doReceive(MailMessageListener.java:109)
at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
Any solution for
How to fix in the Liferay7.0 CE.
Regards
Anand Gopalan
javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connect
How to fix in the Liferay7.0 CE.
Regards
Anand Gopalan
I have faced the same issue. when i configured with port 465 works fine but if i use 25 or 587 doesnot works. Could you please help? Please find the error belowjavax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
at sun.security.ssl.InputRecord.handleUnknownRecord(InputRecord.java:710)
at sun.security.ssl.InputRecord.read(InputRecord.java:527)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:983)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1385)
at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:938)
at sun.security.ssl.AppInputStream.read(AppInputStream.java:105)
at com.sun.mail.util.TraceInputStream.read(TraceInputStream.java:97)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:246)
at java.io.BufferedInputStream.read(BufferedInputStream.java:265)
at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:75)
at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:1440)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1260)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:370)
at javax.mail.Service.connect(Service.java:275)
at com.liferay.petra.mail.MailEngine._send(MailEngine.java:588)
at com.liferay.petra.mail.MailEngine.send(MailEngine.java:387)
at com.liferay.petra.mail.MailEngine.send(MailEngine.java:462)
at com.liferay.mail.messaging.MailMessageListener.doMailMessage(MailMessageListener.java:94)
at com.liferay.mail.messaging.MailMessageListener.doReceive(MailMessageListener.java:109)
at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
at sun.security.ssl.InputRecord.handleUnknownRecord(InputRecord.java:710)
at sun.security.ssl.InputRecord.read(InputRecord.java:527)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:983)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1385)
at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:938)
at sun.security.ssl.AppInputStream.read(AppInputStream.java:105)
at com.sun.mail.util.TraceInputStream.read(TraceInputStream.java:97)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:246)
at java.io.BufferedInputStream.read(BufferedInputStream.java:265)
at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:75)
at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:1440)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1260)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:370)
at javax.mail.Service.connect(Service.java:275)
at com.liferay.petra.mail.MailEngine._send(MailEngine.java:588)
at com.liferay.petra.mail.MailEngine.send(MailEngine.java:387)
at com.liferay.petra.mail.MailEngine.send(MailEngine.java:462)
at com.liferay.mail.messaging.MailMessageListener.doMailMessage(MailMessageListener.java:94)
at com.liferay.mail.messaging.MailMessageListener.doReceive(MailMessageListener.java:109)
at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
Vignesh kumar:
My first assumption is that you're connecting to a clear-text SMTP-server but attempt to talk TLS (SSL) with it. At least that's what the message says. Can you confirm or deny this?
I have faced the same issue. when i configured with port 465 works fine but if i use 25 or 587 doesnot works. Could you please help? Please find the error belowjavax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
at sun.security.ssl.InputRecord.handleUnknownRecord(InputRecord.java:710)
I think, Liferay has a bug here. I am not a 100% sure, I was in a hurry when I tested it. But when you set the secure flag, Liferay always uses port 25, not the configured port. I think, it should work if you set the mail settings in portal-ext properties and not through the UI. I also didn't test this, I was in a hurry, so I just installed postfix and used it to route the mails to the correct server with tls.
Christoph Rabel:
In that case I'll add my standard question about the exact version - and if it can still be reproduced on the latest GA of that release.
I think, Liferay has a bug here. I am not a 100% sure, I was in a hurry when I tested it. But when you set the secure flag, Liferay always uses port 25, not the configured port. I think, it should work if you set the mail settings in portal-ext properties and not through the UI. I also didn't test this, I was in a hurry, so I just installed postfix and used it to route the mails to the correct server with tls.
The version I used, was 7.2 CE GA1 . I wanted to add an issue for it, but it fell into a hole ...
I will do a quick test on the weekend, I want to try some other things out too.
I will do a quick test on the weekend, I want to try some other things out too.
I have created LPS-104877
@a g: Please try to set the mail properties through portal-ext instead of through the UI. I think, that should work.
@a g: Please try to set the mail properties through portal-ext instead of through the UI. I think, that should work.
Hello, I am facing exactly the same problem. I saw that reported issue still open and probably it is not fixed yet. I am using 7.3.3-GA4 version of Liferay, I set the properties as suggested in thread but it still without working for me and the "javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?" exception is thrown. There are specific properties for SMTPS (additional to SMTP settings)? Thanks!
Copyright © 2025 Liferay, Inc
• Privacy Policy
Powered by Liferay™