OfficeDev / office-js

A repo and NPM package for Office.js, corresponding to a copy of what gets published to the official "evergreen" Office.js CDN, at https://appsforoffice.microsoft.com/lib/1/hosted/office.js.
https://learn.microsoft.com/javascript/api/overview
Other
665 stars 94 forks source link

Forwarding an email with .cer attachment, getAttachmentContentAsync( ) doesnt call the addin callback. #3947

Open mkondadg opened 8 months ago

mkondadg commented 8 months ago

Provide required information needed to triage your issue

Forwarding an email with .cer attachment, getAttachmentContentAsync( ) doesnt call the callback.

Your Environment

Windows desktop Outlook You have Microsoft Outlook Version 1.2023.1018.300 (Production). Client Version is 20231027003.07 . Windows 10 Enterprise 21H2 19044.2006

Expected behavior

Forwarding an email with .cer attachment, getAttachmentContentAsync( ) calls the addin Javascript callback.

Current behavior

Forwarding an email with .cer attachment, getAttachmentContentAsync( ) DOESNT call the addin Javascript callback.

Steps to reproduce

Send an email with .cer attachment

  1. Forward the mail from sent items to another recipient.
  2. Addin doesnt callback the javascript function.

Context

Our addin waits to collect all fields (to/cc/bcc/body/subject/multiple attachments) and the evaluate for egress. But on calling "mailboxItem.getAttachmentsAsync", the callback is called with asyncResult.value.length > 0

So addin tries to get the .cer content using currentItem.getAttachmentContentAsync(fileAttachment.id, options, currSendMailInfo.handleAttachmentsContentCallback); and waits to collect all items but Outlook doesnt make a callback to javscript function.

exextoc commented 7 months ago

Hi @mkondadg , thanks for reporting issue on attachments. .cer files are blocked attachment types. That is why OWA is not behaving as expected. Details on how to safely share blocked attachment types - https://support.microsoft.com/en-us/office/blocked-attachments-in-outlook-434752e1-02d3-4e90-9124-8b81e49a8519 . This issue has been put on our backlog. We unfortunately have no timelines to share at this point.   Internal tracking id: Office: [4191034]