0

Some executions of my side-loaded Outlook add-in report this permissions exception in my remote logger when they're run:

Error Elevated permission is required to call the method: 'mailbox.getCallbackTokenAsync'. 
    https://appsforoffice.microsoft.com/lib/1/hosted/outlook-win32-16.02.js:20:187671 G
    https://appsforoffice.microsoft.com/lib/1/hosted/outlook-win32-16.02.js:20:204853 We
    https://[mydomain]/AppRead/Home/Functions.js:22:9 Anonymous function
    https://appsforoffice.microsoft.com/lib/1/hosted/office.js:46:22370 Microsoft.Office.WebExtension.onReadyInternal
    https://appsforoffice.microsoft.com/lib/1/hosted/office.js:46:22842 Microsoft.Office.WebExtension.onReady
    https://[mydomain]/AppRead/Home/Functions.js:17:5 functionName
    https://appsforoffice.microsoft.com/lib/1/hosted/outlook-win32-16.02.js:20:156870 Anonymous function

The add-in manifest specifies the following permissions:

<Permissions>ReadWriteMailbox</Permissions>
<Rule xsi:type="RuleCollection" Mode="Or">
    <Rule xsi:type="ItemIs" ItemType="Message" FormType="Read"/>
</Rule>

Based on the stack traces I have, it's always outlook-win32-16.02.js and Edge browser, so it seems to be isolated to recent-ish Outlook. I've logged a decent number of these, though it's not happened frequently enough that any customer has reported it.

It definitely seems similar to this question Elevated permission is required to call the method: 'mailbox.getUserIdentityToken', but I'm not using a timer control and this is executing in the onReady(), so Office.js should be loaded.

Have I missed a new security change that's specific to that platform? Or is my understanding of either Office.onReady() or ReadWriteMailbox permissions flawed?

  • We are trying to track down some issues related to this. Any information you have that may help us repro the issue would be appreciated. What type of Add-in is this? (mail compose, mail read, appointment organizer etc.) Is it Pinnable? Version of Outlook this started happening in? If you have a local repro, perhaps any steps leading up to the repro that may be notable? – Outlook Add-ins Team - MSFT Aug 20 '21 at 22:01
  • It's a mail read add-in with no taskbar that takes the execute function action. I do not yet have a local repro, I'm only seeing it in the field atm, but I am working on that. – Dustin Brungart Aug 23 '21 at 15:25
  • Thanks for this information. Do you have any logging to determine the version of Outlook in which this issue is occurring? – Outlook Add-ins Team - MSFT Aug 29 '21 at 20:51

0 Answers0