How to test relays using telnet or openssl s_client?
Manual SMTP testing validates relay behavior:
Basic telnet test (no TLS):
telnet mail.example.com 25. Observe greeting. Type EHLO test.com. Then MAIL FROM:<test@test.com>. Then RCPT TO:<recipient@example.com>. Observe each response.
TLS test with openssl:
openssl s_client -connect mail.example.com:465 (implicit TLS). Or openssl s_client -starttls smtp -connect mail.example.com:25. Then proceed with SMTP commands.
What to observe:
Server greeting and capabilities. Response codes at each step. Error messages for failures. Where rejection occurs.
Common tests:
Can you connect? Does STARTTLS work? Will it relay for your domain? What error for invalid recipient?
Manual testing shows exactly what the server does. No abstraction layer; pure SMTP conversation.
Was this answer helpful?
Thanks for your feedback!