Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Last revision Both sides next revision | ||
mail:test-smtp-auth-telnet [2009-10-15 22:01:26] garrett.plasky |
mail:test-smtp-auth-telnet [2011-07-01 19:06:50] garrett.plasky Approved |
||
---|---|---|---|
Line 4: | Line 4: | ||
The first thing you need to do is get a base64 encoding of your username and password. There are a couple ways to do this, the example below uses Perl: | The first thing you need to do is get a base64 encoding of your username and password. There are a couple ways to do this, the example below uses Perl: | ||
- | <code console># perl -MMIME:: | + | <sxh shell>perl -MMIME:: |
- | # perl -MMIME:: | + | perl -MMIME:: |
What will be returned from each command is a base64 encoding of the username and password; save these as you will need them later. Now connect to the mail server using Telnet: | What will be returned from each command is a base64 encoding of the username and password; save these as you will need them later. Now connect to the mail server using Telnet: | ||
- | <code console># telnet mailserver.com 25</code> | + | <sxh shell>telnet mailserver.com 25</sxh> |
Greet the mail server: | Greet the mail server: | ||
- | <code console>EHLO mailserver.com</ | + | <sxh shell>EHLO mailserver.com</ |
Tell the server you want to authenticate with it: | Tell the server you want to authenticate with it: | ||
- | <code console>AUTH LOGIN</code> | + | <sxh shell>AUTH LOGIN</sxh> |
The server should have returned < | The server should have returned < | ||
- | <q> | + | <sxh plain> |
Now the server should have returned < | Now the server should have returned < | ||
- | <q> | + | <sxh plain> |
Now you should have received a message telling you that you successfully authenticated. If it failed your user/pass may have been wrong or your mailserver is broken. | Now you should have received a message telling you that you successfully authenticated. If it failed your user/pass may have been wrong or your mailserver is broken. | ||
Line 33: | Line 33: | ||
Below is a log of a real successful SMTP AUTH connection over Telnet: | Below is a log of a real successful SMTP AUTH connection over Telnet: | ||
- | <code console> | + | <sxh plain> |
Trying 1.1.1.1... | Trying 1.1.1.1... | ||
Connected to exampledomain.com (1.1.1.1). | Connected to exampledomain.com (1.1.1.1). | ||
Line 53: | Line 53: | ||
bXlwYXNzd29yZA== | bXlwYXNzd29yZA== | ||
- | 235 Authentication succeeded</ | + | 235 Authentication succeeded</ |
{{tag> | {{tag> |