IBM Support

JR46277: CORRECT E-MAIL ATTACHEMENT HANDLING OF "READ E-MAIL VIA POP" INTEGRATION SERVICE

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • This fix addresses two problems in the "Read E-mail via POP"
    integration service:
    (1) When 2 emails are received that have attachements with the
    same name but different content, they are saved to the same
    directory. As a result, one is overriding the other one.
    (2) When a email has an attachment with a latin character, the
    attachment name is encoded with mime Q encoding (e.g.
    =?iso-8859-1?Q?TESTE_-_C=F3pia.pdf?=). This has to be decoded
    before the file is copied to the local file system.
    

Local fix

  • n/a
    

Problem summary

  • This fix addresses two problems related to the "Read E-mail via
    POP" integration
    service. When a mail is received with an attachment, the
    attachment is saved to
    the local file system. The two problems arise in the following
    areas:
    
    (1) If the attached file contains Latin characters, a
    FileNotFoundException can
        be observed and the attachment is not copied to the file
    system:
    
        java.io.FileNotFoundException:
    C:\Windows\TEMP\=?iso-8859-1?Q?TESTE_-_C=F3pia.pdf?=
        (The filename, directory name, or volume label syntax is
    incorrect.)
     at java.io.FileOutputStream.<init>(FileOutputStream.java:190)
     at java.io.FileOutputStream.<init>(FileOutputStream.java:142)
     at teamworks.Mail.getAttachments(Mail.java:626)
     at teamworks.Mail.message2Record(Mail.java:508)
     at teamworks.Mail.getMailMessages(Mail.java:401)
     at teamworks.Mail.getPOPMessages(Mail.java:291)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at
    sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessor
    Impl.java:60)
     at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethod
    AccessorImpl.java:37)
     at java.lang.reflect.Method.invoke(Method.java:611)
     at
    teamworks.connector.JavaReflectionConnector$1.execute(JavaReflec
    tionConnector.java:81)
     at
    com.lombardisoftware.server.core.ManagedAssetClassLoaderUtil.exe
    cuteWithManagedAssetClassLoader(ManagedAssetClassLoaderUtil.java
    :53)
     at
    teamworks.connector.JavaReflectionConnector.execute(JavaReflecti
    onConnector.java:49)
     at
    com.lombardisoftware.component.javaconnector.worker.JavaConnecto
    rWorker.invokeJavaMethod(JavaConnectorWorker.java:149)
     at
    com.lombardisoftware.component.javaconnector.worker.JavaConnecto
    rWorker.doJob(JavaConnectorWorker.java:82)
     at
    com.lombardisoftware.component.common.workflow.ExecutionJob.doJo
    b(ExecutionJob.java:403)
     at
    com.lombardisoftware.server.ejb.workflow.EJBWorkflowManagerBean.
    doResumeWorkflowEngine(EJBWorkflowManagerBean.java:1003)
     at
    com.lombardisoftware.server.ejb.workflow.EJBWorkflowManagerBean.
    resumeProcess(EJBWorkflowManagerBean.java:349)
     at
    com.lombardisoftware.server.ejb.workflow.EJSRemoteStatefulEJBWor
    kflowManager_82478d70.resumeProcess(Unknown Source)
     at
    com.lombardisoftware.server.ejb.workflow._EJBWorkflowManagerInte
    rface_Stub.resumeProcess(_EJBWorkflowManagerInterface_Stub.java:
    518)
     at
    com.lombardisoftware.component.common.workflow.EJBWorkflowManage
    rDelegateDefault.resumeProcess(EJBWorkflowManagerDelegateDefault
    .java:142)
     at
    com.lombardisoftware.component.common.workflow.EJBWorkflowManage
    rDelegateWebSphere$6.run(EJBWorkflowManagerDelegateWebSphere.jav
    a:84)
     at
    java.security.AccessController.doPrivileged(AccessController.jav
    a:251)
      [....]
    
    (2) If two or more mails are received that have attachments with
    the same name
        but different content, one is overriding the other one. And
    thus data is lost.
    
    Problem Summary:
    
    The code that is dealing with the "Read E-mail via POP"
    integration service was
    not dealing so far with non ASCII characters in E-mail
    attachments so that the
    code was not decoding the file name of the attachment w.r.t.
    mime-Q-encoding.
    Also the case that multiple E-mails contain an attachment with
    same name was not
    addressed. As result the two issues arised, the first in
    resulting a
    FileNotFoundException caused by invalid characters and the
    second with clashing
    file names in the location where the attachments are stored.
    

Problem conclusion

  • The fix addresses both problems as follows:
    
    (1) The file name of an attachment is decoded regarding the
    mime-Q-encoding
        before the file is copied to the local file system.
    
    (2) It is checked whether the file name of the attachment is
    already present
        on the local file system, and if so an postfix, e.g.  "_1",
    is added to the
        file name before the file is saved.
    
    
    Fix included in V8012
    

Temporary fix

Comments

APAR Information

  • APAR number

    JR46277

  • Reported component name

    BPM STANDARD

  • Reported component ID

    5725C9500

  • Reported release

    801

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2013-04-08

  • Closed date

    2013-04-30

  • Last modified date

    2013-04-30

  • APAR is sysrouted FROM one or more of the following:

    JR46176

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    BPM STANDARD

  • Fixed component ID

    5725C9500

Applicable component levels

  • R801 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSFTDH","label":"IBM Business Process Manager Standard"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"8.0.1","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
07 January 2022