Error when try to use anonymous mailrelay Exchange server (No authentication mechansims supported)

0
We run a Mendix App On-premise (so not in the Mendix Cloud). When I try to send an email with the default email module I get the following error: No authentication mechansims supported by both server and client at com.sun.mail.smtp.SMTPTransport.authenticate(SMTPTransport.java:760) at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:673) at javax.mail.Service.connect(Service.java:317) at javax.mail.Service.connect(Service.java:176) at javax.mail.Service.connect(Service.java:125) at javax.mail.Transport.send0(Transport.java:194) at javax.mail.Transport.send(Transport.java:124) at org.apache.commons.mail.Email.sendMimeMessage(Email.java:1391) at org.apache.commons.mail.Email.send(Email.java:1428) at emailtemplate.mail.Sender.send(Sender.java:102) at emailtemplate.mail.EmailModule$1.execute(EmailModule.java:136) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:37) at com.mendix.util.classloading.Runner$1.run(Runner.java:24) at java.security.AccessController.doPrivileged(Native Method) at com.mendix.util.classloading.Runner.runUsingClassLoaderOf(Runner.java:19) at emailtemplate.mail.EmailModule.mail(EmailModule.java:130) at emailtemplate.actions.SendEmail.executeAction(SendEmail.java:133) at emailtemplate.actions.SendEmail.executeAction(SendEmail.java:25) at com.mendix.systemwideinterfaces.core.UserAction.execute(UserAction.java:53) at com.mendix.core.actionmanagement.CoreAction.doCall(CoreAction.java:291) at com.mendix.core.actionmanagement.CoreAction.call(CoreAction.java:276) at com.mendix.core.actionmanagement.ActionManager$1.execute(ActionManager.java:204) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:37) at com.mendix.core.actionmanagement.ActionManager.executeSync(ActionManager.java:199) at com.mendix.core.component.InternalCore.execute(InternalCore.java:263) at com.mendix.modules.microflowengine.actions.actioncall.JavaAction.execute(JavaAction.scala:42) at com.mendix.modules.microflowengine.microflow.impl.MicroflowObject.execute(MicroflowObject.java:49) at com.mendix.modules.microflowengine.microflow.impl.MicroflowImpl.executeAfterBreakingIfNecessary(MicroflowImpl.java:193) at com.mendix.modules.microflowengine.microflow.impl.MicroflowImpl.executeAction(MicroflowImpl.java:148) at com.mendix.systemwideinterfaces.core.UserAction.execute(UserAction.java:53) at com.mendix.core.actionmanagement.CoreAction.doCall(CoreAction.java:291) at com.mendix.core.actionmanagement.CoreAction.call(CoreAction.java:276) at com.mendix.core.actionmanagement.ActionManager$1.execute(ActionManager.java:204) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:37) at com.mendix.core.actionmanagement.ActionManager.executeSync(ActionManager.java:199) at com.mendix.core.component.InternalCore.executeSync(InternalCore.java:235) at com.mendix.modules.microflowengine.actions.SubMicroflowAction.execute(SubMicroflowAction.scala:33) at com.mendix.modules.microflowengine.microflow.impl.MicroflowObject.execute(MicroflowObject.java:49) at com.mendix.modules.microflowengine.microflow.impl.MicroflowImpl.executeAfterBreakingIfNecessary(MicroflowImpl.java:193) at com.mendix.modules.microflowengine.microflow.impl.MicroflowImpl.executeAction(MicroflowImpl.java:148) at com.mendix.systemwideinterfaces.core.UserAction.execute(UserAction.java:53) at com.mendix.core.actionmanagement.CoreAction.doCall(CoreAction.java:291) at com.mendix.core.actionmanagement.CoreAction.call(CoreAction.java:276) at com.mendix.core.actionmanagement.ActionManager$1.execute(ActionManager.java:204) Does somebody know how we can fix this? Thanks!
asked
2 answers
1

Try downgrading the javax.mail jar 1.4.5 to 1.4.1. or just delete the 1.4.5 if you already have a mail.jar in place. That worked for me.

answered
0

This has to do with an incompatibility between your email server and your cloud configuration..

You get this error when the email configuration is not supported by the the email server. For example if you don't configure a username and password, the email server must allow that server to send email without credentials.
But also the other way around, if you have specified a username and password, the email server needs to allow your mendix server to send email. And the email server needs to allow the username and password to be used in authentication.

Anyway the solution is either in changing the email settings, using different form of authentication or changing the security in your email server.

answered