Community Discussions and Support
SMTP test tool

Folks,

Looking at today's posts of GRC's Usenet I found a tool some of you may wanna try. The author also provides the full source code of the application. Following below, some of author's notes:

[quote]Wrote the tool quite some time ago for my personal needs, but since it may be useful for other people willing to run checks on SMTP servers and since it's useful for diagnostic purposes, I thought to share it, the zip file is available at this URL

http://www.mvps.org/bitbucket/smtptest.zip

and contains the 32 bits exe and the full "C" sources, the program is a simple commandline tool which may be used to perform some checks toward an SMTP server (or even the "FakeMX"), running the program without any arguments will show the following help

smtptest: simple SMTP server checking tool
Version 4.7 written by ObiWan Feb-2017

usage: smtptest [-option [value]] server_or_domain

option          option meaning/usage
------------      ------------------------------------------
-p port         SMTP port for connection (default=25)
-h helo         HELO/EHLO string to use (default=DNS-PTR)
-e                use HELO instead of EHLO
-a type         AUTH type 1=PLAIN, 2=LOGIN
-U user         AUTH user name
-P pass         AUTH password
-x                send a HELP command to the server
-f fromaddr    use this address as the "from" (-c/-r)
-c address     check <address> using VRFY/EXPN
-r recipient     try an RCPT TO <recipient>
-M filename   send an email from file contents
-t timeout      connect/response timeout (default=10000)
-n retries       number of retries on error (default=1)
-d delay        delay between retries (default=30000)
-i                  ignore SMTP 5xx codes (keep going)
-T                use TCP only for DNS queries (no UDP)
-I                 use ICMP to check if the host is alive
-m               test all MX for the given domain
-C               enable colors
-o               dump traffic in readable format
-v                enable verbose/debug logging mode
-?               shows this help text
------------     ------------------------------------------

examples: smtptest mx1.hotmail.com
                smtptest -t 30000 -v mx2.hotmail.com
                smtptest -r postmaster@live.com mx3.hotmail.com
                smtptest -xm hotmail.com

notice that while the program may optionally be used to send an email message, I purposely didn't optimize that part so hopefully it won't be abused as a "spam tool", also, the program currently doesn't support SSL, time ago I started fiddling with schannel code, but then I didn't go on and add it to the program, willing to do so, the best approach would probably be adding an "sslsock.c" module exposing the needed functions and then modifying the "smtptest.c" code to add calls to the module to deal with either implicit or explicit SSL modes.[/quote]

&lt;p&gt;Folks,&lt;/p&gt;&lt;p&gt;Looking at today&#039;s posts of GRC&#039;s Usenet I found a tool some of you may wanna try. The author also provides the full source code of the application. Following below, some of author&#039;s notes: &lt;/p&gt;&lt;p&gt;[quote]Wrote the tool quite some time ago for my personal needs, but since it may be useful for other people willing to run checks on SMTP servers and since it&#039;s useful for diagnostic purposes, I thought to share it, the zip file is available at this URL http://www.mvps.org/bitbucket/smtptest.zip and contains the 32 bits exe and the full &quot;C&quot; sources, the program is a simple commandline tool which may be used to perform some checks toward an SMTP server (or even the &quot;FakeMX&quot;), running the program without any arguments will show the following help smtptest: simple SMTP server checking tool Version 4.7 written by ObiWan Feb-2017 usage: smtptest [-option [value]] server_or_domain option&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; option meaning/usage ------------ &amp;nbsp; &amp;nbsp;&amp;nbsp; ------------------------------------------ -p port&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SMTP port for connection (default=25) -h helo&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HELO/EHLO string to use (default=DNS-PTR) -e&amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; use HELO instead of EHLO -a type&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AUTH type 1=PLAIN, 2=LOGIN -U user&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; AUTH user name -P pass&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; AUTH password -x&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp; send a HELP command to the server -f fromaddr&amp;nbsp;&amp;nbsp;&amp;nbsp; use this address as the &quot;from&quot; (-c/-r) -c address &amp;nbsp; &amp;nbsp; check &amp;lt;address&amp;gt; using VRFY/EXPN -r recipient&amp;nbsp; &amp;nbsp;&amp;nbsp; try an RCPT TO &amp;lt;recipient&amp;gt; -M filename&amp;nbsp;&amp;nbsp; send an email from file contents -t timeout&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; connect/response timeout (default=10000) -n retries&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; number of retries on error (default=1) -d delay&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; delay between retries (default=30000) -i&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp; ignore SMTP 5xx codes (keep going) -T&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; use TCP only for DNS queries (no UDP) -I&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; use ICMP to check if the host is alive -m&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; test all MX for the given domain -C&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; enable colors -o&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp; dump traffic in readable format -v&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp; enable verbose/debug logging mode -?&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; shows this help text ------------&amp;nbsp;&amp;nbsp; &amp;nbsp; ------------------------------------------ examples: smtptest mx1.hotmail.com &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; smtptest -t 30000 -v mx2.hotmail.com &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; smtptest -r postmaster@live.com mx3.hotmail.com &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; smtptest -xm hotmail.com notice that while the program may optionally be used to send an email message, I purposely didn&#039;t optimize that part so hopefully it won&#039;t be abused as a &quot;spam tool&quot;, also, the program currently doesn&#039;t support SSL, time ago I started fiddling with schannel code, but then I didn&#039;t go on and add it to the program, willing to do so, the best approach would probably be adding an &quot;sslsock.c&quot; module exposing the needed functions and then modifying the &quot;smtptest.c&quot; code to add calls to the module to deal with either implicit or explicit SSL modes.[/quote] &lt;/p&gt;

-- Euler

Pegasus Mail 4.81.1154 Windows 7 Ultimate
IERenderer: 2.7.1.5 AttachMenu: 1.0.1.2
PMDebug: 2.5.8.34 BearHTML 4.9.9.6

live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft