A quick way to test your SMTP server is to use telnet. The default well known port for SMTP is 25.
telnet mail.example.com 25
220 mail.example.com ESMTP Postfix (Ubuntu)
250 2.1.0 Ok
250 2.1.5 Ok
354 End data with
250 2.0.0 Ok: Queued as ABC123
220 2.0.0 Bye
To use the labels, such as From, To, Subject, add them after the data command. i.e.
There are other commands you can issue such as ehlo (extended helo) instead of helo. This will have the server list it’s capabilities. Other commands such as vrfy (verify and address) may have been disabled by the system administrator.
One of the inherent problems with email is it allows the sender to use arbitry information in the headers. Fake domain addresses and so on. The mail administrator may use a variety of techniques to block spam and otherwise unwanted mail from entering their systems but it’s an ongoing battle.