1
  1. I've installed the SDK + emulator with both Android 11 and 8 images (separate AVDs).

The app that I'm interested in running isn't showing in the playstore but it shows just fine on my physical phone: bank app

How is it possible for it not to show on emulator playstore?.

  1. I've downloaded the apk from apk-pure and sideloaded into the emulator. The app starts (flash screen) and then crashes. Any way to decipher why?.

Thanks

Robert
  • 20,025
  • 6
  • 47
  • 66
jzz11
  • 11
  • 3
  • It is probably not in the play store because google thinks on some reason that it is incompatible with your (virtual) device. Maybe the developers of the app try to avoid its installation in an emulator, on security reasons. How about downloading the app from https://apkmirror.com and then trying to install it by adb? – peterh Jan 17 '21 at 20:46
  • Thanks - as I've mentioned in the 2nd bullet I've already tried that. – jzz11 Jan 18 '21 at 11:49

1 Answers1

3

The Play Store enabled emulator images are x86 images so they can be executed faster on an Intel/AMD CPU. Physical smartphones at the moment all use ARM CPUs (armv8a 64 bit to be precise).

If an app uses CPU specific native libraries it needs to include one version them for each CPU architecture it plans to support. Therefore if the app you want to install in the emulator only has native libraries for ARM then it can not be executed on an x86 emulator and thus will not be shown in Play Store.

Additionally when publishing an app in Play Store one can very flexible exclude or include certain device type(s).

As your app can be installed via side loading it seems to at least contain something for the x86 platform but detecting an emulator in an app and then let the app crash is simple. Besides that t!here are a lot of ways to detect an emulator. If an app developer does not want an app to be executed on an emulator it can get pretty hard and requires reverse engineering and code manipulation skills and many hours to make it run.

Especially financial apps disallow execution on an emulator as this is a common way for hackers to investigate such an app for attacking the bank, the app and their customers. Some banking apps even refuse to work on custom ROMs or rooted devices.

Robert
  • 20,025
  • 6
  • 47
  • 66
  • Thanks. No malicious intentions here. I just don't feel safe using mobile banking apps with all the Android security issues. Is there an ARM emulator which runs on x86, that is, something which fully emulates the ARM environment, something like a virtualbox? I've tried Android VB and the app still wouldn't run. – jzz11 Jan 18 '21 at 09:39
  • 1
    @jzz11 The main problem is that there are about 50 ways how to identify an emulator. And there is no emulator available that "patches" them all. Furthermore if the app performs a Google SafetyCheck it is even getting more complicated as the emulator image has to registered at Google as Google Android compliant device. Therefore as you don't know exactly what the banking app checks you can only try out every available emulator and install the banking app via side-loading and check if it works. – Robert Jan 18 '21 at 09:49
  • Thanks. Besides the Android SDK emulator, which it didn't work with, what would be the next 2nd best emulator to try?. I prefer something which runs on Linux, but I also have Windows if that's imperative. – jzz11 Jan 18 '21 at 11:52
  • @jzz11Most emulators are designed for gaming. An interesting article from the "reverse perspective" is this. It also names a few emulators. – Robert Jan 18 '21 at 11:56
  • Thanks. An interesting read. – jzz11 Jan 18 '21 at 12:00
  • A lot of 32bit, and also a lot of 64 bit ARM cpus exist. There are many x86 and amd64 androids, too, although probably more emulators/hack-machines than real devices. Probably some MIPS-based architectures also exist. Afaik if there is no machine-dependent code in an app, it can run anywhere (dalvik is platform-independent). – peterh Jan 18 '21 at 21:52
  • Apps likely have some descriptor files, somewhere in the apk, similar to the MANIFEST.MF in the Java world. Probably it describes, where the app can run. If it is so (any good Android developer can say it), then modifying this manifest in the apk makes probably some checksums/signatures invalid, but results that the app can be installed and started everywhere. – peterh Jan 18 '21 at 21:54
  • @peterh-ReinstateMonica In Android apps ther is the AndroidManifest.xml which defines some hardware requirements (e.g. required features). But other requirements are implicitly defined by the the native libraries that exist. But modifying those files make the app "uninstallable" as it invalidates the signature. Therefore you always have to resign the app with an own certificate. But in this case the app can be installed but crashes at start-up thus all what you say is not helpful as it has no effect on the crash. – Robert Jan 19 '21 at 08:26