Javax.mail.MessagingException: Missing start boundary

I use the following code creates a Mime file
MimeMultipart mmp = new MimeMultipart();
               MimeBodyPart mbp = null;
               // add rootpart
               mbp = new MimeBodyPart();
               mbp.setContentID("[email protected]");
               mbp.setDataHandler(new DataHandler(new FileDataSource(args[0])));
               mmp.addBodyPart(mbp);
               // add attachment info
               for(int i = 1; i < args.length; i = i+2){
                    ByteArrayOutputStream baos = new ByteArrayOutputStream();
                    GZIPOutputStream gos = new GZIPOutputStream(baos);
                    FileInputStream fis = new FileInputStream(args[i+1]);
                    byte[] bytes = new byte[1024];
                    int len;
                    while((len = fis.read(bytes, 0, 1024)) > 0){
                         gos.write(bytes, 0, len);
                    fis.close();
                    gos.close();
                    baos.close();
                    InternetHeaders ih = new InternetHeaders();
                    ih.addHeader("Content-ID", args);
                    mbp = new MimeBodyPart(ih, baos.toByteArray());
                    mmp.addBodyPart(mbp);
               String CarriageReturn = String.valueOf(CARRIAGE_RETURN);
               String lineFeed = String.valueOf(LINE_FEED);
               String horizontaltab = String.valueOf(HORIZONTAL_TAB);
               FileOutputStream fos = new FileOutputStream(args[0] + ".mime");
               StringBuffer msgParam = new StringBuffer();
               msgParam.append("MIME-Version: 1.0");
               msgParam.append(CarriageReturn);
               msgParam.append(lineFeed);
               msgParam.append("Content-Type: ");
               msgParam.append(mmp.getContentType().replaceAll(CarriageReturn,"").replaceAll(lineFeed,"").replaceAll(horizontaltab,""));
               msgParam.append("; start=\"<[email protected]>\"");
               msgParam.append(CarriageReturn);
               msgParam.append(lineFeed);
               msgParam.append(CarriageReturn);
               msgParam.append(lineFeed);
               msgParam.append(CarriageReturn);
               msgParam.append(lineFeed);
               fos.write(msgParam.toString().getBytes());
               mmp.writeTo(fos);
               fos.close();
I can correctly read the mime file at windows OS,but in linux OS i got the following error Message:
2010/11/19 11:53:40     K101J2EED1     fatal     0041EBFC124735B5B67FFA9F4B3B09961KD1     例外=[javax.mail.MessagingException: Missing start boundary]     
sun.reflect.GeneratedMethodAccessor303.invoke(Unknown Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:597)
org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:301)
org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
$Proxy28.execute(Unknown Source)
org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
jp.terasoluna.fw.web.struts.action.RequestProcessorEx.process(RequestProcessorEx.java:149)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
javax.servlet.http.HttpServlet.service(HttpServlet.java:713)
javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:675)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:324)
jp.co.nttdata.erc.sys.app.extended.ExtendedFilter.doFilter(ExtendedFilter.java:163)
org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:183)
org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:138)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:424)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:324)
jp.co.nttdata.erc.sys.app.extended.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:174)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:424)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:324)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:379)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.web.catalina.core.LinkedPipeline.invoke(LinkedPipeline.java:475)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:983)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:349)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.web.tcg.ThreadControlGroupValve.invoke(ThreadControlGroupValve.java:82)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.ejb.management.mbean.web.RequestStatisticsValve.invoke(RequestStatisticsValve.java:72)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:188)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.web.catalina.core.StandardSessionValve.invoke(StandardSessionValve.java:96)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.web.catalina.core.LinkedPipeline.invoke(LinkedPipeline.java:475)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:983)
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:3928)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:261)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:197)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.web.catalina.core.LinkedPipeline.invoke(LinkedPipeline.java:475)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:983)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
com.hitachi.software.web.catalina.core.ValveWrapper.invokeNext(LinkedPipeline.java:672)
com.hitachi.software.web.catalina.core.LinkedPipeline.invoke(LinkedPipeline.java:475)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:983)
org.apache.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:700)
org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:959)
java.lang.Thread.run(Thread.java:620)
Edited by: chengen on Nov 24, 2010 8:26 PM
Edited by: chengen on Nov 24, 2010 9:25 PM

I can correctly read the mime file at windows OS,but in linux OS i got the following error Message:That would suggest one or more of the following.
1. An end of line problem. Something is wrong with your use of CR/LF.
2. A line length problem (brief look suggests a 998 limit.)
3. One reader is more lenient than the other. This goes back to 1 and 2.

Similar Messages

  • .MessagingException - Missing start boundary when loading a mail twice

    Hi!
    I have found a very interesting behaviour. When parsing a multipart mail twice, there is an error "javax.mail.MessagingException: Missing start boundary". This happens for every multipart mail which is fetched via POP3 and seems to be independant of both POP3 Server and the mail client the message was built with.
    Environment:
    debian linux, amd64, java 1.6
    latest javamail from https://hg.kenai.com/hg/javamail~mercurial
    Test program:
    import java.io.*;
    import javax.mail.*;
    public class Mailtest {
         private final static void loadMail(Part p) throws Exception{
              Object content = p.getContent();
              if (content instanceof Multipart) {
                   Multipart mp = (Multipart) content;
                   int cnt = mp.getCount();
                   for (int u=0;u<cnt;u++) {
                        loadMail(mp.getBodyPart(u));
         public final static void main(String[] args) throws Exception {
              //System.setProperty("mail.mime.cachemultipart", "true");
              java.util.Properties props = new java.util.Properties();
              Session mailSession = Session.getInstance(props, null);
              Store store = mailSession.getStore("pop3");
              store.connect("pop3srv", 110, "username", "pwd");
              Folder folder = store.getFolder("INBOX");
              folder.open(Folder.READ_WRITE);
              Message[] msgs = folder.getMessages();
              for (int i=0;i<msgs.length;i++) {
                   /*if (msgs[i] instanceof com.sun.mail.pop3.POP3Message) {
                        System.out.println("inputstream");
                        InputStream in = msgs.getDataHandler().getInputStream();
                        in.close();
                   System.out.println("i=" + i + " try = 1");
                   loadMail(msgs[i]);
                   System.out.println("i=" + i + " try = 2");
                   loadMail(msgs[i]);     
    Output:
    i=0 try = 1
    i=0 try = 2
    Exception in thread "main" javax.mail.MessagingException: Missing start boundary
    at javax.mail.internet.MimeMultipart.parsebm(MimeMultipart.java:882)
    at javax.mail.internet.MimeMultipart.parse(MimeMultipart.java:503)
    at javax.mail.internet.MimeMultipart.getCount(MimeMultipart.java:244)
    at testapp.Mailtest.loadMail(Mailtest.java:11)
    at testapp.Mailtest.main(Mailtest.java:38)
    Java Result: 1
    I thought that the 2 code blocks which are commented might be a workaround, but nothing changed if both blocks are active.
    BTW: What is "mail.mime.multipart.bmparse" supposed to do?

    Yes, thank you, that's a bug introduced in the (not yet final) JavaMail 1.4.4 release.
    I've fixed it. I'll push the fix soon.
    mail.mime.multipart.bmparse is a property to control whether the old (slow) multipart parser
    is used, or the new (fast) Boyer-Moore multipart parser is used.

  • Correct way to copy Multipart and prevent Missing start boundary Exception

    Hi there
    I've worked through the FAQ's and forum and based on the info available tried to construct code to deal with the whole "javax.mail.MessagingException: Missing start boundary" problem. I keep on getting a ClassCastException though and was hoping you could scan through the code and let me know if you see anything. I must be missing something ... simplified extract of code below:
    Multipart mp = (Multipart)part.getContent();
    try {
         for (int i = 0; i < mp.getCount(); i++) {
              processBodyPart(wrapper, mp.getBodyPart(i), i);
    } catch (MessagingException e) {
         // Converting Msg to a Copy (to fix boundary)
         ByteArrayOutputStream bos = new ByteArrayOutputStream();
         part.writeTo(bos);
         byte[] bytes = bos.toByteArray();
         MimeMessage newMsg = new MimeMessage(emailAccount.getSession(), new ByteArrayInputStream(bytes));
         String ct = newMsg.getContentType();
         newMsg.removeHeader("Content-Type");
         ct = ct.substring(0, ct.indexOf(";")); // Strip out the rest, only retain the content-type
         newMsg.setDataHandler(new DataHandler(newMsg.getContent(), ct));
         Multipart testMp = (Multipart)newMsg.getContent(); // <<-------- ClassCastException here!!
         for (int i = 0; i < testMp.getCount(); i++) {
              Part bp = testMp.getBodyPart(i);
              processBodyPart(bp);
    }Much appreciated.
    Marius

    I took out the truncating part to make the example shorter,
    but I did try both keeping it as it was, as well as truncating
    it (it is "multipart/mixed") with the same effect.
    I was able to save the entire message to file (thanks), attached
    below - maybe you can spot something that could be causing it?
    Thanks again.
    X-Original-To: [email protected]
    Delivered-To: [email protected]
    Received: from mail.adept.co.za (localhost [127.0.0.1])
         by mail.adept.co.za (Postfix) with ESMTP id E3074C03D9
         for <[email protected]>; Fri, 18 Jan 2008 14:35:29 +0200 (SAST)
    X-Greylist: from auto-whitelisted by SQLgrey-1.7.4
    Received: from mail-03.jhb.wbs.co.za (mail-03.jhb.wbs.co.za [196.2.97.2])
         by mail.adept.co.za (Postfix) with ESMTP id CA3AEC03D7
         for <[email protected]>; Fri, 18 Jan 2008 14:35:28 +0200 (SAST)
    Received: from localhost by mail-03.jhb.wbs.co.za;
      18 Jan 2008 14:35:28 +0200
    Date: 18 Jan 2008 14:35:28 +0200
    To: [email protected]
    From: "Mail Delivery System" <[email protected]>
    Subject: Delivery Status Notification (Failure)
    MIME-Version: 1.0
    Content-Type: multipart/report; report-type=delivery-status; boundary="9sdJO.4G/vWebcc.bcm9J.Ak/cwPA"
    Message-Id: <[email protected]>
    X-Virus-Scanned: ClamAV Passed
    X-Spam-Scanned: -1.4
    X-Scanned-By: proxfilter
    --9sdJO.4G/vWebcc.bcm9J.Ak/cwPA
    content-type: text/plain;
        charset="utf-8"
    Content-Transfer-Encoding: quoted-printable
    The following message to <[email protected]> was undeliverable.
    The reason for the problem:
    5.1.2 - Bad destination host 'DNS Hard Error looking up onyxit.co.za (MX): =
    NXDomain'
    --9sdJO.4G/vWebcc.bcm9J.Ak/cwPA
    content-type: message/delivery-status
    Reporting-MTA: dns; jnb-mailfw01.wbs.co.za
    Final-Recipient: rfc822;[email protected]
    Action: failed
    Status: 5.0.0 (permanent failure)
    Diagnostic-Code: smtp; 5.1.2 - Bad destination host 'DNS Hard Error looking up onyxit.co.za (MX):  NXDomain' (delivery attempts: 0)
    --9sdJO.4G/vWebcc.bcm9J.Ak/cwPA
    content-type: message/rfc822
    Received: from wbs-smtp-out-02.jhb.wbs.co.za (HELO wbs-smtp-out-02) ([196.2.97.197])
      by mail-03.jhb.wbs.co.za with ESMTP; 18 Jan 2008 14:35:28 +0200
    Received: from wbs-smtp-out-02.jhb.wbs.co.za (HELO wbs-smtp-out-02) ([196.2.97.197])
      by mail-03.jhb.wbs.co.za with ESMTP; 18 Jan 2008 14:35:28 +0200
    Received: from wbs-41-208-227-16.wbs.co.za ([41.208.227.16] helo=jnfsworkpool)
         by wbs-smtp-out-02 with esmtp (Exim 4.67)
         (envelope-from <[email protected]>)
         id 1JFqSK-0000qy-8m; Fri, 18 Jan 2008 14:36:30 +0200
    Date: Fri, 18 Jan 2008 14:35:10 +0200 (SAST)
    From: Ros Copeling <[email protected]>
    To: [email protected]
    Cc: [email protected]
    Message-ID: <[email protected]>
    Subject: FW: Fw: Message from ESKOM
    MIME-Version: 1.0
    Content-Type: multipart/mixed;
         boundary="----=_Part_16_32195616.1200659710788"
    X-Priority: 3
    Importance: normal
    Sensitivity: Normal
    workpool_message_id: 6879
    X-Original-Subject: FW: Fw: Message from ESKOM
    X-Spam-Ignored: [TOO LARGE] Message > 100K
    X-Scan-Signature: 66244f1a8ccb48c519852bcb33c1a261
    --9sdJO.4G/vWebcc.bcm9J.Ak/cwPA--

  • Missing start boundary exception, caused by an empty Part, how to handle?

    Hello,
    i wrote an application that automatically handles mails from laboratories. The only essential part of the mail is the attachment, where chemical analyses are submitted (from permitted addresses, recognized by whitelist and fileheader of the attachment). Other ways to submit data weren't allowed.
    Currently a mail was received that can't be parsed. It's from a laboratory, that
    use its provider's (a german internet suplier named Arcor) webmail, a browser-based mailing portal. It always worked fine, because they wrote some greetings. But this time they sent a blank message. The result is following structure of the mail:
    MIME-Version: 1.0
    Content-Type: multipart/mixed;
    boundary="----=_Part_50112_10709369.1203586767396"
    //Some X-Flags
    ------=_Part_50112_10709369.1203586767396
    Content-Type: multipart/alternative;
         boundary="*----=_Part_50111_24141780.1203586767396*"
    ------=_Part_50111_24141780.1203586767396--
    ------=_Part_50112_10709369.1203586767396
    Content-Type: application/octet-stream
    Content-Transfer-Encoding: base64
    Content-Disposition: attachment; filename=somefile.bin
    ABCDEF.... //Some binary data
    ------=_Part_50112_10709369.1203586767396--
    It seems the webmailer creates an empty mailpart and only writes the end boundary (Line: ------=_Part_50111_24141780.1203586767396--).
    I know, the start boundary is really missing.
    I checked it out by getting a mailaccount from Arcor, and it always creates this structure when sending a message without a text. By the way, the Message-ID (header) generated from Arcor's server seems to be from javamail. (.....1234.567890.....JavaMail.ngmail@....).
    I don't know how many mailclients create "empty" parts, but impossible is nothing (e.g. other or future webmailer services).
    But how to handle?
    The error occures when calling MimeMultipart.getCount(), which causes to parse the mail if not parsed. All actions, which cause the mail to be parsed, will end in this exception (for this mail).
    I looked at the javamail source and found out, that the line of the empty part is not recognized as a boundary, because of its ending delimiters:
    if (line.equals(boundary))
    break;
    So the boundary is added to the preamble. It goes on with reading lines from the stream, until line == null.
    if (line == null)
    throw new MessagingException("Missing start boundary");
    Because there is no test, if the line matches the end boundary, it's not recognized. Wouldn't it be better in this case, to add an empty bodypart and set a variable to false (e.g. complete) instead of throwing an exception? Because MimeMultipart.parse() is called by other methods, like getCount, getBodyPart and writeTo, I can't nearly do anything automatically with the mail. How should i walk through the bodyparts and fetch the parts I'm interested in?
    Subclassing seems to be difficult to me:
    Object content = message.getContent();
    //javax.mail.Message, won't return a subclassed multipart
    if (content instanceof Multipart) {
    //recursive method!
    handleMultipart((Multipart) content); //collecting parts from multipart
    Of course, I could ask the laboratory: "please send me a greeting!" ;-)
    Greetings,
    cliff

    Interesting.
    Yes, it's probably a bug that JavaMail allows you to
    create a multipart with no body parts, since the
    MIME specification doesn't allow that. Still, the
    webmail application should be fixed so that it doesn't
    try to do that, at least including an empty plain text
    body part.
    Please contact the webmail provider and tell them of
    this bug in their application.
    I'll also look into making JavaMail cope with these
    broken messages more gracefully. Contact me
    at [email protected] and I'll let you know when
    I have a version ready to test.

  • Mail doesn't send - javax.mail.MessagingException: 250

    Hello all,
    I'm new to JavaMail. I actually started with it last night. I've successfully sent a number of messages, but I randomly get a strange exception for no apparent reason.
    If I run the exact same code several times, it will produce this error about every 5 or 6 times:
    javax.mail.MessagingException: 250 Requested mail action okay, completed
    Does anyone know what might be going on? Thanks in advance for any help you might can give.
    Here is the heart of my code:
    // Get system properties
    Properties props = System.getProperties();
    // Setup mail server
    props.put("mail.smtp.host", host1);
    // Get session
    Session session = Session.getDefaultInstance(props, null);
              session.setDebug(true);
    // Define message
    MimeMessage message = new MimeMessage(session);
    // Set the from address
    message.setFrom(new InternetAddress(fromAddress));
    // Set the to address
    message.addRecipient(Message.RecipientType.TO, new InternetAddress(toAddress));
    // Set the subject
    message.setSubject(subject);
    // Set the content
    message.setContent(content, "text/html");
    // Send message
    Transport.send(message);
    Below is the debugger output: (certain values have been removed for anonymity's sake)
    DEBUG: getProvider() returning javax.mail.Provider[TRANSPORT,smtp,com.sun.mail.smtp.SMTPTransport,Sun Microsystems, Inc]
    DEBUG SMTP: useEhlo true, useAuth false
    DEBUG: SMTPTransport trying to connect to host "xx.xx.xx.xx", port 25
    DEBUG SMTP RCVD: 220 domain.company.com ESMTP MailEnable Service, Version: 1.704-- ready at 01/14/04 14:07:27
    DEBUG: SMTPTransport connected to host "xx.xx.xx.xx", port: 25
    DEBUG SMTP SENT: EHLO licensing
    DEBUG SMTP RCVD: 502
    DEBUG SMTP SENT: HELO licensing
    DEBUG SMTP RCVD: 250-AUTH LOGIN
    250-SIZE 5120000
    250-HELP
    250 AUTH=LOGIN
    DEBUG SMTP: use8bit false
    DEBUG SMTP SENT: MAIL FROM:<[email protected]>
    DEBUG SMTP RCVD: 250 Requested mail action okay, completed
    DEBUG SMTP SENT: RCPT TO:<[email protected]>
    DEBUG SMTP RCVD: 250 Requested mail action okay, completed
    Verified Addresses
    [email protected]
    DEBUG SMTP SENT: DATA
    DEBUG SMTP RCVD: 250 Requested mail action okay, completed
    DEBUG SMTP SENT: QUIT

    But I am getting that code thrown as a MessageException; the message never goes through. If you look at the debugging output compared to a message that went through, the DATA transmission commands are screwed up.
    Thanks for your input, though. I think I've gotten around this by trying to resend the message. It looks like that when I get this exception the message is never sent. I have a catch that detects this exception and tries to resend up to 3 times.
    Thanks,
    floosh

  • Missing start boundary

    Hi ,
    i have Missing start boundary exception while reading message..
    Following is message information.Can any one let me know how i can fix this problem.
    Received: from backup1.texterity.com ([68.112.246.59]) by exchange2003.scientificmonitoring.com with Microsoft SMTPSVC(6.0.3790.1830); Thu, 8 Mar 2007 11:37:05 -0700
    Received: from backup1.texterity.com (localhost.localdomain [127.0.0.1]) by backup1.texterity.com (8.13.1/8.13.1) with ESMTP id l28IaTnQ023719 for <[email protected]>; Thu, 8 Mar 2007 13:36:29 -0500
    Received: (from textcafe@localhost) by backup1.texterity.com (8.13.1/8.13.1/Submit) id l28IaR1K023718; Thu, 8 Mar 2007 13:36:27 -0500
    Content-Transfer-Encoding: binary
    X-MimeOLE: Produced By Microsoft Exchange V6.5
    Content-Type: multipart/alternative;
         boundary="----=_NextPart_000_20F60_01C76D97.08C9D40D"
    MIME-Version: 1.0
    X-Mailer: MIME::Lite 3.01 (F2.73; A1.67; B3.05; Q3.03)
    Date: Thu, 8 Mar 2007 18:36:26 UT
    From: <[email protected]>
    Subject: Intech March 2007 Digital Edition
    To: <[email protected]>
    Message-ID: [email protected]
    Return-Path: <[email protected]>
    X-OriginalArrivalTime: 08 Mar 2007 18:37:05.0234 (UTC) FILETIME=[C51A9320:01C761B0]
    This is a multi-part message in MIME format.
    ------=_NextPart_000_20F63_01C76D97.08C9D40D
    Content-Disposition: inline
    Content-Length: 1066
    Content-Transfer-Encoding: quoted-printable
    Content-Type: text/plain;
         charset="iso-8859-1"
    You can now find your March issue of InTech at=20
    http://pubsrv.texterity.com/cgi-bin/pwf_gateway.cgi?d=3Dwww.isa-intech-di=
    gital.org&u=3D/intech/200703&s=3DCEGUsgx3DOlJm&e=3D3567746.=20
    Each month, we will e-mail you a link to the current issue of InTech.
    Your digital issue has the exact same content as a printed copy but with
    unique features, such as the ability to:
    *     Search and page through articles online=20
    *     Zoom, print, or e-mail pages to a colleague=20
    *     Archive your issues for convenient retrieval=20
    We hope you enjoy your digital issues of InTech magazine. Thank you for
    your readership.
    Sincerely,=20
    Gregory Hale
    InTech Editor=20
    Click here to convert to the print edition: =
    http://pubsrv.texterity.com/cgi-bin/pwf_optout.cgi?c=3Dintech&e=3Djim@sci=
    entificmonitoring.com&email_msgid=3D3567746
    This email was sent to: [email protected]
    Please do not reply to this mail.
    For technical questions regarding the digital edition, email =
    [email protected].
    From ISA, PO Box 12277, 67 Alexander Drive, Research Triangle Park, NC =
    27709
    ------=_NextPart_000_20F63_01C76D97.08C9D40D
    Content-Disposition: inline
    Content-Length: 4386
    Content-Transfer-Encoding: quoted-printable
    Content-Type: text/html;
         charset="iso-8859-1"
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <title>Intech Digital Edition</title>
    <meta http-equiv=3D"Content-Type" content=3D"text/html; =
    charset=3Diso-8859-1">
    </head>
    <body>
    <IMG =
    SRC=3D"http://pubsrv.texterity.com/cgi-bin/pwf_eds.cgi?transaction_type=3D=
    datalog&[email protected]&publication=3Dintech=
    &id_stamp=3Dintech.20070308133626&user_action=3Dviewmail&email_msgid=3D35=
    67746" height=3D"0" width=3D"0" border=3D"0">
    <TABLE WIDTH=3D613 BORDER=3D0 CELLPADDING=3D0 CELLSPACING=3D0>
         <TR>
              <TD COLSPAN=3D2><A =
    HREF=3D"http://pubsrv.texterity.com/cgi-bin/pwf_gateway.cgi?d=3Dwww.isa-i=
    ntech-digital.org&u=3D/intech/200703&s=3DCEGUsgx3DOlJm&e=3D3567746" =
    TARGET=3D"_blank" TITLE=3D"Intech">
                   <IMG BORDER=3D0 =
    SRC=3D"http://www.texterity.com/images/intech/intech_header.gif" =
    WIDTH=3D613 HEIGHT=3D116></A></TD></TR>
         <TR>
              <TD VALIGN=3DTOP WIDTH=3D144>
              <TABLE BORDER=3D0 CELLPADDING=3D6 CELLSPACING=3D6><TR =
    ALIGN=3DCENTER><TD ALIGN=3DCENTER>
              <A =
    HREF=3D"http://pubsrv.texterity.com/cgi-bin/pwf_gateway.cgi?d=3Dwww.isa-i=
    ntech-digital.org&u=3D/intech/200703&s=3DCEGUsgx3DOlJm&e=3D3567746" =
    TARGET=3D"_blank" TITLE=3D"Click here to read Intech">
              <IMG style=3D"border: solid 1px; border-color: black" =
    SRC=3D"http://www.isa-intech-digital.org/tcprojects/isa/intech/inbox/3820=
    4/imgpages/tn/intech200703_0001.gif"
                   ALT=3D"Click here to read Intech"></A></TD></TR>
              <TR HEIGHT=3D109><TD> </TD></TR>
              <TR ALIGN=3DCENTER><TD ALIGN=3DCENTER><A =
    HREF=3D"http://www.texterity.com" TARGET=3D"_blank">
              <IMG BORDER=3D0 =
    SRC=3D"http://www.texterity.com/images/ViaTexterity.gif" width=3D132 =
    height=3D45 ALT=3D"Digital Delivery Via =
    Texterity"></A></TD></TR></TABLE></TD>
              <TD VALIGN=3DTOP><TABLE BORDER=3D0 CELLPADDING=3D6 =
    CELLSPACING=3D6><TR><TD>
              <P style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">
              You can now find your March issue of InTech at <br><a =
    href=3D"http://pubsrv.texterity.com/cgi-bin/pwf_gateway.cgi?d=3Dwww.isa-i=
    ntech-digital.org&u=3D/intech/200703&s=3DCEGUsgx3DOlJm&e=3D3567746" =
    target=3D"_blank">http://www.isa-intech-digital.org/intech/200703/</a>.
              </p>
              <P style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">Each month, we will e-mail you a link to the current =
    issue of InTech. Your digital issue has the exact same content as a =
    printed copy but with unique features, such as the ability to:</p>
              <ul><li style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">
              Search and page through articles online </li>
              <li style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">Zoom, print, or e-mail pages to a colleague</li>
              <li style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">Archive your issues for convenient retrieval</li></ul>
              <P style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">We hope you enjoy your digital issues of InTech =
    magazine. Thank you for your readership.</p>
              <P style=3D"font-family:verdana,arial,helvetica,sans-serif; =
    font-size:12px;">
              Sincerely,<br><br>
              Gregory Hale<br>
              InTech Editor
              </P>
         </TD></TR></TABLE>
    </TD></TR></TABLE>
    <TABLE WIDTH=3D613 BORDER=3D0 CELLPADDING=3D0 CELLSPACING=3D0><TR><TD>
         <table width=3D"100%" border=3D"0" cellspacing=3D"0" cellpadding=3D"0" =
    bgcolor=3D"#FFFFEE">
              <tr><td>
              <IMG BORDER=3D0 =
    SRC=3D"http://www.texterity.com/images/recycling-footer.gif" WIDTH=3D613 =
    HEIGHT=3D11>
    <font face=3D"arial" size=3D"1" color=3Dblack>
      <a =
    href=3D"http://pubsrv.texterity.com/cgi-bin/pwf_optout.cgi?c=3Dintech&e=3D=
    [email protected]&email_msgid=3D3567746">Click here</a> to =
    Convert to the print edition.<BR>
      This email was sent to: [email protected]<BR>
      If you cannot click on the links above, please copy and paste =
    this url into your browser:<BR>
      <a =
    href=3D"http://pubsrv.texterity.com/cgi-bin/pwf_gateway.cgi?d=3Dwww.isa-i=
    ntech-digital.org&u=3D/intech/200703&s=3DCEGUsgx3DOlJm&e=3D3567746">http:=
    //www.isa-intech-digital.org/intech/200703/</A><BR>
      Please do not reply to this mail.<BR>
      For technical questions regarding the digital edition, email <a =
    href=3D"mailto:[email protected]?subject=3DIntech%20Support%2=
    0Request">[email protected]</a>.<BR>
      From From ISA, PO Box 12277, 67 Alexander Drive, Research =
    Triangle Park, NC 27709</font><br>
              </td></tr>
              <tr><td bgcolor=3D"#FFFFEE">
         </td></tr></table>
    </TD></TR></TABLE>
    </body>
    </html>
    ------=_NextPart_000_20F63_01C76D97.08C9D40D--
    can any one please help how i can fix this.

    Right on all counts. I have been able to resolve #1 and #2 using the prescribed workarounds.
    I'm still persuing #3 This seems to be the most common issue, as our application receives dozens of these each day. Our mail administrator gave the "it's working with everything else" response - of course everything else is probably not using the IMAP interface... If anyone has had a similar problem with Trend or Sophos specifically, let me know. I will need to output the raw IMAP stream, find the specific RFC 2822 violation and take it to the vendor. Any setting on the JavaMail side to compensate for the problem, would of course be helpful. I have to be careful not to break working messages that have file attachments, though. It's possible that my attempt of the workaround you described was incorrect - I'll go back and try it again with a simpler code example.
    #4 I've not had success with JTNEF yet, but I'm not sure if it's even still a problem after the workaround for #2. Anyway, that one seems to be infrequent so it's low priority for me.
    #5 As you mention in the other thread: this is a problem with a couple of email clients (Thunderbird and Apple Mail, possibly others) - maybe they are using a common library? Anyway, I'm going to try out the workaround posted in that thread if I can get more specifics.
    It would be nice if the various workarounds could be handled within JavaMail, a global LIBERAL=true setting : ) , although I understand that could be a never-ending project for JavaMail considering the number of vendor problems. Also such workarounds could certainly cause "code entropy" within JavaMail code. Getting the vendor to fix their product also kind of depends on whether or not I have 'business leverage' on the buggy software. In my case, for example, I can apply leverage on virus gateway vendors to fix their product, but not on customers who are sending me incorrectly formatted emails and have the option of going elsewhere for business.
    In any case, thanks for all the help - it has been greatly appreciated.

  • Multipart/report - Missing Start Boundary - MultiPart.getContent()

    I am writing to you in regard to an issue that I have been facing recently, and I wanted to see if the JavaMail developers / community could provide any answers.
    Does JavaMail support the multipart/report MIME specification (RFC 1892)?
    The reason I ask, is that I have seen a strong correlation between errors in JavaMail and this content....
    I am getting Missing Start Boundary exceptions when I execute this code on a message that has this Mime Type in it, (multipart/report)
    mp = (Multipart)part.getContent();
    count = mp.getCount(); // THIS IS WHAT THROWS THE ERROR
    An example of this message header, would be
    X-Atlas-MailScanner-From: [email protected]
    Content-Type: multipart/report; report-type=delivery-status;
    boundary="==IFJRGLKFGIR5607UHRUHIHD"
    ** NOTE HOW BOUNDARY IS SPECIFIED UNLIKE THE OTHER SECTIONS WHICH LEADS ME TO BELIEVE THE MISSING START BOUNDARY EXCEPTION **
    --==IFJRGLKFGIR5607UHRUHIHD
    Content-Type: text/plain; charset=UTF-8
    Content-Transfer-Encoding: base64
    --==IFJRGLKFGIR5607UHRUHIHD
    Content-Type: message/rfc822
    I have seen older posts that talk about other people's problem regarding this Exception; however, have not seen an abstract way for circumventing the issue.
    Any insight/future development intentions/experience in dealing with this issue would be greatly appreciated.
    RR

    I'm getting the same exception on several "bounce" messages I try to access with JavaMail. I believe that some of them are flat-out wrong in their MIME encoding, as there truly is no start boundary. However, some appear to be OK and causing JavaMail to give an exception. Should this be logged as a bug?
    Here's an example similar to yours (I didn't include all the received headers and several addresses are munged):
    <blockquote><i>{noformat}Date: Sat, 19 Apr 2008 06:57:46 -0400
    From: [email protected]
    Subject: Undelivered mail
    To: x
    Message-ID: <[email protected]>
    MIME-Version: 1.0
    Content-Type: multipart/report; report-type=delivery-status;
            boundary="--TKFLZMMSbcaBDNCJdCBMaXGSRbVIAF"
    --TKFLZMMSbcaBDNCJdCBMaXGSRbVIAF<br />
    --> Error description:
    Error-For: [email protected]
    Error-Code: 5.1.1
    Error-Text: No such list.
    Error-End: One error reported.
    --TKFLZMMSbcaBDNCJdCBMaXGSRbVIAF<br />
    Content-Type: message/delivery-status
    Reporting-MTA: dns; LISTS.NETSPACE.ORG
    Final-Recipient: RFC822; [email protected]
    Action: failed
    Status: 5.1.1 (No such list)
    --TKFLZMMSbcaBDNCJdCBMaXGSRbVIAF<br />
    Content-Type: message/rfc822
    Return-Path: <x>
    X-Original-To: [email protected]
    Received: from ppp91-122-170-233.pppoe.avangarddsl.ru (ppp91-122-170-233.pppoe.avangarddsl.ru [91.122.170.233]) by lists.netspace.org (Postfix) with ESMTP id 538527A53A for <[email protected]>; Sat, 19 Apr 2008 06:57:45 -0400 (EDT)
    Received: from [91.122.170.233] by mx1.bne.server-mail.com; Sat, 19 Apr 2008 14:06:15 +0300
    Message-ID: <01c8a226$87bfa580$e9aa7a5b@retentioncal53>
    From: "x" <x>
    To: <[email protected]>
    Subject: The extracts of VPXL are Pueraria tuberose 75 mg, Mucuna pruriens 75 mg, Asteracantha longifolia 75 mg.
    Date: Sat, 19 Apr 2008 14:06:15 +0300
    MIME-Version: 1.0
    Content-Type: text/plain; format=flowed; charset="Windows-1252"; reply-type=original
    Content-Transfer-Encoding: 7bit
    X-Priority: 3
    X-MSMail-Priority: Normal
    X-Mailer: Microsoft Outlook Express 6.00.2741.2600
    X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2741.2600
    TKFLZMMSbcaBDNCJdCBMaXGSRbVIAF{noformat}
    </i></blockquote>

  • Missing start Boundary exception

    Hi all,
    I am evaluating an e-mal archiving software that utilizes javamail. I am getting a high number of messages that don't get archived, due to the Missing start Boundary exception.
    Now I know, that often times e-mail messages don't get correctly constructed, but the sheer number of rejected messages really struck me.
    So I gathered a message and loaded it into a text editor to check the boundary structure myself.
    I have stripped the message down to reflect the boundary structure and I would like to know, if I missed anything, but I can't find out why javamail complains about a missing start boundary.
    I could post the complete message as well, if my example should not be suitable for examining this issue.
    So, here we go:
    Content-Type: multipart/signed; protocol="application/x-pkcs7-signature"; micalg=sha1; boundary="------------ms020608030602020702090804"
         This is a cryptographically signed message in MIME format.
         --------------ms020608030602020702090804
         Content-Type: multipart/mixed; boundary="------------070406040008020802000107"
              This is a multi-part message in MIME format.
              --------------070406040008020802000107
              Content-Type: text/plain; charset=ISO-8859-1; format=flowed
              Content-Transfer-Encoding: quoted-printable
              Test f=FCr mailArchiva III
              --------------070406040008020802000107
              Content-Type: multipart/alternative; boundary="============_CoolerEmail_============"
                   Date: Wed, 23 Apr 2008 07:41:31 -0700
                   --============_CoolerEmail_============
                   Content-Transfer-Encoding: binary
                   --============_CoolerEmail_============
                   Content-Transfer-Encoding: binary
                   Content-Type: text/html; charset="iso-8859-1"
              --============_CoolerEmail_============--
         --------------070406040008020802000107--
         --------------ms020608030602020702090804
    --------------ms020608030602020702090804--
    Thanks,
    Stephan

    Hi Bill,
    well, yes. It's one of a huge amount of messages being rejected. Actually I am not a programmer, but I try to deal with an archiving solution called mailArchiva. This software uses javamail and the mails get into the software using a postfix milter.
    I wanted to make sure that my gateways don't mess up these messages, prior getting into negotiation with the developer about what could be wrong along the way.
    I will now contact him and see, if I can get any more logs from the software.
    Thanks,
    Stephan

  • Javax.mail.MessagingException: Unable to load BODYSTRUCTURE

    Hi.
    when i try receive message i have next exception. (But some message recieve without this problem). Can help me?
    Exception with Session debug:
    A12 FETCH 5 (ENVELOPE INTERNALDATE RFC822.SIZE)
    * 5 FETCH (INTERNALDATE "14-Dec-2006 08:46:20 -0500" RFC822.SIZE 35458 ENVELOPE ("Thu, 14 Dec 2006 15:46:13 +0200" "Fwd: Fwd: 123" (("s2mtestAIM" NIL "s2mtest" "aim.com")) (("s2mtestAIM" NIL "s2mtest" "aim.com")) (("s2mtestAIM" NIL "s2mtest" "aim.com")) ((NIL NIL "s2mtest" "aim.com")) NIL NIL "<[email protected]>" "<[email protected]>"))
    A12 OK FETCH completed
    FROM: s2mtestAIM <[email protected]>
    TO: [email protected]
    SUBJECT: Fwd: Fwd: 123
    SendDate: Thu Dec 14 15:46:13 EET 2006
    FLAGS: XAOL-GOODCHECK-DONE
    A13 FETCH 5 (BODYSTRUCTURE)
    * 5 FETCH (BODYSTRUCTURE (("TEXT" "HTML" ("CHARSET" "windows-1251") NIL NIL "QUOTED-PRINTABLE" 4071 146 NIL NIL NIL)("MESSAGE" "RFC822" ("NAME" "1.eml") NIL NIL "7BIT" 13251 NIL ("attachment" ("FILENAME" "1.eml")) NIL)("MESSAGE" "RFC822" NIL NIL NIL "7BIT" 17777 ("Thu, 14 Dec 2006 13:17:25 +0200" "Fwd: 123" (("s2mtestAIM" NIL "s2mtest" "aim.com")) (("s2mtestAIM" NIL "s2mtest" "aim.com")) (("s2mtestAIM" NIL "s2mtest" "aim.com")) ((NIL NIL "s2mtest" "aim.com")) NIL NIL "<[email protected]>" "<[email protected]>") (("TEXT" "HTML" ("CHARSET" "windows-1251") NIL NIL "QUOTED-PRINTABLE" 3103 124 NIL NIL NIL)("MESSAGE" "RFC822" ("NAME" "1.eml") NIL NIL "7BIT" 3723 NIL ("attachment" ("FILENAME" "1.eml")) NIL)("MESSAGE" "RFC822" NIL NIL NIL "7BIT" 1658 ("Thu, 14 Dec 2006 12:36:23 +0200" "123" (("12323" NIL "resetdel" "gmail.com")) (("12323" NIL "resetdel" "gmail.com")) (("12323" NIL "resetdel" "gmail.com")) ((NIL NIL "s2mtest" "aol.com")) NIL NIL NIL "<[email protected]>") ("TEXT" "HTML" ("CHARSET" "windows-1251") NIL NIL "7BIT" 1658 0 NIL NIL NIL) 0 NIL NIL NIL)("TEXT" "HTML" ("CHARSET" "windows-1251") NIL NIL "QUOTED-PRINTABLE" 2063 97 NIL NIL NIL)("TEXT" "PLAIN" ("CHARSET" "US-ASCII") NIL NIL "7BIT" 1697 35 NIL NIL NIL)("TEXT" "HTML" ("CHARSET" "windows-1251") NIL NIL "QUOTED-PRINTABLE" 2063 97 NIL NIL NIL) "MIXED" ("BOUNDARY" "----------87AC1A33733336A") NIL NIL) 440 NIL NIL NIL) "MIXED" ("BOUNDARY" "----------121BF2519BABDF9") NIL NIL))
    A13 OK FETCH completed
    javax.mail.MessagingException: Unable to load BODYSTRUCTURE
         at com.sun.mail.imap.IMAPMessage.loadBODYSTRUCTURE(IMAPMessage.java:1117)
         at com.sun.mail.imap.IMAPMessage.getContentType(IMAPMessage.java:340)
    Thanks.

    Then it's a bug in the AIM IMAP server, please report it.
    I guess this deserves a FAQ entry. Here's what I'll add:
    Q: I can read messages from my IMAP server with other mail clients,
    but even though I can connect to the server using JavaMail, when I use
    JavaMail to read some messages it fails. Doesn't that mean there's a bug
    in JavaMail?
    A: No, not usually. Most other mail clients make very little
    use of the rich IMAP protocol. They use the IMAP protocol as little
    more than a variant of the POP3 protocol, typically downloading the
    entire message to the client and parsing it in the client. This allows
    them to avoid all sorts of parsing and protocol bugs in many IMAP
    servers, but of course it comes at the cost of being less efficient
    because they don't take advantage of the IMAP protocol's ability to
    fetch only the parts of the message that are needed. These server bugs
    often manifest themselves as the following exception on the client:
    javax.mail.MessagingException: Unable to load BODYSTRUCTURE
    The best approach when running into server bugs of this sort is to contact
    the vendor of the server and get them to fix their product. Contact
    [email protected] and we'll help you
    pinpoint the problem so that you can report it to the server vendor.
    If you can't get a fix from the server vendor, the following technique
    will often allow you to work around these server bugs:
        // Get the message object from the folder in the
        // usual way, for example:
        MimeMessage msg = (MimeMessage)folder.getMessage(n);
        // Use the MimeMessage copy constructor to make a copy
        // of the entire message, which will fetch the entire
        // message from the server and parse it on the client:
        MimeMessage cmsg = new MimeMessage(msg);
        // The cmsg object is disconnected from the server so
        // setFlags will have no effect (for example).  Use
        // the original msg object for such operations.  Use
        // the cmsg object to access the content of the message.

  • Unable to send email javax.mail.MessagingException: 553 Domain require

    Hello
    When sending a test message using One to One fulfillment I get the following message
    unable to send email
    javax.mail.MessagingException: 553 <UNSET>... Domain name required"
    Has anybody got this message before? how did you resolve it?
    Thank you
    Kind Regards
    Eva

    See if there is any space in the name of the email server. If yes, remove the space and stop and start the fulfillment server.
    HTH

  • How can I solve a "org.jvnet.mimepull.MIMEParsingException: Missing start boundary" when using "Page Attachments to Disk"?

    I have built a streaming MTOM enabled web service for downloading large files. I also built a client that uses that service (with MTOM and streaming feature). Everything works, when the client calls the web service directly.
    Then I have set up the OSB, so that I can call the service through the OSB. I have build a Business Service and a Proxy Service. For the Business Service, I use "XOP/MTOM Enabled", "Include Binary Data By Reference" and "Page Attachments to Disk" to prevent the OSB from loading the whole data into memory.
    If I do not use the "Page Attachments to Disk" option, the download works, but I assume everything is loaded into the OSB memory.
    When I use the "Page Attachments to Disk" option, I receive the following error message
    Exception in thread "main" com.sun.xml.ws.fault.ServerSOAPFaultException: Client received SOAP Fault from server: Couldn't create SOAP message due to exception: org.jvnet.mimepull.MIMEParsingException: Missing start boundary Please see the server log to find more detail regarding exact cause of the failure.
        at com.sun.xml.ws.fault.SOAP11Fault.getProtocolException(SOAP11Fault.java:193)
        at com.sun.xml.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:131)
        at com.sun.xml.ws.client.sei.StubHandler.readResponse(StubHandler.java:253)
        at com.sun.xml.ws.db.DatabindingImpl.deserializeResponse(DatabindingImpl.java:203)
        at com.sun.xml.ws.db.DatabindingImpl.deserializeResponse(DatabindingImpl.java:290)
        at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:119)
        at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:92)
        at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:161)
        at com.sun.proxy.$Proxy38.fileDownload(Unknown Source)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at weblogic.wsee.jaxws.spi.ClientInstanceInvocationHandler.invoke(ClientInstanceInvocationHandler.java:87)
        at com.sun.proxy.$Proxy39.fileDownload(Unknown Source)
        at largefiletransfer_osb_client.MtomClientDownload.main(MtomClientDownload.java:59)
    Why do I get this exception and how can I solve the issue?
    Additional Infos:
    OS: Windows 7 64bit
    Tool: JDeveloper BPM Suite 12.1.3.0.0
    WebService: HTTP + SOAP + MTOM + Streaming

    I have built a streaming MTOM enabled web service for downloading large files. I also built a client that uses that service (with MTOM and streaming feature). Everything works, when the client calls the web service directly.
    Then I have set up the OSB, so that I can call the service through the OSB. I have build a Business Service and a Proxy Service. For the Business Service, I use "XOP/MTOM Enabled", "Include Binary Data By Reference" and "Page Attachments to Disk" to prevent the OSB from loading the whole data into memory.
    If I do not use the "Page Attachments to Disk" option, the download works, but I assume everything is loaded into the OSB memory.
    When I use the "Page Attachments to Disk" option, I receive the following error message
    Exception in thread "main" com.sun.xml.ws.fault.ServerSOAPFaultException: Client received SOAP Fault from server: Couldn't create SOAP message due to exception: org.jvnet.mimepull.MIMEParsingException: Missing start boundary Please see the server log to find more detail regarding exact cause of the failure.
        at com.sun.xml.ws.fault.SOAP11Fault.getProtocolException(SOAP11Fault.java:193)
        at com.sun.xml.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:131)
        at com.sun.xml.ws.client.sei.StubHandler.readResponse(StubHandler.java:253)
        at com.sun.xml.ws.db.DatabindingImpl.deserializeResponse(DatabindingImpl.java:203)
        at com.sun.xml.ws.db.DatabindingImpl.deserializeResponse(DatabindingImpl.java:290)
        at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:119)
        at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:92)
        at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:161)
        at com.sun.proxy.$Proxy38.fileDownload(Unknown Source)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at weblogic.wsee.jaxws.spi.ClientInstanceInvocationHandler.invoke(ClientInstanceInvocationHandler.java:87)
        at com.sun.proxy.$Proxy39.fileDownload(Unknown Source)
        at largefiletransfer_osb_client.MtomClientDownload.main(MtomClientDownload.java:59)
    Why do I get this exception and how can I solve the issue?
    Additional Infos:
    OS: Windows 7 64bit
    Tool: JDeveloper BPM Suite 12.1.3.0.0
    WebService: HTTP + SOAP + MTOM + Streaming

  • Javax.mail.MessagingException: 505 Client was not authenticated

    Hi!,
    I got the following error:
    Exception in thread "main" javax.mail.MessagingException: 505 Client was not authenticated
    at com.sun.mail.smtp.SMTPTransport.issueCommand(SMTPTransport.java:507)
    at com.sun.mail.smtp.SMTPTransport.mailFrom(SMTPTransport.java:312)
    at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:168)
    at HelloMail.main(HelloMail.java:35)
    This is the code:
    To send an email I need authentification, and I include the mail.smtp.auth propertie and
    "message.saveChanges();
    Transport transport = session.getTransport("smtp");
    transport.connect("mail.xxx.com.mx","harriaga",passw);
    transport.sendMessage(message,message.getAllRecipients());
    transport.close();"
    Do you know if I am skip something.
    import java.util.Properties;
    import javax.mail.*;
    import javax.mail.internet.*;
    public class HelloMail {
    public static void main(String args[]) throws Exception {
    String host="mail.xxx.com.mx"; //obviously doesn't work
    String from="[email protected]"; //sender's email
    String to ="[email protected]" ; //receiver's email
    Properties props = System.getProperties();
    props.put("mail.smtp.host", host);
    props.put("mail.smtp.auth", "true");
    Session session=Session.getInstance(props,null);
    MimeMessage message = new MimeMessage(session);
    message.setFrom(new InternetAddress(from));
    message.addRecipient(Message.RecipientType.TO, new
    InternetAddress(to));
    message.setSubject(" My Test HTML email ");
    message.setText(" Here is the content ");
    message.saveChanges();
    Transport transport = session.getTransport("smtp");
    transport.connect("mail.xxx.com.mx","harriaga",passw);
    transport.sendMessage(message,message.getAllRecipients());
    transport.close();
    Thanks for all,
    HAG.

    HAG,
    you need to create a session object passing a valid authenticator. In other words,
    MyAuthenticator auth = new MyAuthenticator ();
    Session session = Session.getInstance(props, auth);where MyAuthenticator is something like
    public class MyAuthenticator extends Authenticator{
      public PasswordAuthentication getPasswordAutentication(){
        return new PasswordAuthentication( "user", "password");
    }You obviously need to replace username and password with data valid for your e-mail account.
    Hope this helps,
    gulfi

  • Javax.mail.MessagingException: 451 Error while writing spool file??

    Hi all friends,
    Can any one plz tell me why Iam getting below error when Iam trying to send mail with attachment.Iam using Java Mail API.
    javax.mail.MessagingException: 451 Error while writing spool file
    Plz tell me what are the reasons behind it.
    Regards
    Bikash

    The problem here is that the SMTP server was unable to write its spool file.
    The error is probably on the OS side of things and has nothing to do with email except that the lack of the system resource is causing email to fail.
    Have the server admin take a look at his error log to find out why the the user that smtp is running as could not write the file.

  • Javax.mail.MessagingException

    HI all,
    i am new to this area and currently i am working on email messaging application.
    in here i have set up an SMTP server and every thing, but finally it gives following exception
    javax.mail.SendFailedException: Sending failed;
    nested exception is:
         javax.mail.MessagingException: 550 Sorry, <[email protected]> is not allowed access from your location
    can you please help me to solve this problem
    thanx
    Kelum

    hi,
    thanx for your reply...i checked JavaMail faq.
    it says
    This is an error reply from your SMTP mail server. It indicates that your mail server is not configured to allow you to send mail through it.
    actually my application is a servlet. that means do we have to give any permisions to my web server to send requests to smtp server.
    do you have any idea abot this
    thanx
    Kelum

  • Javax.mail.MessagingException: 502 unimplemented (#5.5.1)

    hi,
    I am facing a problem in sending mail.
    My program is running on a linux operating system and Tomcat 5.5 .
    So my problem is that when I try to execute that program I get the
    FOLLOWING EXCEPTION.
    I am not getting why that exception is occuring.
    javax.mail.MessagingException: 502 unimplemented (#5.5.1)
    at com.sun.mail.smtp.SMTPTransport.issueCommand SMTPTransport.java:1020)
    at com.sun.mail.smtp.SMTPTransport.helo SMTPTransport.java:630)
    at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:31 1)
    at javax.mail.Service.connect(Service.java:233)
    at javax.mail.Service.connect(Service.java:134)
    at com.kaizen.Passtori.mail.SendMail.sendMailWithAttachment(SendMail.java:102)
    at com.kaizen.Passtori.UserValidation.UserUtility.sampleRegistration(UserUtility.java:680)
    at org.apache.jsp.jsp.registrationTake_jsp._jspService(org.apache.jsp.jsp.registrationTake_jsp:431)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper .java:322)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3 14)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl icationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF ilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV alve.java:213)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV alve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j ava:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j ava:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal ve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav a:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java :868)
    at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.p rocessConnection(Http11BaseProtocol.java:663)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpo int.java:527)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFol lowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP ool.java:684)
    at java.lang.Thread.run(Thread.java:595)
    If anyone knows why this exception is occuring please kindly tell me.
    Its really urgent.
    Thanks and regards
    Rakesh Sagar.

    Run the code using JavaMail's debug mode to see the conversation between your code and the server.
    I don't see the code where you're getting the Session so I can't advise you how to do that, if you don't already know.

Maybe you are looking for

  • XML error when invoking a form created by live cycle

    I have created a pdf form with Live Cycle Designer 8.0. When I open the pdf document in the firefox browser, in many times I get an error message: XML analys error. This does not happen with Internet Explorer. Is there anything I can set in Live Cycl

  • How do I stop deleted email messages from being removed?

    I have an iMac running OS X Yosemite Version 10.10.2 and an iPhone 5.  I get my email from hotmail using IMAP protocol.  When I delete an email, I want it to stay in the "deleted" folder forever or until I decided to manually remove it.  However, for

  • Ui:hyperlink action methods stopped working in IE

    Hi I'm developing my application for few months, but few days ago all ui:hyperlink action methods stopped working in IE. They are not invoked at all... No javascript errors, everything works fine in Firefox. Can anybody tell me where to look as I'm s

  • Adobe Flash on N70

    Hi guys! I have just downloaded a .SWF file onto my fone and i'm just wondering how can I open it? I have Flash Lite 2.1 installed on my phone. Opening it says that I have no movies saved on either my memory card or my phone. What folder should I sav

  • Critical Updates

    I hate when things start downloading in the background when I'm on the computer. I have turned off automatic updates on other programs so I can choose times that are convenient for me for my computer to go off and install things. Tonight a "Critical