Skip to content

About

πŸ›‘ WipeShield 擦屏卫士 β€” lock every Mac input (keyboard, trackpad, mouse, gestures, media keys) behind a pure-black shield while you clean. esc to exit. Fail-safe. 8 languages.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

4 Commits

Folders and files

Repository files navigation

WipeShield 擦屏卫士

Lock every input on your Mac so you can clean the screen and keyboard without shutting down. Open WipeShield, click Start Cleaning Mode β€” the screen goes pure black, and every keystroke, trackpad gesture, mouse move, scroll and media key is dropped at the system level. Press esc when you're done. That's it.

Download on GitHub Releases platform license

δΈ­ζ–‡θ―΄ζ˜Ž

Why

You want to wipe your MacBook's screen or keyboard, but:

  • you don't want to shut down, and with the system lock screen any key press wakes the display and types into the password field;
  • a stray key leaves garbage in the document you're editing;
  • a stray trackpad swipe triggers pinch-zoom in the screen-sharing window you left open.

WipeShield covers every display with a pure-black shield and discards all input events β€” nothing lights up, nothing gets typed, nothing leaks to any app.

How it compares

WipeShield KeyboardCleanTool pristine_screen LUCE
Blocks keyboard βœ… βœ… βœ… βœ…
Blocks mouse / trackpad / scroll / gestures βœ… βœ… ❌ cursor flies around ❌ (mouse is the unlock)
Blocks media keys (brightness / volume / backlight / playback) βœ… βœ… ❌ βœ…
Full-screen black shield βœ… ❌ screen stays on βœ… ❌
Exit single esc key hotkey combo β€” click a button
Prevents sleep / screensaver / auto-lock βœ… ❌ ❌ brightness check only
Fail-safe (never "fake locked") βœ… β€” ❌ partial
Auto-exit on lid close βœ… ❌ ❌ ❌
Launch-and-click + global hotkey βœ… βŒ₯⌘K ❌ βœ… ❌
Native, zero dependencies βœ… ~750 KB universal β€” Flutter SwiftUI
Minimum macOS 10.15 β€” unknown 14
Open source βœ… MIT ❌ βœ… βœ…

"Fail-safe" means: if the input blocker ever becomes invalid (permission revoked, system policy), WipeShield immediately ends cleaning mode and tells you, instead of leaving a black screen that looks locked but isn't.

Install

Download WipeShield-<version>-universal.zip from Releases, unzip, and drag WipeShield.app to /Applications.

  • Builds are ad-hoc signed (no Apple Developer certificate yet), so on first launch: right-click the app β†’ Open β†’ Open. After that it opens normally.
  • Requires macOS 10.15 or later. Universal binary (Apple Silicon + Intel).

First launch (one-time permission)

Blocking system input requires the Accessibility permission (every tool in this category needs it):

  1. On first launch WipeShield shows a guide β€” click Open System Settings;
  2. In System Settings β†’ Privacy & Security β†’ Accessibility, allow WipeShield;
  3. Back in the dialog, click Granted, Retry.

Usage

Action Effect
Open app β†’ Start Cleaning Mode (or βŒ₯⌘K anywhere) Screen goes black, all input blocked
Press esc Exit cleaning mode, back to the main window
Power key Native system behavior (short press = sleep dialog, hold = shutdown)
Close window (red button) App stays in the Dock; click the Dock icon to bring the window back
⌘Q Quit

While cleaning, the app holds a power assertion so the display never sleeps, the screensaver never starts, and auto-lock never kicks in. Closing the lid or putting the system to sleep automatically ends cleaning mode, so you can't get stuck behind the shield.

How it works

~1,000 lines of dependency-free Swift:

  • Input blocking β€” a session-level CGEventTap (head-insert) subscribes to all event types and applies a whitelist: esc triggers exit; the power key (NX_KEY_TYPE_POWER) passes through; everything else is dropped β€” including media keys (NX_SYSDEFINED, subtype 8), trackpad gestures, pressure and tablet events. A disabled tap is re-enabled, or cleaning mode is terminated β€” never a "fake lock".
  • Visual shield β€” one borderless, pure-black window per display at screen-saver level (1000), joining all Spaces (including full-screen apps), rebuilt automatically when displays change.
  • State keeping β€” IOPMAssertionCreateWithName(PreventUserIdleDisplaySleep) blocks sleep/screensaver; NSWorkspace.willSleep ends the session as a safety net.

Known limitations

  • Touch Bar (2016–2019 MacBook Pro): the Touch Bar is separate hardware; touching it still lights it up (the input itself is blocked).
  • Notification banners may float above the shield; enable Do Not Disturb while cleaning.
  • System-level gestures like three-finger desktop swipe are handled below the session event tap and may still work.
  • "Launch at Login" is macOS 13+ only.
  • Distributing outside Releases with your own Developer ID requires re-signing + notarization.

Privacy

No network access, no data collection, no third-party code. The entire codebase is readable in an afternoon.

Development

Requirements: Xcode Command Line Tools (xcode-select --install).

./scripts/build.sh          # build universal WipeShield.app (icon, dual-arch, lipo, sign)
  • The build script auto-deploys to /Applications and stops a running instance; set SKIP_DEPLOY=1 to skip (CI does).
  • It signs with a local certificate named WipeShield Dev if present (so the Accessibility permission survives rebuilds β€” see scripts/create_cert.sh), otherwise falls back to ad-hoc.
  • Automated-test safety net: WipeShield.app/Contents/MacOS/WipeShield --self-test <seconds> exits cleanly after N seconds; --self-test-start additionally triggers the start path once.

Releases are built by GitHub Actions (.github/workflows/release.yml) on tag push.

License

MIT

About

πŸ›‘ WipeShield 擦屏卫士 β€” lock every Mac input (keyboard, trackpad, mouse, gestures, media keys) behind a pure-black shield while you clean. esc to exit. Fail-safe. 8 languages.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages