Uninstallation protection using device admin permission - android

I am working on an app blocker app, user select apps, determine blocking period, when the apps are blocked I want to leave no hack to stop the blocking, the hack for now is that the user can simply uninstall the app, how to use the device admin permission to prevent uninstallation until the period is done.
I want detect when the user open my app info in the device settings trying to uninstall the app

Related

I don't want my app to get uninstalled by user for a particular period of time

is there any option in android studio to make an app so that user can not able to uninstall it for a particular period of time. For example if user granted permission of not uninstalling the app for one hour , so user can not uninstall this app for one hour
There is no way to do this, unless the app is enrolled in Android Enterprise (which is their program to allow businesses to control fleets of hardware. Using that you can install apps and prevent their uninstallation). Otherwise no, there's no way an app can prevent the user from uninstalling itself. That would basically make malware unremovable.
There is no way to prevent user to uninstall the app for particular period of time.
Thanks

Start a Windows app without user interaction just after installation on Windows Phone

I read that on android all applications, upon installation, are placed in a "stopped" state. This is the same state that the application winds up in after the user force-stops the app from the Settings application. While in this "stopped" state, the application will not run for any reason, except by a manual launch of an activity.
Is there any similar security feature implemented for Windows phones? Is it possible to start an without user interaction just after installation?

Possible to prevent uninstallation of app?

Is it possible for an Android device administrator app to disable uninstallation of itself?
The default behavior is that the app's uninstall button is grayed out, unless the user unchecks it from the list of device administrators. However, I've seen MDM apps that goes the extra step to disallow users from unchecking the app from the list of device administrators (e.g. Citrix XenMobile). How is this possible?
Thanks.

Install/uninstall an android application without user interaction in background

I am hitting web service and getting action to install and uninstall the application in background. Till now I am able to install and uninstall the application with user interaction.
I need that there should be no user interaction and the application should be installed / uninstalled as per the action in background without disturbing the user.
what you want to do is not possible
This kind of task can only be done by system apps, or apps with root access.
It is not possible via the public SDK for security reasons.

Require Pass-code to Disable Android Device Administrator

I was thinking of a security app which will have device administrator privileges. I wanted to see if it was possible to require a pass-code when the user tries to uncheck the app as an administrator under Settings->Security->Device Administrators. This would add a roadblock to not easily allow the user to uninstall the app as they would first need to remove the admin privileges from the app (for which they would need to authenticate with a password) and then they could uninstall. The idea is for parents to install a security app on their kids' phones and not have the kids uninstall it easily. Would something like this be possible without root access?
Start the pass-code activity in onDisableRequested() method (an override method of DeviceAdminReceiver)
In Android 2.3
As soon as deactivate button is clicked your activity will open.
From Android 4.x
The activity opens after around 5-10 secs when deactivate button is clicked.
So you can lock the device from onDisabled() method instead onDisableRequested().

Categories

Resources