Alice is sending letter to Bob what happens to the letter:
The SMTP commands define the mail transfer or the mail system function requested by the user. SMTP commands are character strings terminated by CR+LF. The commands themselves are alphabetic characters terminated by space if parameters follow and CR+LF otherwise.
MAIL FROM:<userx@y.foo.org>
RCPT TO:<userc@d.bar.org>
EHLO marshall.edu
HELO marshall.edu MAIL FROM: <dementiev@marshall.edu> RCPT TO: <danil@mathcs.emory.edu> RCPT TO: <dementiev@marshall.edu> DATA This is my test e-mail from SMTP server. Dan. . QUITOfficial information about Simple Mail Transfer Protocol can be found in RFC2821.
HELO mathcs.emory.edu MAIL FROM: <danil@mathcs.emory.edu> RCPT TO: <dementiev@marshall.edu> RCPT TO: <_dementiev@marshall.edu> DATA From: someaddr@somewhere.edu To: dementiev@marshall.edu Subject: IST362 MIME encoding MIME-Version: 1.0 Hello, this is a test message for IST362 class sent via direct TCP connection to Marshall SMTP server. Sincerely, Daniel . QUIT
HELO mathcs.emory.edu MAIL FROM: <danil@mathcs.emory.edu> RCPT TO: <dementiev@marshall.edu> RCPT TO: <_dementiev@marshall.edu> DATA From: someaddr@somewhere.edu To: dementiev@marshall.edu Subject: IST362 MIME encoding MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Type: image/gif R0lGODlhDwAPAKL/AP+9AP/GAP/OAP/eCP/vEMDAwAAAAAAAACH5BAEAAAUALAAAAAAPAA8A QANGWKrWvSyIKYa9g5higDPCN2wMZhEoyQBs4FLkJ8/cNIopxHz60rSuh48FcEkoIw7rE3JY GkGn6AYzGTIajumCyvquWI0qAQA7 . QUITUsing MIME we can text and binary data in on letter:
HELO mathcs.emory.edu MAIL FROM: <danil@mathcs.emory.edu> RCPT TO: <dementiev@marshall.edu> RCPT TO: <_dementiev@marshall.edu> DATA From: someaddr@somewhere.edu To: dementiev@marshall.edu Subject: IST362 MIME encoding MIME-Version: 1.0 Content-Type: multipart/mixed; boundary=gc0p4Jq0M2Yt08j34c0p --gc0p4Jq0M2Yt08j34c0p Content-Type: text/plain Hello, this is a test message for IST362 class sent via direct TCP connection to Marshall SMTP server. This message also includes this image: --gc0p4Jq0M2Yt08j34c0p Content-Transfer-Encoding: base64 Content-Type: image/gif R0lGODlhDwAPAKL/AP+9AP/GAP/OAP/eCP/vEMDAwAAAAAAAACH5BAEAAAUALAAAAAAPAA8A QANGWKrWvSyIKYa9g5higDPCN2wMZhEoyQBs4FLkJ8/cNIopxHz60rSuh48FcEkoIw7rE3JY GkGn6AYzGTIajumCyvquWI0qAQA7 --gc0p4Jq0M2Yt08j34c0p Sincerely, Daniel --gc0p4Jq0M2Yt08j34c0p-- . QUIT