wire / wire-format / smtp-protocol
SMTP is the protocol for sending email. Commands: HELO/EHLO, MAIL FROM, RCPT TO, DATA, RSET, NOOP, QUIT, VRFY, EXPN. Responses: 3-digit codes (220 service ready, 250 OK, 354 start mail input, 421 service not available, 450 mailbox unavailable, 550 mailbox not found). ESMTP extensions: STARTTLS (upgrade to TLS), AUTH (authentication), SIZE (message size limit), PIPELINING (batch commands), 8BITMIME, SMTPUTF8.
aka: SMTP (Simple Mail Transfer Protocol)
spec: RFC 5321
SMTP is the protocol for sending email. Commands: HELO/EHLO, MAIL FROM, RCPT TO, DATA, RSET, NOOP, QUIT, VRFY, EXPN. Responses: 3-digit codes (220 service ready, 250 OK, 354 start mail input, 421 service not available, 450 mailbox unavailable, 550 mailbox not found). ESMTP extensions: STARTTLS (upgrade to TLS), AUTH (authentication), SIZE (message size limit), PIPELINING (batch commands), 8BITMIME, SMTPUTF8.
| field | size | meaning |
|---|---|---|
| HELO/EHLO | command | Identify the client. EHLO enables ESMTP extensions. |
| MAIL FROM | command | Specify sender address. MAIL FROM:<[email protected]>. |
| RCPT TO | command | Specify recipient. RCPT TO:<[email protected]>. Can be repeated. |
| DATA | command | Start message body. Server responds 354. Client sends headers + blank line + body, terminated by \.\r\n. |
| STARTTLS | EHLO extension | Upgrade connection to TLS. Server responds 220. Client sends TLS ClientHello. |
| AUTH | EHLO extension | Authentication: AUTH PLAIN, AUTH LOGIN, AUTH XOAUTH2. Client sends credentials. |
| Response codes | 3 digits | 220 service ready, 250 OK, 354 start mail input, 421 service not available, 450 mailbox unavailable, 550 mailbox not found, 552 exceeded storage, 554 transaction failed. |
example:
00 00
SMTP (placeholder)
agent: curl -H 'accept: application/json' wire.phall.io/wire-format/smtp-protocol
or /wire-format/smtp-protocol.json