ShizuStore

Privacy Flip

dorumrr

2.4.0 · GitHub

Download APK
Privacy Android 8.0+ 2 weeks ago MIT Dhizuku
1.3k ShizuStore
17.5k GitHub
327 Stars
2 MB Size

More about this app

Manage your device privacy based on lock/unlock state

PrivacyFlip

Automatic lock/unlock privacy control for Android devices ๐Ÿ”๐Ÿ“ฑโœจ

PrivacyFlip automatically manages your Android device's privacy features based on lock/unlock state. When you lock your device, it can disable Wi-Fi, Bluetooth, mobile data, location services, NFC, and even camera/microphone sensors. When you unlock, it intelligently restores the features you want back on.

Works with Sui, Root, Dhizuku or Shizuku - Choose your preferred privilege method!

๐Ÿ“ธ Screenshots

PrivacyFlip by Doru Moraru PrivacyFlip by Doru Moraru

๐Ÿ”’ Features

Automatic Privacy Control

  • Lock Detection: Disables privacy features when the screen locks, after your lock delay (camera and microphone at once)
  • Unlock Detection: With a PIN, pattern or password, waits until you unlock it. With no secure lock, turning the screen on counts as unlocking
  • Smart Restoration: Configurable feature re-enabling on unlock. With Dhizuku, some features cannot follow this setting (see Option 3)

Privacy Features Controlled

  • ๐Ÿ“ถ Wi-Fi - Disable/enable wireless connectivity
  • ๐Ÿ“ฑ Bluetooth - Control Bluetooth radio
  • ๐Ÿ“ก Mobile data - Manage cellular data connection
  • ๐Ÿ“ Location services - Control GPS and location tracking
  • ๐Ÿ“ณ NFC - Control Near Field Communication sensor
  • ๐Ÿ“ท Camera - Disable/enable camera sensor privacy (Android 12+)
  • ๐ŸŽค Microphone - Disable/enable microphone sensor privacy (Android 12+)
  • โœˆ๏ธ Airplane Mode - Enable airplane mode on lock (opt-in, disables all radios)
  • ๐Ÿ”‹ Battery Saver - Enable battery saver mode on lock (opt-in)

Advanced Features

  • Smart Disable Options:

    • "Only if unused/not connected" - Don't disable WiFi, Bluetooth, or Location if actively in use, or Mobile Data while media is playing. The microphone is not disabled during a phone or VoIP call. While a Wi-Fi hotspot is on, Wi-Fi, mobile data and Airplane Mode are always left alone
    • "Only if not already enabled" - Prevent connection resets by not re-enabling features that are already on
    • "Only if Privacy Flip turned it on" - On unlock, turn Airplane Mode or Battery Saver off only if Privacy Flip turned it on
  • App Exemptions - If an exempt app is in front when the phone locks, nothing is disabled. Unlock always runs. Needs Usage Access

  • NFC Auto-Retry - Opt-in: if a payment or wallet app turns NFC back on right after Privacy Flip turns it off, retry disabling it

  • Keep Off While Locked - Opt-in: if Wi-Fi, Bluetooth, mobile data, location or NFC is switched back on before you unlock (for example from Quick Settings), or Airplane Mode or Battery Saver is switched off, Privacy Flip runs its lock actions again, with the same "only if" rules; camera and microphone cannot change while locked. It puts back only what Privacy Flip itself turned off, at most 5 times per lock, and only while the background service runs

  • Accessibility Service - Experimental, opt-in: an extra lock and unlock signal from the lock screen window (requires Accessibility permission). It does not make camera and microphone work with an instant power-button lock: Android refuses that once the phone is locked

  • Quick Settings tile and home screen widget - Turn protection on and off. Turning it off needs an unlocked phone

  • Advanced Detection - Multi-tier Bluetooth connection detection prevents unwanted headphone disconnects

Customizable Timing

  • Lock Delay: 0-60 seconds (granular), 2 minutes, or 5 minutes before privacy actions trigger
  • Unlock Delay: 0-60 seconds (granular), 2 minutes, or 5 minutes before features are restored
  • Instant Mode: Set delays to 0 for immediate action
  • Note: Camera and microphone ignore custom delays and trigger immediately, due to Android limitations

๐Ÿ“ฑ Requirements

Minimum: Android 8.0+ (API level 26) Camera/Microphone Features: Android 12+ (API level 31)

Choose your privilege method:

Option 1: Shizuku (No root required!)

  • Shizuku app installed and running
  • ADB privileges via USB debugging or wireless ADB
  • No root required - works with ADB-level permissions

Option 2: Root Access (Recommended for rooted devices)

  • Root access via Magisk, SuperSU, or similar
  • Best performance with UID 0 privileges

Option 3: Dhizuku (Device Owner method, 5 of 9 features)

  • Device Owner status. Android refuses to set a Device Owner on a device that already has a second user, such as a work profile
  • No root required, no ADB needed after initial setup
  • Persistent privileges - survives reboots
  • Works for, and each needs its own Android version: Camera and Microphone (Android 12+), Bluetooth (Android 9+), Location (Android 11+), NFC (Android 15+). Below Android 9 a Dhizuku setup can switch nothing at all.
  • Cannot do: WiFi, Mobile Data, Airplane Mode, Battery Saver. Dhizuku shares Device Owner rights, and Android gives a Device Owner no way to switch those. Use Root or Shizuku for them.
  • At unlock: NFC, camera and microphone always come back on. Bluetooth never does: turn it on yourself

Option 4: Sui (Best of both worlds)

  • Rooted device with Magisk installed
  • Sui Magisk module installed
  • Best user experience - no permission prompts, automatic startup

