Security requirements on sender mail adapter

I have set up a sender mail adapter to fetch the email with attachment from MS exchange mail server. The sender mail adapter can process the attachment well and convert it to XML format. Now I have a new requirement to determine if the email comes from a particular user. I can see the FROM field in the payload "MailMessage" But I don't know how to get the value of this field. Any idea on how to set up the message mapping? Thanks in advance.

Before the sender mail adapter processes the attachment in the email, it need to determine the email is actaully from the business user not someone else on server. Cuz everyone can send email to the email address the mail adapter connects to, that is why this security issue comes from.
Basically when you fetch a email with attachment, in Sxi_monitor, you can see two field in the payload, One is MailMessage and the other is MailAttachment-1. In the MailMessage, you can see all the emial header fields, such as From, To, Subject, Content etc. I need to check if the FROM field is email address we allowed. That is basic requirements. Let me knwo if you want me to explain it further.
Edited by: Bai Li on Dec 23, 2010 6:02 AM

Similar Messages

  • Sender Mail Adapter Configuration - Process Multiple Attachments

    Dear sirs,
    I need to process several attachments at the same mail message as individual payloads.
    In default configuration of sender mail adapter only the body of message is used as payload.
    So I added PayloadSwapBean Module at Processing Sequence and it processed the attachment I set in Module Configuration.  I'm not able to process all attachments available, just one attachment is sent to PI pipeline.
    How can I process all attachments of a single mail message?
    Thank you in advance.
    Fabio Purcino

    Hi Jose,
    We are trying to implement reading multiple attachment in sender mail adapter. 
    Our Requirement is : Reading a mail having multiple .xls files. This should be read and converted to payload .
    package multiswap;
    //import com.sap.aii.adapter.xi.ms.XIMessage;
    import com.sap.aii.af.lib.mp.module.*;
    import com.sap.aii.af.lib.trace.Trace;
    import com.sap.aii.af.sdk.xi.mo.Message;
    import com.sap.aii.af.sdk.xi.mo.MessageContext;
    import com.sap.aii.af.sdk.xi.mo.xmb.XMBMessageOperator;
    import com.sap.aii.af.sdk.xi.mo.xmb.XMBPayload;
    import com.sap.aii.af.sdk.xi.util.PayloadType;
    import com.sap.aii.af.service.auditlog.Audit;
    import com.sap.aii.af.service.cpa.*;
    import com.sap.engine.interfaces.messaging.api.MessageDirection;
    import com.sap.engine.interfaces.messaging.api.MessageKey;
    import com.sap.engine.interfaces.messaging.api.Payload;
    import com.sap.engine.interfaces.messaging.api.auditlog.AuditLogStatus;
    import java.util.Hashtable;
    import java.util.Iterator;
    import java.util.Locale;
    import javax.ejb.*;
    public class MultiSwapRead
        implements SessionBean, Module
        private static final String VERSION_ID = "$Id: //tc/xpi.af/NW731EXT_07_REL/src/_af_application_ejb_module/ejbm/api/com/sap" +
    "/aii/af/app/modules/PayloadSwapBean.java#1 $"
        private static final Trace TRACE = new Trace("$Id: //tc/xpi.af/NW731EXT_07_REL/src/_af_application_ejb_module/ejbm/api/com/sap" +
    "/aii/af/app/modules/PayloadSwapBean.java#1 $"
        private static final String SIGNATURE_PROCESS = "process(ModuleContext , ModuleData)";
        protected Hashtable cachedChannels;
        protected SessionContext myContext;
        public MultiSwapRead()
            cachedChannels = new Hashtable();
        public void ejbRemove()
        public void ejbActivate()
        public void ejbPassivate()
        public void setSessionContext(SessionContext context)
            myContext = context;
        public void ejbCreate()
            throws CreateException
        public ModuleData process(ModuleContext moduleContext, ModuleData inputModuleData)
            throws ModuleException
            if(TRACE.beLogged(200))
                TRACE.entering("process(ModuleContext , ModuleData)", new Object[] {
                    moduleContext, inputModuleData
            ModuleData outputModuleData;
            Iterator itr;
            outputModuleData = inputModuleData;
            String chid = moduleContext.getChannelID();
            TRACE.infoT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, (new StringBuilder()).append("performing payload swap for channel ").append(chid).toString());
            LookupManager lman = LookupManager.getInstance();
            Channel chan = null;
      try {
      chan = (Channel)LookupManager.getInstance().getCPAObject(CPAObjectType.CHANNEL, chid);
      } catch (CPAObjectNotFoundException e1) {
      // TODO Auto-generated catch block
      e1.printStackTrace();
      } catch (CPAException e1) {
      // TODO Auto-generated catch block
      e1.printStackTrace();
            Direction direction = chan.getDirection();
            String swapkey = moduleContext.getContextData("swap.keyName");
            String keyvalue = moduleContext.getContextData("swap.keyValue");
            Object obj = inputModuleData.getPrincipalData();
            Object pivotedObj = inputModuleData.getSupplementalData("mp.pivoted");
            boolean pivoted = pivotedObj == null || !(pivotedObj instanceof Boolean) ? false : ((Boolean)pivotedObj).booleanValue();
            Message mo = null;
            if(obj instanceof com.sap.engine.interfaces.messaging.api.Message)
                mo = (Message)((com.sap.engine.interfaces.messaging.api.Message)obj);
            } else
            if(obj instanceof MessageContext)
                mo = ((MessageContext)obj).getMessage();
            } else
                TRACE.warningT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, "no message found");
            if(mo != null && XMBMessageOperator.numberOfPayloads(mo) > 0)
               // String midstr = XMBMessageOperator.getMessageId(mo).toString();
                MessageKey auditkey = new MessageKey(((com.sap.engine.interfaces.messaging.api.Message) mo).getMessageId(), com.sap.engine.interfaces.messaging.api.MessageDirection.INBOUND);
                itr = (Iterator) mo.getAttachments();
                if(swapkey != null && keyvalue != null)
                    StringBuffer textSwappingbyBuf = new StringBuffer();
                    textSwappingbyBuf.append("Swap: swapping by '").append(swapkey).append("' ? '").append(keyvalue).append("'");
                    String textSwappingby = textSwappingbyBuf.toString();
                    TRACE.infoT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, textSwappingby);
                    Audit.addAuditLogEntry(auditkey, AuditLogStatus.SUCCESS, textSwappingby);
                   while (itr.hasNext()){
                    boolean swappedp = swapPayloads(mo, swapkey, keyvalue);
                    String swappedStatus = swappedp ? "Swap: successfully swapped" : "Swap: no matching payload found";
                    Audit.addAuditLogEntry(auditkey, AuditLogStatus.SUCCESS, swappedStatus);
                } else
                    StringBuffer textInvalidBuf = new StringBuffer();
                    textInvalidBuf.append("Swap: parameter missing ");
                    if(swapkey == null)
                        textInvalidBuf.append("swap.keyName");
                    if(swapkey == null && keyvalue == null)
                        textInvalidBuf.append(" and ");
                    if(keyvalue == null)
                        textInvalidBuf.append("swap.keyValue");
                    String textInvalid = textInvalidBuf.toString();
                    TRACE.warningT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, textInvalid);
                    Audit.addAuditLogEntry(auditkey, AuditLogStatus.WARNING, textInvalid);
            } else
                String messageEmpty = "Swap: message is empty or has no payload";
                TRACE.infoT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, messageEmpty);
            return outputModuleData;
        private static boolean swapPayloads(Message mo, String swapkey, String keyvalue)
            swapkey = swapkey.toUpperCase(Locale.ENGLISH);
            keyvalue = keyvalue.toUpperCase(Locale.ENGLISH);
            int ifound = -1;
            for(int i = 0; i < XMBMessageOperator.numberOfPayloads(mo); i++)
                XMBPayload pldi = XMBMessageOperator.getPayload(mo, i);
                String pldivalue = null;
                if(swapkey.equals("PAYLOAD-DESCRIPTION"))
                    pldivalue = pldi.getPayloadDescription();
                } else
                if(swapkey.equals("PAYLOAD-NAME"))
                    pldivalue = pldi.getPayloadName();
                } else
                    pldivalue = pldi.getContentAttribute(swapkey);
                if(pldivalue == null)
                    continue;
                pldivalue = pldivalue.toUpperCase(Locale.ENGLISH);
                if(pldivalue.indexOf(keyvalue) < 0)
                    continue;
                ifound = i;
                break;
            if(ifound >= 0)
                XMBPayload pldfound = XMBMessageOperator.getPayload(mo, ifound);
                if(pldfound.getPayloadType() != PayloadType.APPLICATION)
                    XMBPayload pldapp = XMBMessageOperator.getApplicationPayload(mo);
                    if(pldapp == null)
                        pldfound.setPayloadType(PayloadType.APPLICATION);
                    } else
                        pldapp.setPayloadType(PayloadType.APPLICATION_ATTACHMENT);
                        pldfound.setPayloadType(PayloadType.APPLICATION);
                    TRACE.infoT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, "successfully swapped");
                return true;
            } else
                TRACE.warningT("process(ModuleContext , ModuleData)", ModuleCategories.SAP_MODULE_ROOT, "no matching found");
                return false;
    We couldn't go further. Please have a look in highlighted code.
    Regards,
    Kesava.

  • Sender Mail Adapter - S/MIME - How to use it?

    Hi guys,
    I am trying to figure out how to use the S/MIME security parameter of the Sender Mail Adapter in PI 7.1.
    Could anyone point me to some useful documentation/examples/blogs ?
    Or perhaps explain what steps are involved when configuring this parameter?
    We are pulling emails from an Microsoft Exchange server.
    Many thanks,
    Aldo

    First of all one sender mail adapter has to be tight with a specific sender email address.
    The email has to be decrypted as whole, you cannot decrypt parts of it.
    Then you store certificates to secure store in J2EE server and point to it in send agreement, this should be equal to HTTPS setup
    Check security guide:
    http://help.sap.com/saphelp_nwpi71/helpdata/EN/f7/c2953fc405330ee10000000a114084/frameset.htm

  • Sender Mail adapter configuration with attachment

    Hi,
    I read the below blog regarding the mail adapter
    /people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step
    I have the same requirement but the attachment file is not an XML, it is CSV file so in the module tab if I change like below is it enough?
    TRANSFORM    swap.keyValue  attachment; filename=u201DMailAttachment-1.csvu201D     (I think MailAttachment-1 is the file name, am I correct?)
    If I change like above is it ok? or any other thing is required, Could you please give me the inputs
    Thanks
    Ramesh

    I have the same requirement but the attachment file is not an XML, it is CSV file so in the module tab if I change like below is
    it enough?
    PayloadSwapBean will ensure that the input to the mapping is from the attachment.....in the blog the attachment is in XML format and hence there was no need for any conversion.....yours is however a CSV file so you need to convert it to XML first and then do the further processing.....you can either use the MessageTransformationBean as shown in this blog:
    /people/gabrielsagayaselvam.panneerselvam/blog/2009/08/31/solve-key-field-problem-using-structplain2xml-in-messagetransformationbean
    Or write your own module code for the conversion.
    Regards,
    Abhishek.

  • How to download / read  text attachment  in Sender Mail Adapter  IN XI

    Hi
    I would like to know how to download / read text attachment in sender mail Adapter & sent same attachment to target system using file adapter.
    Please help how to design / resolve this concept.
    Regards
    DSR

    I would like to know how to download / read text attachment in sender mail Adapter & sent same
    attachment to target system using file adapter.
    Take help from this blog:
    /people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step
    From the blog:
    However in most cases
    our message will not be a part of the e-mail's payload but will be sent as a file attachment.
    Can XI's mail adapter handle such scenarios? Sure it can but with a little help
    from the PayloadSwapBean adapter module
    Once your message (attachment) is read by the sender CC, you can perform the basic mapping requirement (if any) to convert the mail message fromat to the file format.....configure a receiver FILE CC and send the message...this should be the design...
    Regards,
    Abhishek.

  • Different Attachment extension(.xls,.txt) in sender mail adapter

    Hi Experts
    Is it possible to use different type of attachment extension (e.g .xls,.txt) in the sender mail adapter?
    My requirement is , the attachment in the mail adapter will be used as the main payload.So I am using PayloadSwapBean adapter module.
    Currently I am using the following module key for .xls attachment and it is working.Configuration for .xls attachment is as follows
    swap.keyName-Content-Disposition
    swap.keyname-Content-Description
    swap.keyName-Content-Type
    swap.keyValue-attachment;filename="MailAttachment-1.xls"
    swap.keyValue-MailAttachment-1
    swap.keyValue-application/vnd.ms-excel.
    Now, the attachment may be .xls or .txt file.
    Now If I want to use .txt atachment then do I need to define all these parameter again and in that case what will be my content type for .txt file.
    Your inputs required
    thanks
    Ayan

    PayloadSwapBean  will only convert the attachment as the main payload.
    Yeah for reading excel file I have a separate custom adapter module.This is not in the scope of my question..
    All I am asking , can .txt as well as .xls attachment be used in the same sender mail adapter.
    If that is possible what will be my content-type for .txt or can I remove content-type and use only content-disposition and content-description so that any type of attachment it can recognise.
    The momment I am specifying  content-type , I am making it particular  that only say .xls attachment , it will identify.
    I hope I make you clear.Inputs required
    Thanks
    Ayan

  • Purpose of advanced properties in sender mail adapter

    helo all.
    hi i just wanna know the usage of
    delete messages once read
    generate fetch report
    security parameters SMIME
    Default XI parameters
                       under sender mail adapter.
    waiting for your great response.
    bye.
    regards.
    seeta ram.

    hi,
    <i>delete messages once read</i>
    If you have selected IMAP4 as the transport protocol, you can specify here whether the messages are to be deleted on the e-mail server after reading.
    You can then specify a Folder for Deleted Messages on the server.
    <i>generate fetch report</i>
    If you want to generate a report for every adapter poll procedure, set the indicator.
    An XI message with the following information is generated:
    Interface namespace: http://sap.com/xi/XI/Mail/30
    Interface Name: FetchReport
    <i>security parameters SMIME</i>
    If you want to decrypt and validate encrypted and digitally signed e-mails in the corresponding sender agreement in the Integration Server or in the PCK, set the S/MIME indicator.
    refer this for the same and more info
    http://help.sap.com/saphelp_nw70/helpdata/en/ae/d03341771b4c0de10000000a1550b0/frameset.htm

  • Sender Mail Adapter - Incoming Mail Validation

    Hi Group,
    I am using sender mail Adapter to read the incoming mails from mail server,I have couple of questions:
    1.How we can configure adapter to read the mails from particular user.
    2.after reading the mail I am only taking subject line in to the mapping,is there any way we can validate whether the incoming
       subject line is in the right define form or not.
    3.how we can archive once after reading mail.
    4.Is there any performance affect on settling polling interval.
    Could you please help .
    Regards,
    Rajiv

    Hi,
    Refer Michael's steps on similar requirement.
    Picking mails from a particular sender using mail sender adapter
    Regards
    Krish

  • SAP PI Sender Mail Adapter error : Unexpected User response

    Hello ,
              I developed a scenario which requires Sender mail Adapter to connect a Third party system to PI, by going thro the links .
    /people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step
    and PDFs in SDN.
    When configured the sender mail adapter using POP Mail Server,faced the following error:gave the correct URL and Login credentials.
    +" exception caught during processing mail message; java.io.IOException: unexpected user response; read -ERR Command is not valid in this state."+
    Then used IMAP for the same mail server : error:
    "exception caught during processing mail message; java.io.IOException: unexpected login response; read 001F BAD Command received in Invalid state."
    Tried with another Mail server :
    "exception caught during processing mail message; java.net.ConnectException: Connection timed out".
    Can you please help, what be the cause? how to rectify it?

    Hi
    There might be an connectivity issue from PI server to mail server. Please check with your BASIS to resolve the issue.,
    Regards
    Ramg

  • Sender Mail Adapter Transport Protocol as SMTP

    Hi,
    i am Working with Mail to File Scenario..
    Done with Whole Process..
    But when i m Sending a mail from SBWP... the mail was sent Successfully sent to the receptint...
    But i m not able to see my message in SXMB_MONI ... and when i check in RWB i got the following error at Sender Communication Channel..
    Can Anyone help me to fix this Error... what might be the problem ?
    1/5/11 1:20:29 PM   mail client job stopped completly
    1/5/11 1:16:27 PM   exception caught during processing mail message; java.net.ConnectException: Connection refused: connect
    1/5/11 1:11:27 PM   exception caught during processing mail message; java.net.ConnectException: Connection refused: connect
    1/5/11 1:06:27 PM   exception caught during processing mail message; java.net.ConnectException: Connection refused: connect
      1/5/11 1:06:26 PM   mail client job scheduled

    Hi Deepthi,
    Try to restart the j2ee engine , Tcode=SMICM by SAP GUI.
    hope it works.
    Also try to chk themailserver security settings , maybe XI is not able to reach it.
    Chk whether theauthentication details for accessing mail box are correct ?
    Connection refused this error generally  occurs when XI is not able to connect .
    maybe some ports are not opened on the firewall
    check if the mail server you are trying to access is running.
    just chk the below link for Configuring the Sender Mail Adapter :-
    http://help.sap.com/saphelp_nw04/helpdata/en/23/c093409c663228e10000000a1550b0/content.htm
    Regards,
    Rohit

  • How to retrieve client certificate information from sender mail adapter

    Hi, expert:
    I have a requirement to verify the validation of coming email with digital certification. The mail is with digital certification. If the coming email is valid, I 'll get the attachemt of the mail for further processing. I have a sender mail adapter and receiver file adapter configued.
    I have already my own developed adapter module, which is configued in mail adapter. My question is how to retrieve the detailed certificate information in the adapter module developed by myself. Is it feasible?
    Thanks a lot.

    The WL-Client-Proxy cert should be the cert used on the proxy side if SSL is configured between Apache and WebLogic, so I believe that is the reason why that does not work. Basically, the problem here is that SSL is end-to-end, and the two ends of this transaction are the client and apache.
    That said, when you add the +ExportCertData option, this should record the client's SSL certificate in the vairable SSL_CLIENT_CERT.  So you should be able to use request.getAttribute("SSL_CLIENT_CERT").
    See:
    http://www.modssl.org/docs/2.8/ssl_reference.html
    If this doesn't work for you (which is possible if the WL_Proxy is doing something funny to the request), it is probably best just to dump out the entire contents of the session, and see what you have:
    for (Enumeration e = request.getAttributeNames() ; e.hasMoreElements() ; ) {
    String attr = (String)e.nextElement();
    System.out.println("ATTR = " + attr);
    System.out.println("VAL = " + request.getAttribute(attr));
    If you can't see any SSL certificate there, you will have to work out some way to pass this on manually.
    cheers,
    Trevor

  • Sender Mail Adapter consegue ler emails com HTML?

    Olá pessoal,
    Encontrei um "issue" onde estou deconfiado de uma limitação do Mail Adapter.
    Gostaria de ouvir suas opiniões.
    O cenário usa um Canal de Comunicação do tipo Mail com XIPAYLOAD em uma caixa POP3, com as seguintes variantes:
    - com ou sem Mail Package;
    - com ou sem encoding;
    - mantendo os anexos.
    Independente das variações acima o resultado do email proveniente do POP é TEXTO.
    Será que o Mail Adapter suporta mensagens HTML?
    Será que o Mail Adapter suporta multipart/alternative Content-Type?
    >Versão do PI: SAP PI 7.0 SP14
    >Mail Server: Lotus Domino 7.0.x
    []´s
    Marlo Simon.

    Marlo,
    o content type é lido a partir do MIME Header que o Cliente de email que enviou a mensagem cria.
    Em geral, mesmo colando um conteudo XML no corpo do email, se o Content Type no Header vier text, o adapter vai interpreta-lo como texto.
    Se vc sabe que o conteudo sempre vai ser um XML, existe uma maneira de forcar que o adapter sempre sete o content type como xml, atraves do parametro avançado IMail.AssumeXMLContent. Veja o help do Sender Mail Adapter:
    Advanced Mode
    To specify additional parameters in the adapter configuration, set the Advanced Mode indicator.
    Specify the additional parameter names and parameter values in the table:
    ●      For the security settings, enter values for the receiver party and receiver service here.
    ●      In the table, set the parameter IMail.AssumeXMLContent = true. The text of the message is then interpreted as XML and is copied unchanged to the mail package. If this parameter is not set, the information is copied from the content type of the MIME header. If the type specified there is application/xml or text/xml, the text of the message is copied as XML; otherwise it is copied as text.
    Abs,
    Henrique.

  • Sender Mail Adapter

    Hi,
      I am working on Sender Mail Adapter. I have done the total configuration but unable to sucess the scenarios. In the CC monitoring, it is saying that "Not Intialised" Even though i send and receive the messages from My Lotus Notes Inbox. I activated all the objects.
    I have done the following examples:
    Transport Protocal: POP3
    Message Protocal: XIALL
    Given the URL and UserId and PWD also
    Poll Intevel: 1 (Mins)
    Adapter Status: Active
    Please help to me solve this problem. I already raised the one more thread today but didn't get solutions.
    <b>Note: Do i need to do any setting from the Lotus notes(Mail Server) to diver my messages.</b>
    Thanks in Advance,
    <b>I found the problem with SMTP Address. Can i use the SMTP Url for POP3 or IMP4 protocal. Is there any thing else because if i use the Same SMTP Address, it is giving exception</b>
    Best Regards,
    Vijay
    Message was edited by:
            Gangisetty Vijaya Bhaskarudu
    Message was edited by:
            Gangisetty Vijaya Bhaskarudu

    Hi Gangisetty,
        SMTP is the out going server(for sending mails out) while POP3 is the in coming(receiving mails) server. So for a sender channel, you need to use the POP server details not SMTP.
    cheers
    danus

  • Sender Mail Adapter - forcing content as an attachement

    Hi all,
    We are using the Sender Mail Adapter to pull emails from the inboxes of some users of an exchange server.  We use the Mail Package option.
    We have noticed that the content of the emails are by-default added as attachments when there are no real attachments to the emails.  However the content is not added as an attachment when one or more attachments are present in these emails.
    Is there a way of forcing the Sender Mail Adapter to always add the content as an attachment and keeping the other attachments as well?  and of course maintain the Mail Package message type as the main payload...?
    Many thanks,
    Aldo

    Hi Stefan,
    Thanks for your reply.  I am glad to hear that I am wrong again )
    In your opinion is it possible to force the Outlook Exchange server to add the content attachment every time?  I mean by doing some configuration on it...?
    The reason why we would like to do this is because when - in the content tag of a Mail Package message - we have MIME message parts that are of content-type text/html we are having problems in decoding the html back to a readable format.
    To do this we use the apache QuotedPrintableCodec Java class.
    This works fine when the content type of the message is just text/plain but we get an exception when we try with text/html.
    The exception we get is:
    org.apache.commons.codec.DecoderException: Invalid URL encoding: not a valid digit (radix 16): 13
    I don't know if this is because of the two character sets we have in the payload (utf-8 and iso-8859-1) or if it is for other reasons...
    If you could help me figure out how to forward any HTML email to another system in a readable format it would be great.
    Thanks for your support,
    Aldo

  • Sender Mail adapter encounters MalformedInputException

    I have a sender mail adapter that processes the attached .csv file.  All is working fine.  I use FCC in module to convert the attachment and pass to an IDOC adapter for processing in SAP system.
    My problem is sometimes the sender mail CC fails with ...........
    exception caught during processing mail message[1]; com.sap.aii.af.mp.module.ModuleException: Transform: failed to execute the transformation: com.sap.aii.messaging.adapter.trans.TransformException: Error converting Message: 'sun.io.MalformedInputException'; nested exception caused by: sun.io.MalformedInputException caused by: com.sap.aii.messaging.adapter.trans.TransformException: Error converting Message: 'sun.io.MalformedInputException'; nested exception caused by: sun.io.MalformedInputException
    It only fails with some files.  At the moment when we test we FORWARD the email to our email account.  If I detach the failed email attachment and attach it to a NEW email it will then work.
    So why does it not work when forwarding emails?  But it works when I attach the same file to a new email and send?
    Other threads for this error seem to point to encoding.  But how do I know which to use.  I currently use the following in my module config:
    Transfer.ContentType     application/octet-stream;charset="ISO-8859-1"

    I have this in my configuration:
    localejbs/AF_Modules/PayloadSwapBean   on local
    TRANSFORM
    localejbs/AF_Modules/MessageTransformBean   on local
    txtxml
    TRANSFORM   swap.keyName   payload-name
    TRANSFORM   swap.keyValue   MailAttachment-1
    txtxml   Transfer.ContentType   application/octet-stream;charset="ISO-8859-1"
    txtxml   Transform.Class   com.sap.aii.messaging.adapter.Conversion
    txtxml   Transform.ContentDescription   MailAttachment-1
    txtxml   Transform.ContentDisposition   attachment;filename="MailAttachment-1.bin"
    txtxml   xml.conversionType   SimplePlain2XML
    txtxml   xml.documentName   MT_BCD_INVOICES
    txtxml   xml.documentNamespace   urn://federalmogul.com/BCDTRAVEL/FINGLOBCD001/00
    txtxml   xml.fieldNames   COST_CENTRE,EMPLOYEE_ID,PRODUCT_GROUP,COMP_CODE,BCD_ACCOUNT,INVOICE_DATE,TRAVELER_NAME,TRAVELER_FIRST_NAME,INVOICE_NO,AMOUNT_EXCL_VAT,CURRENCY1,AMOUNT_VAT,CURRENCY2,AMOUNT_DOC_CURRENCY,CURRENCY3
    txtxml   xml.fieldSeparator   ;
    txtxml   xml.lastFieldsOptional   YES
    txtxml   xml.processFieldNames  fromConfiguration
    txtxml   xml.structureTitle   RECORDSET

Maybe you are looking for