AzureAD / microsoft-authentication-library-common-for-android

Common code used by both the Active Directory Authentication Library (ADAL) and the Microsoft Authentication Library (MSAL)
MIT License
41 stars 35 forks source link

getIpcStrategies should only be invoked in bg thread #2339

Closed rpdome closed 7 months ago

rpdome commented 7 months ago

OneAuthSharedFunctions.getIpcStrategies, which invokes ContentProviderStrategy.isSupportedByTargetedBroker, which invokes IPC operation, should be invoked in background thread only.

The issue is that we're invoking it in the constructor today - and that constructor is invoked in main thread.

by making this lazy-load, it would only be invoked when the ipc request is actually happening - inside a command, which sits inside a commandDispatcher.