Privilege Detection Priority

  1. Sui - Magisk module providing Shizuku API with root (best UX)
  2. Root - Traditional root access via Magisk/SuperSU
  3. Dhizuku - Device Owner method (no root or ADB needed after setup)
  4. Shizuku - ADB privileges via Shizuku app

๐Ÿค Contributing

Help make this app better. No contribution is too small!

How to Contribute

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Make your changes
  4. Commit your changes (git commit -m 'Add some amazing feature')
  5. Push to the branch (git push origin feature/amazing-feature)
  6. Open a Pull Request

All contributions are valued and appreciated!

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ’– Support Development

PrivacyFlip protects your privacy. You can protect its future!

DONATE


Late nights for brighter days

Created by Doru Moraru

Close

How Shizuku is used

Can toggle WiFi, Bluetooth, data, NFC, location, camera, mic, airplane mode and battery saver via `Shizuku shell commands`.

This is an AI-assisted analysis of Shizuku-related usages in the app's public source code. It is best effort, so it may not catch every single usage.

How this app uses Shizuku

Shizuku is used to switch privacy sensitive features off on lock and back on on unlock and to read back their state.

  • Switch wireless radios: turn WiFi, Bluetooth and mobile data off on lock and back on on unlock with the svc wifi, svc bluetooth and svc data shell commands through Shizuku, with state checked with dumpsys wifi, dumpsys bluetooth_manager and dumpsys telephony.registry.
  • Switch NFC: turn NFC off on lock and back on on unlock with the svc nfc and cmd nfc shell commands through Shizuku, and on newer Android with a direct NFC service call through Shizuku, with state checked with dumpsys nfc.
  • Control location services: turn location providers off and on with the settings put secure shell commands through Shizuku, with state checked with settings get secure and dumpsys location.
  • Block camera and microphone: block and unblock camera and microphone access with the cmd sensor_privacy shell command through Shizuku, with state checked with dumpsys sensor_privacy.
  • Toggle airplane mode: turn airplane mode on and off with the cmd connectivity airplane-mode shell command through Shizuku, with state checked with settings get global airplane_mode_on.
  • Toggle battery saver: turn battery saver on and off with the cmd power set-mode and settings put global low_power shell commands through Shizuku, with state checked with dumpsys power.
  • Skip features in use: optionally leave WiFi, hotspot and location alone when they look actively used, checked with the dumpsys connectivity, dumpsys tethering and dumpsys appops shell commands through Shizuku.

Android APIs or commands used

  • svc wifi enable
  • svc wifi disable
  • svc bluetooth enable
  • svc bluetooth disable
  • svc data enable
  • svc data disable
  • svc nfc enable
  • svc nfc disable
  • cmd nfc enable
  • cmd nfc disable
  • cmd nfc enable-nfc
  • cmd nfc disable-nfc '[persist]'
  • android.nfc.INfcAdapter.enable
  • android.nfc.INfcAdapter.disable
  • cmd sensor_privacy enable 0 camera
  • cmd sensor_privacy disable 0 camera
  • cmd sensor_privacy enable 0 microphone
  • cmd sensor_privacy disable 0 microphone
  • cmd connectivity airplane-mode enable
  • cmd connectivity airplane-mode disable
  • cmd power set-mode
  • settings put secure location_mode
  • settings put secure location_providers_allowed
  • settings get secure location_mode
  • settings get secure location_providers_allowed
  • settings put global airplane_mode_on
  • settings get global airplane_mode_on
  • settings put global low_power
  • settings get global low_power
  • settings get global wifi_on
  • settings get global bluetooth_on
  • settings get global mobile_data
  • am broadcast -a android.intent.action.AIRPLANE_MODE
  • dumpsys wifi
  • dumpsys bluetooth_manager
  • dumpsys telephony.registry
  • dumpsys location
  • dumpsys nfc
  • dumpsys sensor_privacy
  • dumpsys power
  • dumpsys connectivity
  • dumpsys tethering
  • dumpsys appops

Notable details

Camera and microphone blocking uses the system sensor privacy switch and is only available on Android 12 and later, so those two options do nothing on older versions. On newer Android, NFC switching prefers a direct system NFC call through Shizuku and falls back to shell commands if the service refuses it.

Close

Changelog

What's new for version 2.4.0

  • Android 8.0 or newer is now required
  • The tile and widget now need an unlocked phone to turn protection off
  • Turning protection off while locked no longer leaves radios off after unlock
  • Root: "Check Again" now appears if you refused Magisk the first time
  • Lock detection resumes after a Shizuku restart, even with protection off
  • Debug output shows when a radio is turned back on while locked
  • "Only if not manually set" is renamed "Only if Privacy Flip turned it on"
Close

Permissions

17 permissions requested

  • android.permission.VIBRATE
  • android.permission.WAKE_LOCK
  • android.permission.FOREGROUND_SERVICE
  • android.permission.FOREGROUND_SERVICE_SPECIAL_USE
  • android.permission.RECEIVE_BOOT_COMPLETED
  • moe.shizuku.manager.permission.API_V23
  • com.rosan.dhizuku.permission.ACCESS_DHIZUKU_SERVICE
  • android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS
  • android.permission.POST_NOTIFICATIONS
  • android.permission.BIND_QUICK_SETTINGS_TILE
  • android.permission.PACKAGE_USAGE_STATS
  • android.permission.QUERY_ALL_PACKAGES
  • android.permission.BLUETOOTH
  • android.permission.BLUETOOTH_CONNECT
  • android.permission.ACCESS_NETWORK_STATE
  • io.github.dorumrr.privacyflip.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION
  • com.rosan.dhizuku.permission.API
Close

Sources

2 sources

2.4.0 GitHub ยท io.github.dorumrr.privacyflip
Selected Download
2.1.7 F-Droid · io.github.dorumrr.privacyflip ยท io.github.dorumrr.privacyflip
Download