Execution Lifecycle: 4-Stage Enforcement Mechanism
Foreground Application Detection (Accessibility Event Filter)
Limitra's accessibility engine listens for window state changes (TYPE_WINDOW_STATE_CHANGED) with sub-second latency. The active timer only ticks when a package from your configured list appears in the foreground.
Time Leak Prevention (UsageStats Reconciliation)
Under low-memory situations, Android may pause background accessibility loops. Limitra cross-validates its counter against the official UsageStatsManager API every 10 seconds.
Unskippable Lock Overlay (Window Overlay & Back Trap)
When your daily budget (e.g. 30 minutes) is exhausted, the native lock window immediately overlays the target application. Swiping back, opening recent tasks, or split-screen modes cannot bypass it.
Midnight Reset & Streak Progression
Every night at 00:00 local time, an Android AlarmManager trigger fires. Daily timers reset to zero, and your discipline streak increments if targets were honored.
Permissions and Privacy Transparency Matrix
| Permission | Why It Is Needed | Potential Abuse Risk | Limitra Safeguard |
|---|---|---|---|
| Accessibility Service | To detect when targeted apps enter the foreground and measure duration. | Potential to read on-screen text or key events (generic OS capability). | Limitra lacks internet permission entirely; it cannot exfiltrate data. Only checks package names. |
| Usage Access (UsageStats) | To cross-verify usage durations at the OS level and close tracking gaps. | Viewing how much time is spent across all apps. | Processed purely on-device only for your chosen restricted apps. |
| Display Over Other Apps (Overlay) | To present the non-dismissable lock view when limits expire. | Covering user interface elements. | Only activates when limits expire; zero ads, zero deceptive overlays. |
| Internet Access (INTERNET) | None (Not requested). | Transmitting analytics or personal habits to remote servers. | android.permission.INTERNET is completely absent from the AndroidManifest. Data transfer is technically impossible. |
Frequently Asked Technical Questions
Does Limitra drain battery?
No. It does not use continuous polling loops or power-hungry CPU wakelocks. It uses an event-driven native Kotlin architecture that only wakes when Android emits window transition events.
Does restarting the phone bypass the lock?
No. Android's BOOT_COMPLETED broadcast receiver immediately reloads state from the local SQLite database. If a limit expired earlier in the day, it stays locked until midnight.
What happens if Limitra is killed in the background?
It runs a high-priority Android Foreground Service to prevent OS termination. Protection against force-stop is safeguarded through administrative safeguards.
Does it block web content or browsers?
No. Limitra intentionally focuses strictly on Android applications (Instagram, TikTok, games, etc.). It does not monitor browser URLs, preserving total browsing privacy.