Are you able to connect using another client ?
You may test using telnet, the protocol is easy to mimic by hand :
> telnet localhost 587
Something similar to the following should now be displayed:
Connected to mail.port25.com (126.96.36.199).
Escape character is '^]'.
220 mail.port25.com (PowerMTA(TM) v4.0) ESMTP service ready
The first command we need to issue to the mail server is the EHLO or HELO. This is a basic greeting that starts the communication between the telnet client and the SMTP server. Also passed is the DNS PTR for the IP address from which we are connecting as determined previously.
Something similar to the following should be returned:
250-mail.port25.com says hello
This shows the SMTP commands that the SMTP server accepts. Not all SMTP servers support the same sets of commands. For example, yahoo only shows the following:
And aol shows only one with:
The next command we need to issue is the MAIL FROM command. This determines the address to which bounces are sent. This is not the same as the from header, which is the email address shown in an email client.
MAIL FROM: <email@example.com>
250 2.1.0 MAIL ok
Now that the MAIL FROM command has been sent we can send the RCPT TO command. This command tells the SMTP mail server to who the message should be sent. This can be the same or different than the to header, which is the email address shown in the email client.
RCPT TO: <firstname.lastname@example.org>
250 2.1.5 <email@example.com> ok
The last command to run before starting the body of the message is the DATA command. This command lets the SMTP mail server know that everything else about to be sent is the body of the message (which also contains the headers).
354 send message
It is important to note that if a mail server supports PIPELINING, as mail.port25.com does, the SMTP mail server may wait until the DATA command is issued before responding to any other commands after the EHLO/HELO. In this case, enter the MAIL FROM, RCPT TO, and DATA commands before waiting for a response.
Now that the DATA command has been sent we can start sending the message contents. This starts with the various headers. At minimum a message should contain a to, from, subject, and date header. The headers entered here will be shown to the user in their email client.
From: "John Smith" <firstname.lastname@example.org>
To: "Jane Doe" <email@example.com>
Subject: test message sent from manual telnet session
Date: Wed, 11 May 2011 16:19:57 -0400
With the headers set, we now add one blank line with a carriage return/line feed (just press enter twice) and then we start the actual body of the message.
This is a test message sent from a manual telnet session.
With the message complete, we need to tell the SMTP server that we are done with the message and want the SMTP mail server to accept it. This is done with a period on a line by itself. If during the writing of a message a period on a line by itself is needed, you must put 2 periods, the first escaping the second.