Email Failure


#1

OS: Win7
KS: 5.3.0

I have tried to setup email for GMail, Outlook.com and my company’s email server. All fail with essentially the same message:

“Unable to send email to the following server: mail.somewhere.com:25 …”

I have tried every setting, followed both sets of instructions in the documentation (the GMail advice is wrong by the way) and still it does not work. For GMail I allowed less secure apps.

I have read a bunch of messages posted here, including this one:

https://forum.katalon.com/discussion/1925/email-configuration-issue

Which suggests downloading a tool from Github which I did. It says to compile it first – the the javac command is not recognized in Windows.

I’m REALLY enjoying working with Katalon Studio but if email is not working, that’s a showstopper for me.

Please help! Thanks!


#2

More info…

I had noticed that the error message always displays the port as 25 and assumed that was just a bad error message. But working the the .log file, all the EmailExceptions say the same thing, also. How do I convince KS to use the correct port?

Here’s a GMail example:

org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.gmail.com:25

at org.apache.commons.mail.Email.sendMimeMessage(Email.java:1421)  
at org.apache.commons.mail.Email.send(Email.java:1448)  
at com.kms.katalon.execution.util.MailUtil.sendTestMail(MailUtil.java:71)  
at com.kms.katalon.composer.execution.settings.MailSettingsPage$11.run(MailSettingsPage.java:379)  
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:119)  

Caused by: javax.mail.MessagingException: Could not connect to SMTP host: smtp.gmail.com, port: 25;


#3

I’m having the same issue. Additionally, I checked my address (and port) through Telnet and was able to correct without issue.

Telnet command:
smtp.office365.com 587

  • Connects just fine, not being stopped by the company firewall.

Katalon Settings:

Have tried with all three protocols: NONE, SSL, and TLS. TLS is the one that should be used. But, none of the three (3) work. I get the same error message each time, with one exception (the port number):

image

The default port of “25” is forced (despite using 587), unless I change the Protocol to SSL. The test email still errors out, BUT, the port changes to “587” in the error msg.


#4

Turns out that Office 365 has a problem with Katalon Studio that we were unable to resolve. So, in the interest of time constraints, the answer was to set up a relay from our domain to Office 365, point Katalon to that relay address which is governed by our firewall, and then white list the internal IP addresses that have Katalon Studio installed. This enabled the functionality.


#5

@vtadmin - Reworded a little, that would make a great Tips & Tricks post.


#6

@huynguyen Please confirm if this is an issue.