On my nougat device, I have downloaded an app from the playstore, which is running great. I then extracted the apk from the installed app, and uninstalled it and again successfully, with the package installer. But the second time on app launch, it crashed. I have analysed both installation with apk analyzer. First one shows com.android.vending as installer and the application source as "Google Play". Sideload installation shows com.google.android.packageinstaller and source Unkown.
My first thought is that developer doesn't want users to install the app from unknown sources to avoid MOD app or pirate release, etc., and is checking programmatically for this parameter. I have decompiled to Java but didn't find any clue where such a condition is begin checked and exception generated.
There is a permission BIND_GET_INSTALL_REFERRER_SERVICE, maybe its causing a crash. I know how to decompile and do some smali editing and already changed verifyinstallation method to true in Smali but the app still crashes.