EHLO |
Announce client identity and request extensions. |
Must be repeated after STARTTLS; fallback to HELO for legacy peers. |
500/502 on legacy server, 501 for malformed argument. |
STARTTLS |
Upgrade plaintext channel to TLS. |
Any buffered pipelined commands are invalid once TLS starts. |
454 TLS not available, certificate name mismatch, chain failure. |
AUTH PLAIN/LOGIN/XOAUTH2 |
Authenticate submission client. |
Policy often requires TLS first; mechanisms differ across providers. |
535 Authentication failed, 534 policy requires TLS. |
MAIL FROM:<...> |
Start transaction with reverse-path and sender params. |
Can carry SIZE, BODY=8BITMIME, SMTPUTF8. |
552 message size exceeds fixed limit, 550 sender rejected. |
RCPT TO:<...> |
Add recipient to envelope. |
Different responses per recipient; keep accepted set and continue. |
450/451 temporary recipient issue, 550/551/553 permanent reject. |
DATA |
Send RFC 5322 message payload. |
Dot-stuffing required; server returns final accept/reject only after terminator. |
554 content rejected, 451 processing error. |
BDAT |
Chunked body transfer with CHUNKING extension. |
No dot-stuffing semantics; chunk sizes must be exact and final chunk flagged. |
500/503 bad chunk sequence, parse mismatch. |
NOOP / RSET / QUIT |
Liveness check, transaction reset, graceful session close. |
RSET clears envelope state but keeps session and auth context. |
Timeout disconnect if peer hung; 221 expected on QUIT. |