SMTPSend 501 Syntactically invalid HELO argument(s)

Hi all

Servoy 223/Windows system hosted on my Server.

Servoy sendMail working fine for client until end last week when started getting SMTPSend 501 error messages every time they tried to send an email - full Server Log errror below.

In tests I can send emails using my Email accounts through the same system which pointed to a problem with their Email SMTP Server.

However, after further testing have discovered that they CAN send emails on their Email Accounts using the same system but hosted on a different Server :?

Have setup new Email accounts and rebooted my Server but still get same error on every message.

MS Knowledgebase #241892 has following for the error message - but it doesn’t explain why my clients SMTP Server will send from one Servoy SErver but not from another:

SYMPTOMS
When sending e-mail to a third-party SMTP server or through a firewall, a non-delivery report (NDR) similar to the following may be generated:
Subject: Notification: Outbound Mail Failure - A protocol error occurred.

A mail message was not sent due to a protocol error.

501 syntactically invalid HELO argument(s)

The message that caused this notification was:
CAUSE
This error is generated by a third-party SMTP server or firewall.

When the Microsoft Exchange Internet Mail Service establishes a connection to a remote host, the Internet Mail Service initiates the SMTP conversation with “EHLO domainname.com”. If an error is returned, the Internet Mail Service falls back to “HELO domainname.com”. If the HELO command returns an error, an NDR is generated containing the error.

Any suggestions would be welcomed.

Graham Greensall
Worxinfo Ltd

2006-02-20 11:20 : SMTPSend 501 Syntactically invalid HELO argument(s)

2006-02-20 11:20 : javax.mail.MessagingException: 501 Syntactically invalid HELO argument(s)

at com.sun.mail.smtp.SMTPTransport.issueCommand(SMTPTransport.java:1250)
at com.sun.mail.smtp.SMTPTransport.helo(SMTPTransport.java:772)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:316)
at javax.mail.Service.connect(Service.java:255)
at javax.mail.Service.connect(Service.java:134)
at javax.mail.Service.connect(Service.java:86)
at com.sun.mail.smtp.SMTPTransport.connect(SMTPTransport.java:144)
at javax.mail.Transport.send0(Transport.java:150)
at javax.mail.Transport.send(Transport.java:80)
at com.servoy.r2.plugins.mail.MailServer.sendMail(MailServer.java:226)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
at sun.rmi.transport.Transport$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

Hi Graham,

Those Servoy servers all send to the same SMTP server?

Anyway, about the HELO command. There is a standard format for this command but loads (and I mean LOADS) of servers/clients are not fully compliant with this standard (especially spam apps). You can setup a mailserver to require such a correct HELO command from any server/client or not but that could mean that you don’t receive a lot of legitimate mail.
Therefore most mail servers don’t have this strictness because of the for-mentioned non-compliance.

So if something worked before and suddenly stopped working I suggest you ask if they changed the settings of the mail server (probably to reduce spamming).

Hope this helps.

Well Graham, I apologize on forehand because I can’t help you much either.

What I did find though is that it MAY have to do with the servers your are mailing through.

Another reason can be the way the plugin properties are coded but I don’t think that’s the reason because it works for most of us…

Thanks for the fast responses.

We are quizzing the Email Server techies on anything that was changed last Friday and also following up the suggestion that maybe the Client’s email address has been caught up in an anti-spam net. My feeling is that it is ‘external’ as the Servoy mail plugin has been very solid for almost a yesr now.

Will report back.

Graham Greensall
Worxinfo Ltd

Graham, Did you find out more about this?

I’ve found that a method using sendMail that was previously working has now stopped working. I can’t say for sure when it happened because I don’t use it frequently, but it might’ve coincided with the upgrade to 3.1.3.

The outbound server is mine and I can still send with OL/OLE directly using the same smtp settings Servoy is using (in Prefs). This is in Developer.

plugins.mail.getLastSendMailException() returns ‘SMTP’

The Servoy Admin log says
javax.mail.NoSuchProviderException: smtp

but I’ve double checked the smtp settings are the same as those in OL, and I’m using the same FROM: address in both (on the same domain)
I’m puzzled. Any helpful thoughts would be appreciated.

Hi Tony

Sorry, I didn’t get back on this one.

In fact we never truly resolved it, other than a suspicion that somehow my Clients email address and the IP of the Test Server had been ‘blacklisted’, since my Emails could still be sent from the Server, and the Clients emails have worked fine on two other Servers.

Once the Email solution had been moved to another Server it has worked perfectly through all the 2.x and 3.x varieties of Servoy.

Regards

Graham