Skip to content

capacitor-community/tap-jacking


Tap Jacking

@capacitor-community/tap-jacking

Tap Jacking is a technique where a malicious app tricks the user into clicking a security-relevant control (confirmation button etc.) by obscuring the UI with an overlay or by other means.

This plugin prevents tap jacking by calling setFilterTouchesWhenObscured(true) (Android 11 and below) or setHideOverlayWindows (Android 12+) as described in the Android Developer Documentation.

On iOS and web this call does nothing.

Install

npm install @capacitor-community/tap-jacking
npx cap sync

Usage

import { TapJacking } from '@capacitor-community/tap-jacking';
...
await TapJacking.preventOverlays();

API

preventOverlays()

preventOverlays() => Promise<void>

enableOverlays()

enableOverlays() => Promise<void>

About

Capacitor plugin to prevent tap jacking on Android devices

Topics

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •