Home > Tech > Sending Mail via Telnet

Sending Mail via Telnet

February 11th, 2004

While I was configuring postfix to act as a backup MX for Steve I needed a way to test it was configured correctly. Here is a quick cheat sheet how to send mail via a manual telnet session with a mail server:

  1. Telnet to hostname on port 25.
    Server should respond with a 220 and identify itself.
  2. HELO your_domain_name
    Server should respond with 250
  3. MAIL FROM:you@hostname
    Server should respond with 250
  4. RCPT TO:them@wherever
    Server should respond with 250
  5. DATA
    Servers tells you to send data then CRLF period CRLF at the end.
  6. Type the message then CRLF period CRLF (basically type a period on a line by itself and hit ENTER)
    Server responds with a 250
  7. QUIT
    Server responds with the signoff message

Tech

  1. No comments yet.
  1. No trackbacks yet.