Security
Authentication, launcher, lock task mode/pinning, Device Owner, Profile Owner, DPC and managed configurations
1. Settings Authentication Session
The settings page is locked using the device's biometrics or credentials (if set).
Once unlocked, it will not prompt for login for the next 5 minutes. This persisting session duration reset each time a settings page is accessed.
When the device is locked, or the app is exited or placed in the background, the authentication session will be revoked.
2. Default Launcher
By setting Webview Kiosk as the default launcher (home screen) app, any attempts to leave the app will simply re-open it at the configured home page.
To do this, use the Launcher option in Setting Actions.
3. App Pinning / Lock Task Mode
3.1. User-owned Devices
On regular user-owned devices, to improve security, enable Ask for PIN/pattern/password before unpinning in your device settings.
On some devices, the setting could be Lock device when unpinning or equivalent.
This setting is typically accessible by first finding App Pinning, then clicking into the item (instead of the toggle/switch) to see additional options.
This will ensure that users cannot unpin (and thus unlock) the kiosk view without the device first locking itself and requiring your biometrics or credentials.
For more on Android App Pinning (screen pinning), refer to:
When in screen pinning mode, you will not be able to launch other applications.
3.2. Device Policy Controller
If you have access to your Device Policy Controller (DPC), or your MDM/EMM has provided an interface to do so, it is recommended that you add Webview Kiosk to the allowlist of apps for lock task packages.
This has the benefits of:
- removing warnings and instructions when you "lock" the app, as it is no longer screen pinning like in user-owned devices
- stopping users from triggering the "unpin" action using gestures or holding the back and overview button, thus removing the side-effect of the device getting locked when users attempt to "unpin"
In Lock Task Mode, the in-app unlock methods are configurable and can be disabled. An eligible DPC can also end Lock Task by updating its policy. The in-app methods are:
- Opening the Kiosk Control Panel by either
- holding the back button
- tapping the screen 10 times in quick succession at your configured region (e.g. Top Left quadrant)
- Adding a custom unlock shortcut (requires a physical keyboard or
a method of that sending key combinations, e.g.
CTRL+1)
For further details, see the MDM/EMM/DPC activation guide.
3.3. Device Owner Mode
When set as the device owner, Webview Kiosk can act as a DPC and automatically adds itself to the allowlist for lock task packages. It is also possible for Webview Kiosk to add other applications in settings, thus allowing it to launch other apps in Lock Task Mode (kiosk).
3.4. Profile Owner (Main User)
Profile Owner manages kiosk settings in your personal user.
The main advantage over device owner is that you can also have a Work Profile.
3.5. Capabilities and Limits
| Operation | Device Owner | Eligible full-user Profile Owner | Ordinary work-profile Profile Owner |
|---|---|---|---|
| Choose Lock Task apps | Yes | Android 9+ without a Device Owner, or Android 8+ for affiliated secondary users | Only with eligible affiliation/policy access |
| Configure Lock Task features | Android 9+ | Android 9+ with policy access | Unavailable in ordinary unaffiliated work profiles |
| Lock Task Mode | App must be allowlisted | App must be allowlisted | Ownership alone is insufficient |
| Transfer native ownership | Android 9+ | Android 9+, retaining owner scope | Android 9+, retaining work-profile scope |
| Deactivate owner | Testing only | Android 7+ on full users, testing only | Not available |
3.6. Dhizuku Shared Ownership
Dhizuku can be used to share Device Owner or Profile Owner permissions between multiple applications. For example, the permission could be shared with both Webview Kiosk and OwnDroid simultaneously.
See Dhizuku setup for further details.
4. Managed Configurations (App Restrictions)
With an eligible Device Owner or Profile Owner in the same user, you can use managed configurations to restrict and remotely modify Webview Kiosk settings through your MDM/EMM.
It is also possible to set app restrictions using OwnDroid or Test DPC.
For a list of available settings, refer to ./app/src/main/res/xml/app_restrictions.xml.
Below are instructions for a few popular MDM/EMM providers:
At the time of writing, Headwind MDM (an open-source platform to manage android device) does not yet support managed configurations, but this is on their roadmap for the future.
Last updated on