Merge "Guard isProviderPackage with permission"