#
if [ "$#" != 1 ]
then
   echo "Usage: $0 ip_address"
   exit 1
fi

while read mail_from
do
   read rcpt_to
   read junk

   ( sleep 2
     echo helo nowhere.com >&2
     echo helo nowhere.com
     sleep 1
     echo MAIL FROM: $mail_from >&2
     echo MAIL FROM: $mail_from
     sleep 1
     echo RCPT TO: $rcpt_to >&2
     echo RCPT TO: $rcpt_to
     sleep 12
     echo quit >&2
     echo quit
   ) | telnet $1 25
echo
done <<END
<sara@mail-abuse.org>
<sara@mail-abuse.org>

<sara>
<sara@mail-abuse.org>

<>
<sara@mail-abuse.org>

<sara@lynk.com>
<sara@mail-abuse.org>

<sara@lynk.com>
<sara%mail-abuse.org@lynk.com>

<sara@lynk.com>
<\"sara@mail-abuse.org\">

<sara@lynk.com>
<\"sara%mail-abuse.org\">

<sara@lynk.com>
<sara@mail-abuse.org@lynk.com>

<sara@lynk.com>
<\"sara@mail-abuse.org\"@lynk.com>

<sara@lynk.com>
<sara@mail-abuse.org@lynk.com>

<sara@lynk.com>
<@lynk.com:sara@mail-abuse.org>

<sara@>
<relaytest@mail-abuse.org@>

<sara@lynk.com>
<mail-abuse.org!sara>

<sara@lynk.com>
<mail-abuse.org!sara@lynk.com>

END
