SMTP Commands: Difference between revisions
From KlavoWiki
Jump to navigationJump to search
No edit summary |
No edit summary |
||
Line 8: | Line 8: | ||
Once a session has been established you can proceed with the following commands. | Once a session has been established you can proceed with the following commands. | ||
<pre> | <pre> | ||
helo | helo mydomain.com | ||
mail from: <from address> | mail from: <from address> | ||
rcpt to: <to address> | rcpt to: <to address> |
Revision as of 01:33, 6 July 2016
If you would like to create an email directly from an SMTP server you can use the commands as follows. The method below is mainly used for testing the relaying restrictions of the SMTP server in question. You need to do the commands in the order as specified. The only exception is the subject line.
You need to first establish a session with the SMTP server. Typically this is done with telnet.
telnet <server address> 25
Once a session has been established you can proceed with the following commands.
helo mydomain.com mail from: <from address> rcpt to: <to address> data subject: <subject> <message goes here>
To end the message and send the email enter the below sequence without any spaces.
enter . enter