Skip to main content
Replies follow SMTP convention: the first digit decides how to react.
  • 2xx means success
  • 4xx means temporary failure; the client may retry later
  • 5xx means permanent failure; do not retry without changing the message
Most replies carry an RFC 5248 enhanced status code (class.subject.detail) after the three-digit code; some carry only the code and a reason. Branch retry logic on the first digit, never on the enhanced code alone.

Connection and authentication

A source IP over the per-IP connection limits gets no reply at all: the connection closes before the greeting.

Envelope

Message content and policy

These replies arrive after DATA, when the message is evaluated.

Reading a reply on the wire

A mail library usually reports a rejection as an exception, with the server’s own text a layer or two down. swaks prints the session verbatim, so the reply you are looking up is the reply you see:
Sending from a domain the credential is not bound to ends the transcript at MAIL FROM:
Add --quit-after RCPT to stop before DATA when you only want to test the envelope.

Retrying

Back off exponentially on a 4xx. On a 5xx, fix what the reply names (credential, address, size, content, or domain) before resending. Rate-limit behavior is covered in Rate limits.