Fix authentication issue on mail server with Telnet

Q I am trying to fix an authentication issue with my mail server, and the only way I have been to test it is by setting it up in Evolution. Is there any way that I could try without having to set an account in Evolution?

A One of the best ways to test a range of different services, including SMPTP SAUTH, is to use Telnet. Now, I would never recommend normal Telnet to log in to a machine, but for testing some services it is invaluable. To trouble shoot your problem, what we want to do is to connect to the mail server on port 25 and authenticate using the encoded base 64 (read about it at First, a few helpful decoded strings, encoded with

'VXNlcm5hbWU6' decodes to
'UGFzc3dvcmQ6' decodes to
'dGVzdF9seGZAcmV6ZC5jby51aw==' decodes to ''
'Zm9vYmFy' decodes to 'foobar'

The following lines are the dialogue to test the server is authenticating. We use base 64 encoding for some of the strings, which are detailed above. First, Telnet to the mail server domain/IP address (ie or on port 25:

telnet 25

The server will answer with an SMTP banner:

Connected to
Escape character is '^]'.

Issue the EHLO command:


Next, the server tells us what it supports. This can very from mail server to mail server. Hello other. [],
pleased to meet you
250 HELP

Authenticate to the mail server with


It sends out the username prompt:

334 VXNlcm5hbWU6

Now we send the name of a user that we are going to authenticate with, eg


Next it asks for the password:

334 UGFzc3dvcmQ6

And we supply it:


And finally it says yes, so we know that authentication is working:

235 2.0.0 OK Authenticated

If we get the following, we know that there is an issue with the authentication in some way:

535 5.7.0 authentication failed

This is sufficient to test authentication; if we wanted to test sending mail we could continue the SMTP dialogue.

Follow us on or Twitter

Username:   Password: