How can I stop the user from sideloading a tablet only application on a phone?
2 回答
There are no mechanisms in the core Android OS to disable the ability to install an application based on the manifest filtration data for features like screen size, these values are only used by Google Play to determine which apps to show on which device. If a user somehow gets ahold of your APK through back channels, you cannot stop them from installing it.
However, after the application is installed, you can make use of technologies like the License Verification Library (LVL) to keep applications that have been improperly installed (i.e. not through Google Play) from being used.