GateShield for the security gate phone

The watchman taps a floor, a flat and Resident 1 or 2, then calls. The resident's number never appears on the gate phone, and the phone stays locked to this app, even after a restart.

Version 1.0.14 · 22.1 MBAndroid 9 or newerFor cobblewave clients

Clients receive a private download link. APK SHA-256: c3ab9a1544be60e02784d726371e32844001092637c9f23a8e2f1d2cefb8e28c

Gate screen showing floors G and 1 to 9 as big coloured tiles in two rows
Call screen showing Flat 101 · Resident 1 with no phone number

Masked calls

The call screen shows "Flat 302 · Resident 1", never the number. Use the gate SIM directly, or a network bridge (Twilio or your own server) so both sides see only a virtual number.

Locked to the gate app

Starts on boot. Home, recents, settings, notifications and other apps are blocked. Only the admin, with a PIN, can open the phone, and any restart locks it again.

Visitor log

Name, mobile, purpose, vehicle and number of people, with the resident's answer: Allowed, Denied or No answer. The admin manages buildings, floors, flats and up to 2 residents per flat.

What you need

Setup guide

1

Get the APK on your computer

GateShield is supplied to cobblewave clients. Open the private download link you received, which saves gateshield.apk. No link yet? Contact cobblewave.

To check the file, compare its SHA-256 with the one at the top of this page:

certutil -hashfile gateshield.apk SHA256

On Mac or Linux: shasum -a 256 gateshield.apk

Keep your download link private: it works for anyone who has it.
2

Prepare the gate phone

  1. Factory reset the phone: Settings › System › Reset options › Erase all data.
  2. In the setup wizard, connect to Wi-Fi but skip adding a Google account. Android only accepts a device owner on a phone with no accounts.
  3. Turn on Developer options: Settings › About phone › tap Build number 7 times.
  4. Settings › System › Developer options › turn on USB debugging.
  5. Connect the phone to the computer and tap Allow on the "Allow USB debugging?" prompt.
Menu names vary a little between phone brands. Root is not needed: GateShield uses Android's built-in device owner mode. Screenshots of every permission step: Give GateShield full access.
3

Install and make GateShield the device owner

Open a terminal in the folder where you saved the file and run:

adb devices
adb install gateshield.apk
adb shell dpm set-device-owner com.gatecall.intercom/.kiosk.AdminReceiver

The last line must print Success: Device owner set to package com.gatecall.intercom. If it says there are accounts on the device, see Help.

Updating an existing gate phone? Just run adb install -r gateshield.apk. Settings, flats and the visitor log are kept.

Device owner is what lets GateShield block home, recents and settings, start on boot and re-lock after every restart. Without it Android only offers screen pinning, which anyone can exit.
4

Open GateShield

Open GateShield from the app list. It locks the phone straight away and shows the gate screen. From now on it opens by itself after every restart.

Until the admin adds buildings and flats, the gate screen says "No buildings set up yet".

Gate screen
Gate screen, here with floors added
5

Log in as admin and set your PIN

  1. Tap the name at the top of the gate screen ("Main Gate" until you change it) 7 times quickly. There is no visible admin button, so the watchman won't find it.
  2. Enter the starting PIN 1234. The login also shows who built the app: cobblewave.
  3. GateShield makes you choose a new 4 to 8 digit PIN. 1234 is not accepted again.
  4. At the top of the Admin menu, Name on top of gate screen: tap Edit to type your apartment or building name (for example "Sunrise Apartments"), or tap one of your building names to use it. It shows centred and bold at the top of the gate screen.
Admin login dialog
Admin login after 7 taps
Set a new admin PIN dialog
New PIN is required
Admin menu with the name on top of the gate screen and an Edit button
Admin menu: edit the name
6

Make it the default phone app

  1. Admin › Device & lock › Set as default phone app.
  2. Android asks "Set GateShield as your default phone app?". Choose GateShield and tap Set as default. The gate stays locked while it asks.

All three checks should turn green within a couple of seconds: device owner, default phone app, gate lock active. No restart is needed.

This step is what hides numbers: until it is done, GateShield refuses SIM calls ("Number masking is off") instead of showing a number.

Device and lock screen with three ticks
All three ticks green
7

Add buildings and floors

  1. Admin › Buildings, floors, flats & residents › Add building (for example "Block A").
  2. Tap the building, then Add range to create many floors at once, for example 0 to 10. Floor 0 is shown as "G".
  3. Use the pencil to rename a floor and the bin to delete it. Deleting a floor removes its flats and residents.
Add building dialog
Add building
Add a range of floors dialog
Add a range of floors
Floors G, 1, 2 and 3
Floors created
8

Add flats and residents

  1. Tap a floor, then Add several: first flat number (it suggests 101 for floor 1) and how many.
  2. Tap a flat and Add resident: name and mobile number. Up to 2 residents per flat, shown to the watchman only as Resident 1 and Resident 2.

Only the admin ever sees the numbers.

Add several flats dialog
Add several flats
Add resident dialog
Add resident
Flat 101 with Resident 1 Ravi and Resident 2 Priya
Two residents saved
9

Choose how calls are made

Admin › Calling & masking. Pick one mode and save. Here you can also rename the gate, choose whether the watchman sees residents' names, and switch on Ask for visitor details on the call screen (off by default).

ModeHow it worksResident sees
Direct SIM
default, no internet
The gate phone dials the resident. GateShield's own call screen hides the number.The gate SIM number
TwilioTwilio rings the gate phone from a virtual number and joins the resident. GateShield answers it automatically.The virtual number
Your bridge serverGateShield sends a request to your server, which connects the call through any provider (Exotel, Knowlarity, Plivo and others).The virtual number
10

Daily use by the watchman

  1. Floors 0–9 are big coloured numbers in two rows at the top. Tap the floor: its flats appear right below on the same page. Tap another floor and the flats change. Each floor keeps its own colour (Google blue, red, yellow, green).
  2. Tap the flat. Each flat shows one person symbol per resident; a faded flat has no resident.
  3. The flat is shown big at the top in its floor's colour, so the right one is called. Below it are two big boxes side by side: green 1 CALL for Resident 1 and blue 2 CALL for Resident 2. Made for watchmen who are older or cannot read well: numbers, colours and symbols, no reading needed.
  4. If the admin switched on visitor details, tap Add (or Edit) to enter name, mobile, purpose, vehicle and persons, then Done. A one-line summary stays on screen.
  5. Tap box 1 or 2. The call screen shows only the flat and resident.
  6. When the call ends, a pop-up asks "Did the resident allow the visitor?": tap the big green ✓ Allowed, red ✗ Not allowed or grey ☎ No answer. Colours and symbols make it clear without reading. The visit is saved to the Visitor log.
  7. The Visitor log shows each visit with the same big green ✓ / red ✗ / grey ☎ circle and the flat number. Tap a visit to change the answer later, for example when a resident calls back.
  8. The strip at the top shows the time, date, SIM signal, network and battery. Double-tap it to lock the screen: it goes dark with a big clock. Double-tap anywhere to wake. Calls and alarms wake it automatically. It also locks by itself after 3 minutes without a touch (admin can change this in Device & lock: Off, 1, 3, 5 or 10 minutes).
  9. The Visitor log button is always at the bottom. Notes (shift handover notes), Alarm (with Snooze and Stop) and Calculator are off by default to keep the screen simple; the admin turns each on under Admin → Watchman tools on the gate screen. Other apps stay blocked, so these are built in.
Floors 0 to 9 in two rows of coloured tiles
Floors 0–9 in two rows
Floor 6 chosen, its flats shown below on the same page
Tap floor: flats below
Flat 102 shown big with green box 1 CALL and blue box 2 CALL side by side
Call boxes 1 and 2 side by side
Visitor details card with Edit button above the call buttons
With visitor details on
Masked call screen
Masked call: no number
Pop-up after the call: Allowed, Not allowed, No answer
Pop-up after the call
Visitor log with green tick, red cross and grey phone circles
Visitor log: ✓ allowed, ✗ not allowed
11

When a resident calls the gate

Calls from a saved resident show the same masked name, for example "Flat 101 · Resident 2". The watchman answers with the green button. Callers who aren't residents are shown with their number.

Incoming call from Flat 101 Resident 2
Incoming, also masked
12

Full phone access for the admin

  1. Admin › Device & lock › Open device and confirm. The lock is released and the phone works normally.
  2. When you're done, open GateShield and tap Lock now, or just restart the phone. It always comes back locked.

To remove GateShield: Device & lock › Remove device owner, then uninstall it like any app.

Open device for admin confirmation
Open device
13

Back up and restore

  1. Admin › Backup & restore › Back up now.
  2. Choose a backup password (at least 6 characters) and type it twice. Write it down. It is never stored, and without it nobody can open the backup, not even cobblewave.
  3. Tap Choose where to save. Android's file picker opens (the gate stays locked), with Downloads selected. Tap Save.
  4. Copy the .gsb file to a PC, pen drive or Google Drive. A backup kept only on the gate phone is lost with the phone.

The backup holds buildings, floors, flats, residents and their numbers, the visitor log, notes, alarms and settings, encrypted with AES-256. The admin PIN is not included.

Restore (same phone, or a new one set up with steps 1–6): Restore from a backup › pick the file › enter its password › check the summary › Restore. Everything on the phone is replaced in one go: if anything fails, nothing changes.

Backup and restore screen with Back up now and Restore from a backup
Backup & restore
Restore confirmation listing buildings, floors, flats and residents in the backup
Check, then Restore

Give GateShield full access, step by step

Every permission GateShield needs, in order, with the screens you will see. Screens are from an Android 16 phone; menu names differ a little between brands.

A

Turn on Developer options

  1. Open Settings › About phone.
  2. Tap Build number 7 times. Android counts down ("You are now 3 steps away from being a developer") and then says "You are now a developer".
  3. If the phone has a screen lock, enter it when asked.
About phone with the Build number row and the developer countdown message
Tap Build number 7 times
B

Turn on USB debugging

  1. Open Settings › System › Developer options.
  2. Scroll to Debugging and switch on USB debugging.
  3. Connect the phone to the computer. On the phone, tap Allow on "Allow USB debugging?" (tick "Always allow from this computer").
Developer options with USB debugging switched on
USB debugging on
C

Give device owner from the computer

This is the "full access" switch: kiosk lock, start on boot, blocking other apps and settings. Run in PowerShell, in the folder with adb and gateshield.apk:

.\adb install gateshield.apk
.\adb shell dpm set-device-owner com.gatecall.intercom/.kiosk.AdminReceiver

You should see:

Performing Streamed Install
Success
Success: Device owner set to package com.gatecall.intercom/.kiosk.AdminReceiver
Active admin set to component com.gatecall.intercom/.kiosk.AdminReceiver

"Already some accounts on the device"? Remove all accounts (or factory reset and skip Google sign-in), wait a minute, run the second line again.

Device owner works only on a phone with no accounts, and only one app can be device owner. Root is never needed.
D

Phone permissions: granted automatically

As device owner, GateShield gives itself the Phone permission (make calls, pick the SIM). There is no "Allow" box to tap.

To check: Settings › Apps › GateShield › Permissions shows Phone: Allowed and "No permissions denied".

Alarms, vibration, network status and start-on-boot need no prompt either; Android grants them at install.

App permissions for GateShield: Phone allowed, no permissions denied
Phone: Allowed
E

Make GateShield the default phone app

  1. Open GateShield, tap the name at the top 7 times, enter your admin PIN.
  2. Device & lock › Set as default phone app.
  3. Android asks "Set GateShield as your default phone app?". Select GateShield, then tap Set as default. The gate stays locked while it asks.

Android's dialog lists what any phone app may use (camera, contacts, SMS and so on). GateShield only asks for Phone, as step D shows.

From the computer instead: .\adb shell cmd role add-role-holder android.app.role.DIALER com.gatecall.intercom

Android dialog: Set GateShield as your default phone app
Android asks
GateShield selected, Set as default enabled
Select GateShield, Set as default
F

Check: three green ticks

Device & lock should show Device owner, Default phone app and Gate lock active now all ticked. They update by themselves within a couple of seconds; no restart needed.

Here you also choose Lock screen when idle (Off, 1, 3, 5 or 10 minutes) and can block USB debugging while locked.

Device and lock screen with three green ticks
All three ticked
G

Full phone access for the admin, when needed

  1. Device & lock › Open device, then confirm. All apps and settings work normally.
  2. To lock again: open GateShield and tap Lock now, or restart the phone. It always comes back locked.
Open device for admin confirmation
Open device for admin

Permissions and rooting

Rooting: not needed, and not recommended

