Test SMTP TLS with OpenSSL with Auth

On a linux box type these two commands

The command will return with the username and password in base64 format.

So now you need to telnet with OpenSSL to the mailserver:

After you have connection, you need to present yourself

Some mailserver, do check if the ehlo is you corrert PTR record, for the IP address you are coming from, but most do not.

The mail server will return with:
250 mailserver.kennethdalbjerg.dk Hello dell1 []

You will now try to authenticated you self, if you don’t need to AUTH, please go to last code example in this blog.

And the mailserver will return with:

Here you type you username in base64 format

And the mailserver will return with:

Please now type you password in base64 format

The server should now return with:
235 2.7.0 Authentication successful

After this you type normal email request to send an email
Example: (You should not type the line starting with a >, it are what the mailserver return to you.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *