A DO-IT-YOURSELF FINGERPRINT UNLOCK FOR A MAC, BUILT TO AVOID APPLE'S 149 DOLLAR TOUCH ID KEYBOARD

A ZW101 sensor and an ESP32 in a 3D printed case authenticate your Mac for ten dollars, and the creator tells you when Apple's is worth the hundred and thirty nine more.

by Zimeng Xiong

FULL CAD BOM FIRMWARE DOCS

Open-hardwareAutomation

difficulty
●●●○○
time
a weekend
license
MIT
repo
repo ACTIVE778 stars

WHAT YOU’LL NEED

  • 3D printer + filamentprintable parts — files are in the repo
  • Electronic partsfull list with part numbers in the repo BOM
  • Dev board / microcontrollerruns the project firmware

Partner

Run your scrapers in the cloudThis build needs data collection that runs 24/7. Apify's free plan includes $5 in credits every month — no card needed.Try Apify free
1

COMPAREE VERDICT

tinyTouch is a straightforward weekend build if you have soldered before and are comfortable running commands in a Mac terminal. The appeal is not just saving money against Apple's 149 dollar Magic Keyboard with Touch ID—it is seeing how the authentication works, and the author's honesty about where it does not match Apple's. The hardware is a Seeed XIAO ESP32-S3 wired to a ZW101 capacitive fingerprint sensor inside a small 3D printed enclosure that presents itself to the Mac as a USB keyboard. In HID mode your real password stays encrypted on the Mac, the board holds only a 32-byte pairing key, and when a finger is recognised the two run an encrypted exchange with a random nonce so a captured message cannot be replayed. Secure Boot and Flash Encryption on the ESP32-S3 mean pulling the chip does not reveal the key. A second mode uses PIV and PAM for stronger protection against a keylogger, but it does not cover Keychain or general settings unlocks. What makes this project unusual is that the creator documents the weak spot in his own table: the sensor talks to the board over unauthenticated UART, which means someone with access to your desk can spoof it. He suggests potting the case in black epoxy as a basic countermeasure and a better sensor as the real fix, and he writes plainly that if you handle sensitive or classified material, or a company device where a leak would land on you, Apple's keyboard is excellent value and worth the added security. The one thing most likely to go wrong is buying the wrong fingerprint sensor—several sellers list ZW101 modules that use UART but have incompatible command sets, and the firmware will not recognise a finger. Check the datasheet before ordering.

NOT IN THE REPO

  • MIT licence, permits commercial use without restriction.
  • 3D printed enclosure files for the sensor and ESP32 are in the repo (STL).
  • Complete firmware for ESP32-S3 and macOS helper app are present, with setup instructions.
  • Author documents the major weakness himself: unauthenticated UART between sensor and board can be spoofed.
  • HID mode keeps passwords on the Mac encrypted; PIV/PAM mode uses challenge-response but does not cover Keychain.
  • No PCB Gerbers because this is a direct wire build between the sensor module and the XIAO board.

Can I build this?

PrintSmall enclosure for sensor and ESP32 board (STL files in repo)
BuySeeed XIAO ESP32-S3, ZW101 capacitive fingerprint sensor (verify UART command set in datasheet), short USB-C cable, wire for four connections
ToolsSoldering iron, 3D printer or access to one, macOS machine (this project is Mac-only), PlatformIO or Arduino IDE, terminal comfort for helper app install
SkillsBasic soldering, command-line comfort on macOS, willingness to troubleshoot USB enumeration if the Mac does not recognise the board immediately
TimeFour to six hours across a weekend: printing the case, soldering four wires, flashing the ESP32, pairing with the helper app, and enrolling fingerprints
CostUnder 20 dollars for the XIAO and sensor if you have wire and filament already; shipping can add ten more depending on where you order from
SafetyNo mains voltage, no high-energy cells. The security trade-off is real: unauthenticated UART means physical access to the case allows spoofing. Do not use this for machines where unauthorised access has regulatory or employment consequences.

Build at your own risk. Projects involve tools, electronics and sometimes mains voltage — follow the creator’s safety notes.

A desktop 3D printer that prints in full colorPartner · Kickstarter
A desktop 3D printer that prints in full color

HeyGears G1: 10M+ colors and transparent parts in one print, plus UV printing on flat objects. Figures, parts and labels — no painting.

See how it prints

Gallery

Start here

Navigation into the creator’s own docs — we don’t rewrite the guide, we route you to the source.

  1. 1.Check the ZW101 datasheet before buying(Several modules share the name but use incompatible UART command sets; the firmware expects specific responses.)
  2. 2.Print the enclosure (STL files are in the hardware folder, designed for the XIAO and ZW101 form factor.)
  3. 3.Wire sensor to XIAO (Four connections: VCC, GND, TX, RX. Pin map is in the README.)
  4. 4.Flash the ESP32 firmware (PlatformIO or Arduino IDE; enable Secure Boot and Flash Encryption in menuconfig for production use.)
  5. 5.Install macOS helper app and pair (Helper runs in the background, handles pairing key storage and password encryption. Terminal commands in the README.)
  6. 6.Enroll fingerprints and test (Use the helper to enroll; HID mode works immediately, PIV/PAM mode requires additional PAM configuration.)

Resources

Documentation, files and community threads for this build — we link straight to the original sources and never rehost the creator’s files.

KNOWN ISSUES

  • Buying a ZW101 module with an incompatible UART command set is the most common dead end—verify the datasheet matches before ordering, or you will spend a weekend debugging why the sensor never responds.
  • The unauthenticated UART link between sensor and board means someone with physical access to your case can spoof it; if you work with sensitive data or company machines, this is not a theoretical risk.
  • PIV/PAM mode is stronger against keyloggers but does not unlock Keychain or settings panels—HID mode covers more use cases but stores the password encrypted on the Mac, not on a challenge-response token.
  • Secure Boot and Flash Encryption must be enabled manually in the ESP32 menuconfig before the final flash; skipping this step means the pairing key can be dumped from the chip.
  • If the Mac does not enumerate the XIAO as a keyboard after first plug, check the USB-C cable (some are charge-only) and verify the firmware uploaded without errors in the PlatformIO or Arduino monitor.
  • The project is Mac-only; there is no Windows or Linux helper and adapting it would require rewriting the password encryption and PAM integration from scratch.

How does this compare to Apple's Magic Keyboard with Touch ID in terms of security?

Apple's uses a Secure Enclave and authenticated communication between sensor and controller, so the entire chain is cryptographically verified. tinyTouch uses encrypted storage and nonce-based replay protection, but the sensor-to-board link over UART is unauthenticated, which the author documents as the major weakness. For sensitive or company machines, he recommends buying Apple's.

Can I use this with a Windows or Linux machine?

No. The helper app and password encryption are written for macOS only. Porting would require rewriting the PAM integration and Keychain interface, which is not a weekend job.

What happens if someone steals the device?

If Secure Boot and Flash Encryption are enabled, dumping the chip does not reveal the pairing key. But the encrypted password is still on your Mac, so if they also have access to your machine they can pair a new device by enrolling a new fingerprint. Physical security of both matters.

Do I need to solder surface-mount components?

No. The XIAO ESP32-S3 and ZW101 are modules with through-hole or castellated pads, so you are soldering four wires between them. Basic through-hole soldering skill is enough.

How long does a fingerprint recognition take?

Under a second in the demo clips. The sensor responds in a few hundred milliseconds, then the encrypted exchange and password typing add another few hundred.

Community builds

No community builds yet — be the first, we feature the best ones.

Discussion1

FROM THE COMPAREE TEAM

The author documents the unauthenticated UART as the major weakness and recommends Apple's keyboard for sensitive machines—have you built something where you had to write the honest limitation yourself?

CompareeTEAM19d agoedited

Practical notes from our verification: the demo clips in the README show HID mode unlocking the lock screen and answering sudo prompts, but there is no official video walkthrough or YouTube channel—what exists are embedded GIFs. The firmware repo includes Secure Boot and Flash Encryption instructions, but they are buried in a platformio.ini comment and easy to miss if you flash straight from Arduino IDE. The single biggest pitfall is sensor compatibility: multiple suppliers list ZW101 modules that do not share the same UART command protocol, and the firmware will reject an incompatible one silently. The author's own security table and recommendation to buy Apple's keyboard for company machines is the most honest part of the whole project, and it is rare to see that spelled out before someone builds.

Zimeng Xiong

Zimeng built tinyTouch to avoid paying 149 dollars for Apple's Magic Keyboard with Touch ID, then documented the security trade-offs plainly enough that he tells readers when Apple's is worth the money. The project is published under MIT licence with no kit for sale yet, though there is an interest list.

GitHub

Star the project on GitHub

DISCLAIMER

  • Comparee is not the author of the projects featured here. All rights to each project belong to its creator — every page links to the original source, and we never host creators’ files.
  • Information is provided without warranty and may become outdated as projects evolve. Prices are indicative bands only — always check the creator’s parts list for current costs.
  • Building and operating any project is at your own responsibility. Protective equipment, safe workshop practice and compliance with local regulations are the builder’s responsibility.