GateShield does not need a rooted phone. The full lock comes from Android's own device owner mode, the same system companies use to manage work phones. It is switched on once from a computer with one adb command (step 3).

  • Don't root the gate phone. Root lets anyone with a USB cable or a root app switch the lock off, read the residents' numbers and change the app.
  • Rooting usually wipes the phone, can void its warranty and stops normal security updates.
  • Already rooted? GateShield still installs and works, but the lock is only as strong as the root access around it. For a secure gate phone, flash the maker's stock firmware first.
  • "Full access" for the society is the admin PIN: Device & lock › Open device. Root is never involved.
Uninstalling: Admin › Device & lock › Remove device owner, then uninstall normally. No factory reset needed.

App permissions

PermissionWhy GateShield needs itHow it's granted
Make phone calls
CALL_PHONE
Dial Resident 1 or 2 from the gate SIM (Direct SIM mode).Automatically, by device owner
Phone status
READ_PHONE_STATE
Pick the SIM on dual-SIM phones, so no "choose SIM" box appears.Automatically, by device owner
Default phone app
dialer role
Show GateShield's own call screen ("Flat 101 · Resident 1") instead of the dialer, which would show the number. Calls are refused until it is set.Once, in Device & lock (step 6)
Device owner
device admin
Kiosk lock, start on boot, block home, recents, settings and the status bar, re-lock after restart.Once, by the adb command
Run at startup
RECEIVE_BOOT_COMPLETED
Open the gate screen and re-lock after every restart.At install
Network status
ACCESS_NETWORK_STATE
Show Wi-Fi, Mobile or Offline in the app's top status strip, since Android's own status bar is hidden while locked. Time, date, SIM signal and battery need no permission.At install
Alarms
USE_EXACT_ALARM
Ring the watchman's alarms at the exact minute set, even when the phone is idle.At install
Vibration
VIBRATE
Vibrate while an alarm rings.At install
Internet
INTERNET
Only for the network masking modes (Twilio or your own server). Direct SIM mode works offline.At install

What device owner switches on

  • Only GateShield can run (lock task mode); the power menu still works so the phone can be restarted.
  • GateShield is the home screen; the lock screen, status bar and notifications are turned off.
  • Blocked: safe mode, factory reset from Settings, adding users, SD cards and USB storage. USB debugging can also be blocked (optional switch).
  • The screen stays on while charging.

How resident data is protected

  • Numbers encrypted on the phone: residents' and visitors' mobile numbers, and the Twilio / bridge keys, are stored encrypted with a key kept in the phone's secure hardware (Android Keystore). A copy of the app's files shows no numbers.
  • Backups encrypted: AES-256 with a key made from your backup password. A wrong password is refused.
  • PIN lockout: after 5 wrong admin PINs, login waits 30 seconds, doubling with each further wrong PIN (up to 15 minutes).
  • Admin closes itself when the screen locks (double-tap or idle), so nobody walks into an open admin session.
  • No screenshots or screen recording of admin screens.
  • The watchman never sees a number; Android's own phone backup is switched off for GateShield.

Never used

Contacts, call history, SMS, location, camera, microphone recording, photos and files, and Google accounts. There are no ads and no analytics. Buildings, residents and the visitor log are stored only on the gate phone. In a network mode, the resident's number goes only to the call service you choose, to connect the call.

Help

"Not allowed to set the device owner because there are already some accounts"

Remove every account in Settings › Passwords & accounts, or factory reset again and skip the Google account. On a freshly reset phone, wait a minute after setup finishes and run the command again.

"Call failed: Number masking is off"

GateShield is not the default phone app yet, so it won't dial (that would show the number). Admin › Device & lock › Set as default phone app and choose GateShield. Version 1.0.2 does this without a restart; on 1.0.1 or older, update with adb install -r gateshield.apk.

Calls only worked after restarting the phone

Fixed in 1.0.2. Older versions skipped part of the setup if GateShield was opened before the device-owner command. Update with adb install -r gateshield.apk; no restart or reset needed.

A "choose SIM" question appears on dual-SIM phones

GateShield picks the first SIM automatically. To use the other SIM, set it as the default for calls in Android settings while the device is opened by the admin.

Forgot the admin PIN

The PIN can't be recovered. Factory reset the phone and repeat this guide from step 2.

Network mode says the call failed

Check the internet connection, the gate phone's own number and the virtual number in Calling & masking. For Twilio, check the Account SID and Auth Token.

The browser warns that the APK may be harmful

Browsers warn about every APK that doesn't come from the Play Store. Check the SHA-256 against the one at the top of this page, then keep the file.