ShizuStore

Ghost Mode

Foxlape

0.2.0 · GitHub

Download APK
Communication Android 8.0+ 5 days ago Apache-2.0
304 ShizuStore
1.4k GitHub
39 Stars
2 MB Size

More about this app

Makes the phone appear unavailable for incoming calls while keeping LTE/5G data active

Ghost Mode icon

Ghost Mode

Become unreachable for cellular calls while mobile data keeps working.

Release CI Android 8.0+ License

Русская версия · Download · Changelog

Ghost Mode makes your phone look switched off to anyone who calls — they hear "subscriber unavailable" — while LTE / 5G data keeps working. Messengers, maps and music continue as usual; only cellular calls stop reaching you. No airplane mode, no call-blocking rules.

Mode on Mode off Presets Statistics

Features

  • Works without root through Shizuku (or Sui and compatible forks); root via KernelSU, Magisk or APatch is detected automatically.
  • Exact restore. Before turning on, the app records the original network types, the values of every setting it changes and the IMS services it disables. Turning off puts back exactly that — even if you switched preset or SIM in between, or rebooted.
  • Presets for Pixel / stock Android, Samsung One UI, Xiaomi HyperOS, OnePlus, vivo / iQOO and Android 9–11, plus your own command sets with JSON import and export.
  • Dual SIM: make SIM 1, SIM 2 or both unreachable.
  • Quick Settings tile, home screen widget, launcher shortcuts.
  • Schedule (e.g. every night 23:00–07:30) and an auto turn-off timer.
  • Reboot-aware: re-applies itself after a restart when root / Sui is available, otherwise shows a notification.
  • Diagnostics per SIM, a full command log and statistics.
  • Material You design, dark and light themes, English and Russian.
  • No ads, no trackers, no analytics. No network access unless you enable the optional update check.

Requirements

Minimum Recommended
Android 8.0 (API 26) 12+ (API 31+) — telephony shell commands used by most presets
Privileges Shizuku v11+ or root —
Network LTE coverage VoLTE-capable carrier

Install

  • GitHub Releases — latest APK with SHA256SUMS.txt.
  • Obtainium — add https://github.com/Foxlape/GhostMode to get updates automatically.
  • F-Droid / IzzyOnDroid — requested in #3; the repository ships fastlane metadata for both.

Official releases are signed with this certificate (also shown in Settings → About):

SHA-256: FB:2A:E9:C4:80:BB:0F:04:55:65:F7:B5:CA:BF:01:7D:98:18:21:A9:33:F0:78:53:DD:47:12:28:D5:71:B0:50

Verify with apksigner verify --print-certs GhostMode-vX.Y.Z.apk.

Quick start

  1. Get access — one of:
    • Shizuku: download the APK from GitHub (the Download Shizuku button in the app opens the same page), start it via Wireless debugging (Android 11+) or ADB, then tap Grant access in Ghost Mode. The actively maintained fork thedjchi/Shizuku works too and can start itself after a reboot, so Ghost Mode can re-apply the mode without root.
    • Root: open Ghost Mode and allow the root request in KernelSU / Magisk / APatch.
  2. Pick a preset on the Presets tab. Start with Universal; switch to your vendor's preset if calls still get through.
  3. Tap the ghost. Check from another phone: you should hear "subscriber unavailable", while mobile data keeps working (turn Wi-Fi off to be sure).

Not working? Open Settings → Diagnostics and Command log, then open an issue with the copied log.

How it works

Presets are lists of shell commands executed through Shizuku or su. The built-in ones combine:

Lever Command Effect
IMS off cmd phone ims disable -s <slot> No VoLTE / VoWiFi registration
LTE only cmd phone set-allowed-network-types-for-users -s <slot> 01000001000000000000 No 2G/3G fallback (CSFB) for calls
IMS package pm disable-user --user 0 <ims package> For firmware that ignores the IMS command
Settings settings put global preferred_network_mode… 11, volte_vt_enabled 0 Samsung, Android 9–11
Preset For What it adds
Universal Any Android 12+ (default) Disables the IMS service the phone actually uses (detected at runtime)
Stock Android / Pixel Pixel, Motorola, Nothing, near-stock IMS off + LTE only
Xiaomi HyperOS / MIUI Xiaomi, Redmi, POCO Same as stock
Samsung One UI Galaxy S / A / Z VoLTE switches, preferred_network_mode for all subscriptions, Samsung IMS packages
OnePlus / OxygenOS OnePlus 8–13 Qualcomm / MediaTek IMS packages
vivo / iQOO OriginOS, Funtouch OS Same as OnePlus
Android 9–11 Phones without the Android 12 commands preferred_network_mode + airplane-mode toggle

When you create your own preset, these placeholders are available:

  • -s 0 — rewritten to the selected SIM slot; the command runs once per slot.
  • {{SAVED_MASK}} — the network-type mask captured before the mode was turned on.
  • {{IMS_PACKAGES}} — the IMS service packages currently used by the selected SIMs.

Original values of settings put keys and packages disabled with pm disable-user are restored automatically.

Limitations

Warning

Do not rely on Ghost Mode when you must be reachable for emergencies.

  • SMS may be delayed until the mode is off on carriers that deliver SMS over IMS.
  • Call forwarding "when unreachable" sends callers to voicemail instead.
  • Some Samsung models drop VoLTE registration only after a reboot.
  • Commands differ between firmware versions. If a preset does not work, send the diagnostics and command log.
  • Use the app only on your own device and in line with local regulations.

Building

Requirements: JDK 17+, Android SDK 35.

./gradlew assembleDebug            # app/build/outputs/apk/debug/
./gradlew testDebugUnitTest        # unit tests
./gradlew assembleRelease          # signed if keystore.properties exists, unsigned otherwise
./gradlew testDebugUnitTest -Pscreenshots --tests '*ScreenshotTest*'   # regenerate store screenshots

Release signing reads keystore.properties (storeFile, storePassword, keyAlias, keyPassword) or the KEYSTORE_FILE, KEYSTORE_PASSWORD, KEY_ALIAS, KEY_PASSWORD environment variables.

Project structure
app/src/main/java/com/ghostmode/app/
├── AppGraph.kt        process-wide objects: state, presets, shell, controller
├── data/              presets, persisted state, applied-state snapshot, statistics
├── domain/            GhostModeController (apply / restore / diagnostics), network masks
├── shell/             root and Shizuku executors, Shizuku user service
├── system/            GhostActions: entry point for every mode change
├── scheduling/        schedule and timer alarms, boot handling
├── service/           status notification and its actions
├── tile/, widget/     Quick Settings tile, home screen widget
└── ui/                Jetpack Compose UI (home, presets, settings, tools)
fastlane/metadata/     store listing texts and screenshots (F-Droid / IzzyOnDroid)

Contributing

Found commands that work on your phone? Open a preset request. For code changes see CONTRIBUTING.md. Security issues: see SECURITY.md.

License

Apache License 2.0

Close

How Shizuku is used

Can appear unreachable for calls while keeping data and run custom commands via `sh -c` through Shizuku.

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

Ghost Mode uses Shizuku to run privileged phone, package and settings shell commands that make the phone look unavailable for incoming calls while mobile data stays active.

  • Appear unavailable for calls: turning Ghost Mode on disables IMS and VoLTE calling, locks the selected SIM slots to LTE only data, disables IMS packages and refreshes carrier configuration so callers hear the subscriber as unavailable while mobile internet keeps working.
  • Restore normal calling: turning Ghost Mode off re-enables IMS, restores the previously saved allowed network mask, re-enables IMS packages and restores VoLTE and network mode settings so calls and full network modes work again.
  • Run custom shell commands: a user created preset can store shell command text typed in the preset editor for turn on, turn off and mask capture, and those commands are executed with Shizuku privileges when the preset runs.
  • Check calling status: running diagnostics queries allowed network types, IMS service state, disabled IMS packages and VoLTE and IMS settings to show whether blocking is active.

Android APIs or commands used

  • sh -c
  • cmd phone ims disable
  • cmd phone ims enable
  • cmd phone set-allowed-network-types-for-users
  • cmd phone get-allowed-network-types-for-users
  • cmd phone ims get-ims-service
  • pm disable-user
  • pm enable
  • pm list packages
  • settings put global
  • settings get
  • settings delete
  • settings list global
  • settings list secure
  • settings list system
  • am broadcast
  • cmd connectivity airplane-mode enable
  • cmd connectivity airplane-mode disable

Notable details

Custom presets run whatever shell text the user saves in them with the same Shizuku privileges as the built-in presets, so only save commands from sources you trust. Restore reuses the network mask saved before first activation, or a default full-network mask when the phone does not report one.

Close

Changelog

What's new for version 0.2.0

A rework of the core and a new interface. The main goal of this release is that turning Ghost Mode off always returns the phone to exactly the state it was in before — whatever happens in between.

Fixed

  • Restore after switching preset or SIM. Turning off used the preset and SIM mode selected at that moment. Switching them while the mode was on ran the wrong restore commands — for example, Samsung IMS packages stayed disabled. The app now records what it applied and reverts exactly that.
  • Universal preset left VoLTE broken. It disabled the detected IMS service (e.g. com.shannon.imsservice on Pixel) but never re-enabled it. Disabled packages are now tracked and re-enabled on turn-off; packages you had disabled yourself stay untouched. Diagnostics offer a one-tap repair for packages left disabled by older versions.
  • preferred_network_mode restored to 0. Samsung and Android 9–11 presets wrote 0 (GSM/WCDMA only, no LTE) on turn-off. Every settings put key is now restored to its original value (or deleted if it did not exist); the same applies to the Samsung VoLTE switches, which were always forced back on.
  • Stale network mask. The original mask was captured once and reused forever. It is now captured on every activation; an LTE-only reading is never taken as the original. Android builds that print network type names instead of a bitmask are parsed correctly instead of falling back to "all networks".
  • Reboot handling. After a reboot the app reset its state to "off", although most changes (mask, settings, disabled packages) survive a reboot — the phone could stay LTE-only or unreachable without the app knowing. Now the mode is re-applied automatically when root or Sui is available; otherwise a notification offers Re-apply or Turn off.
  • Schedule, timer, widget, notification action and shortcuts failed silently on Shizuku when the app process was not running, because the Shizuku binder arrives asynchronously. They now wait for it.
  • One shell connection for the whole app. Every component created its own Shizuku connection; when one of them unbound, it killed the service used by the others. Toggles from the tile and the app could also run at the same time. Everything now shares one connection and one lock.
  • Shizuku restarts. After Shizuku was restarted, all commands timed out until the app was restarted. A race while binding the service could also cause 10-second timeouts.
  • Root command timeout was never enforced: output was read before waiting, so a hanging command blocked forever.
  • Auto turn-off timer was not cancelled by a manual turn-off and could switch off a later session.
  • Launcher shortcuts ran again on every screen rotation, theme or language change.
  • Leaving the app during a toggle could cancel the command sequence halfway.
  • Update check never worked — the INTERNET permission was missing.
  • English UI showed Russian texts for built-in presets, log notes and import messages.
  • About showed a stale version number; duration units were not translated.
  • Diagnostics always reported mobile data as active — it is now actually checked.
  • Statistics ignored sessions crossing midnight or the 7-day boundary.
  • The chosen language was lost after a restart on Android 12 and older.
  • White flash on start in the dark theme; missing edge-to-edge layout before Android 15.
  • An unexpected error in the schedule receiver could crash the app.
  • Removed the empty "Buy me a coffee" dialog.
  • "Both SIMs" on a single-SIM phone ran every slot-specific command against the empty slot and reported errors; slots without a ready SIM card are now skipped.
  • "Add Quick Settings tile" did nothing when the tile was already added or the firmware does not support the request; the result is now shown, with manual instructions when needed.

Added

  • New interface. Three tabs (Home, Presets, Settings); a large animated switch; live status (active time, preset, SIM); auto turn-off timer on the home screen; quick tiles for SIM, schedule, statistics and diagnostics; alert cards only when something needs attention (access, reboot, exact alarms, battery, update).
  • Presets: every command is visible; placeholders {{SAVED_MASK}}, {{IMS_PACKAGES}} and -s 0 are documented in the editor.
  • Diagnostics per SIM: network types, bound IMS service, mobile data, disabled IMS packages with a repair action.
  • Statistics: 7-day chart and recent sessions.
  • Command log: full-screen, copy the whole log for bug reports.
  • Dynamic colors (Android 12+), redesigned widget, launcher icon and Quick Settings tile states.
  • Fastlane metadata for F-Droid / IzzyOnDroid (#3).

Changed

  • The update check is opt-in and off by default; without it the app never accesses the network.
  • Download Shizuku opens the latest release on GitHub instead of Google Play, which is missing or disabled on many phones.
  • The preset and SIM selection are locked while the mode is on.
  • Importing presets shows every command and requires confirmation — imported commands run with shell/root rights.
  • The Quick Settings tile asks to unlock the device first on a secure lock screen.
  • A partial failure is reported ("some commands failed") with a shortcut to the log.
  • The dependency-metadata block is no longer embedded in the APK; app data is excluded from backups and device transfer (it is device-specific modem state).
  • versionCode scheme is now major × 10000 + minor × 100 + patch (0.2.0 → 200).
🇷🇺 На русском

Полная переработка и новый дизайн. • Выключение возвращает ровно то, что было изменено, даже после смены пресета/SIM или перезагрузки • Исправлено: «Универсальный» оставлял VoLTE отключённым; preferred_network_mode восстанавливался в 3G • После перезагрузки режим применяется заново (root/Sui) или приходит уведомление • Расписание, таймер, виджет и плитка надёжно работают с Shizuku • Новый интерфейс: вкладки, диагностика по SIM, статистика за 7 дней • Проверка обновлений — только по желанию


Verify: apksigner verify --print-certs must show SHA-256 FB:2A:E9:C4:80:BB:0F:04:55:65:F7:B5:CA:BF:01:7D:98:18:21:A9:33:F0:78:53:DD:47:12:28:D5:71:B0:50; checksums are in SHA256SUMS.txt.

Full changelog: CHANGELOG.md

Close

Permissions

8 permissions requested

  • android.permission.POST_NOTIFICATIONS
  • android.permission.RECEIVE_BOOT_COMPLETED
  • android.permission.SCHEDULE_EXACT_ALARM
  • android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS
  • android.permission.ACCESS_NETWORK_STATE
  • android.permission.INTERNET
  • com.ghostmode.app.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION
  • moe.shizuku.manager.permission.API_V23
Close