{"id":45591502,"url":"https://github.com/erel3/lidguard","last_synced_at":"2026-04-28T07:00:41.127Z","repository":{"id":339005333,"uuid":"1159954411","full_name":"erel3/lidguard","owner":"erel3","description":"macOS laptop theft protection — Telegram alerts, location tracking, siren alarm","archived":false,"fork":false,"pushed_at":"2026-04-16T17:32:35.000Z","size":936,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-16T19:26:03.316Z","etag":null,"topics":["anti-theft","macos","menu-bar-app","security","swift","telegram"],"latest_commit_sha":null,"homepage":"https://lidguard.erel3.me","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/erel3.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"ko_fi":"erel3"}},"created_at":"2026-02-17T11:16:22.000Z","updated_at":"2026-04-16T17:32:39.000Z","dependencies_parsed_at":"2026-04-28T07:00:39.080Z","dependency_job_id":null,"html_url":"https://github.com/erel3/lidguard","commit_stats":null,"previous_names":["erel3/lidguard"],"tags_count":62,"template":false,"template_full_name":null,"purl":"pkg:github/erel3/lidguard","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/erel3%2Flidguard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/erel3%2Flidguard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/erel3%2Flidguard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/erel3%2Flidguard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/erel3","download_url":"https://codeload.github.com/erel3/lidguard/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/erel3%2Flidguard/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32370030,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T20:07:02.737Z","status":"online","status_checked_at":"2026-04-28T02:00:07.250Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["anti-theft","macos","menu-bar-app","security","swift","telegram"],"created_at":"2026-02-23T12:38:21.212Z","updated_at":"2026-04-28T07:00:41.121Z","avatar_url":"https://github.com/erel3.png","language":"Swift","funding_links":["https://ko-fi.com/erel3"],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"Resources/AppIcon.png\" width=\"128\" height=\"128\" alt=\"LidGuard icon\"\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003eLidGuard\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eLaptop theft protection for macOS\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/Erel3/lidguard/releases/latest\"\u003e\u003cimg src=\"https://img.shields.io/github/v/release/Erel3/lidguard?style=flat-square\u0026color=blue\" alt=\"Release\"\u003e\u003c/a\u003e\n  \u003cimg src=\"https://img.shields.io/badge/platform-macOS_14%2B-black?style=flat-square\" alt=\"Platform\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/swift-6.2-orange?style=flat-square\" alt=\"Swift\"\u003e\n  \u003ca href=\"LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/github/license/Erel3/lidguard?style=flat-square\" alt=\"License\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  A menu bar app that detects lid close and power disconnect events,\u003cbr\u003e\n  then tracks your device and sends alerts via Telegram.\n\u003c/p\u003e\n\n---\n\n## How It Works\n\n```\n Disabled ──arm──▶ Enabled ──trigger──▶ Theft Mode\n    ◀──disarm───    ◀──authenticate───\n                                          ├─ 📍 Location\n    arm: menu, shortcut, BT auto-arm      ├─ 📶 WiFi \u0026 IP\n    trigger: lid close, power disconnect, ├─ 🔋 Battery\n             motion (pickup/carry),       ├─ 🔔 Telegram alerts\n             power button                 ├─ 🚨 Siren alarm\n    authenticate: Touch ID, Telegram      └─ 🔒 Lock screen overlay\n    disarm: Touch ID\n```\n\nWhen theft mode activates, LidGuard sends **tracking updates every 20 seconds** with location, IP, WiFi, and battery status — all controllable remotely via Telegram.\n\n## Features\n\n🛡️ **Theft Detection** — lid close, power disconnect, power button press\\\n🤚 **Motion Detection** — pickup, tilt, and walking via Apple Silicon accelerometer (helper required)\\\n📡 **Bluetooth Auto-Arm** — arms when trusted devices (phone, watch) leave range, disarms when they return\\\n📍 **Device Tracking** — location, IP, WiFi, battery every 20s\\\n📲 **Telegram Alerts** — instant notifications with full device info\\\n🎮 **Remote Control** — enable, disable, alarm, status via Telegram bot\\\n🚨 **Alarm** — synthesized siren or system sounds at max volume (enforced, can't be silenced)\\\n😴 **Sleep Prevention** — IOKit assertions + `pmset disablesleep`\\\n🔒 **Lock Screen** — fullscreen \"STOLEN DEVICE\" overlay with owner contact info\\\n⌨️ **Global Shortcuts** — system-wide hotkeys for protection toggle and Bluetooth auto-arm toggle\\\n🔐 **Touch ID** — biometric auth for settings, disable, and quit\\\n🛑 **Shutdown Blocking** — prevents force quit and shutdown during theft mode\\\n🔄 **Auto-Update** — checks for new versions and installs with one click\\\n🚀 **Launch at Login** — start protection automatically via macOS login items\n\n## Install\n\n### Download\n\nGrab the latest `.zip` from [**Releases**](https://github.com/Erel3/lidguard/releases/latest), unzip, and move `LidGuard.app` to `/Applications`.\n\n### Build from Source\n\n```bash\ngit clone https://github.com/Erel3/lidguard.git\ncd lidguard\njust run            # build .app with -dev suffix and open\njust lint           # run swiftlint\njust install        # install to /Applications\n```\n\n## Setup\n\nOn first launch, LidGuard opens Settings automatically if no notification service is configured.\n\n### Telegram Bot\n\nLidGuard uses a Telegram bot to send alerts and receive remote commands.\n\n1. Open Telegram and message [@BotFather](https://t.me/BotFather)\n2. Send `/newbot`, pick a name and username\n3. Copy the **bot token** (looks like `123456789:ABCdefGHI...`)\n4. Send any message to your new bot, then open `https://api.telegram.org/bot\u003cTOKEN\u003e/getUpdates`\n5. Find your **chat ID** in the response JSON (`\"chat\":{\"id\":123456789}`)\n6. Paste both into LidGuard Settings → Notifications → Telegram\n\n\u003e The bot only responds to your chat ID — no one else can control it.\n\n### Settings\n\nSettings are organized into five tabs:\n\n| Tab | What's there |\n|:----|:-------------|\n| **General** | Contact name \u0026 phone (shown on lock screen overlay), launch at login, auto-update, reset |\n| **Triggers** | Lid close, power disconnect, power button, motion detection toggles; global shortcut for protection toggle |\n| **Protection** | Sleep prevention, shutdown blocking, lock screen, alarm sound \u0026 volume, auto-alarm |\n| **Bluetooth** | Trusted device picker, auto-arm toggle, lock-on-arm option, dedicated global shortcut |\n| **Notifications** | Telegram bot token \u0026 chat ID, alert and tracking toggles |\n\n\u003e Credentials are stored in macOS Keychain — never synced or uploaded.\n\n## Remote Commands\n\nControl LidGuard from anywhere via your Telegram bot:\n\n| Command | Action |\n|:--------|:-------|\n| `/stop` or `/safe` | Deactivate theft mode |\n| `/enable` | Arm protection |\n| `/disable` | Disarm protection |\n| `/status` | Device info + current state |\n| `/alarm` | Trigger siren |\n| `/stopalarm` | Stop siren |\n\nTelegram replies include context-aware button keyboards — no need to type commands manually.\n\n## Menu Bar\n\nLidGuard lives in the menu bar with a custom laptop icon:\n\n| Icon | State |\n|:-----|:------|\n| Closed eye (dark) | Disabled |\n| Open eye (green) | Protection enabled |\n| Open eye (red) | Theft mode active |\n\n**Left-click** opens the full menu. **Right-click** quick-toggles protection.\\\nHold **Option** while the menu is open to reveal hidden items (test alert, activity log).\n\n## Permissions\n\n| Permission | Why |\n|:-----------|:----|\n| **Input Monitoring** | Global keyboard shortcuts (protection + Bluetooth toggles) |\n| **Accessibility** | Power button monitoring (via helper) |\n| **Location Services** | Device tracking in theft mode |\n| **Bluetooth** | Trusted-device proximity for auto-arm |\n| **Contacts** *(optional)* | Auto-fill owner phone number from your Me card |\n\nThe app is **not sandboxed** — it needs direct access to IOKit, CoreAudio, and `pmset` for full theft protection.\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ferel3%2Flidguard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ferel3%2Flidguard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ferel3%2Flidguard/lists"}