It looks like James doesn't properly handle basic non-mime messages which do
_not_ begin with a CRLF after the SMTP 'DATA' command.
For example, I'm printing out all MIME headers (via a Mailet, with code
shown below) as a debugging test, and I can reproduce the following scenario
every time:

<Transcript of telnet session>
220 fnatural SMTP Server (JAMES SMTP Server 2.0a3) ready Fri, 27 Dec 2002
21:14:26 -0800
helo aeoifj
250 fnatural Hello aeoifj (fnatural [192.168.1.100])
mail from: <aeoijf@aeofij>
250 Sender <aeoijf@aeofij> OK
rcpt to: <[EMAIL PROTECTED]>
250 Recipient <[EMAIL PROTECTED]> OK
data
354 Ok Send data ending with <CRLF>.<CRLF>
This is noline body.
.
250 Message received

<Output of Mailet>
MIME Header: Return-Path = <aeoijf@aeofij>
MIME Header: Received = from fnatural ([192.168.1.100])
          by fnatural (JAMES SMTP Server 2.0a3) with SMTP ID 544
          for <[EMAIL PROTECTED]>;
          Fri, 27 Dec 2002 21:15:21 -0800
MIME Header: This is noline body. = This is noline body.         <==== UH
OH!!! WHAT"S THIS??
MIME Header: Date = Fri, 27 Dec 2002 21:15:21 -0800
MIME Header: From = aeoijf@aeofij


<Mailet code snippet>
          MimeMessage mimeMessage = mail.getMessage();

          try
          {
              java.util.Enumeration mimeHeaders =
mimeMessage.getAllHeaders();
              while ( mimeHeaders.hasMoreElements() )
              {
                  Header header = (Header)mimeHeaders.nextElement();
                  System.out.println( "MIME Header: " + header.getName() + "
= " + header.getValue() );
              }
          }
          catch (MessagingException ee)
          {
              // Do nothing
          }



CONCLUSIONS --> If you don't put either a) Message headers like From:, To:,
or b) an initial CRLF,  after the SMTP "DATA" prompt,  then James doesn't
properly handle the message body and confuses the body with a MIME header.
Makes sense??

-Dave


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to