Skip to content

Find fingerprint readers a platform names - #14675

Merged
ryanrhughes merged 3 commits into
omacom:quattrofrom
scottjones:fingerprint/platform-readers
Oct 19, 2026
Merged

ryanrhughes merged 3 commits into
omacom:quattrofrom
scottjones:fingerprint/platform-readers

Conversation

@scottjones

@scottjones scottjones commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Builds on #14431, which added the platform files under /usr/share/omarchy-platform/; this adds one more. Now based on quattro.

omarchy-hw-fingerprint only looks at USB, so it never finds a Mac's Touch ID, which the kernel drives through the Secure Enclave. This PR lets the platform package name such readers in a new platform file, fingerprint-readers, the same way it already describes displays, cutouts and keys. It's the detection half of omacom#694. The enrollment changes from that PR aren't included.

On its own this does nothing for users. Omarchy ships no fingerprint-readers file, and omarchy-mac only adds one in omacom/omarchy-mac-pkgs#12, which waits on the Apple Touch ID kernel work. Until then every machine detects exactly what it does today.

Thanks to Chris Kearney (@iconidentify) and DJ (@DjDeveloperr) for helping get the Touch ID hardware working.

Summary

 omarchy-hw-fingerprint
+  for each "<absolute glob> <value>" line in /usr/share/omarchy-platform/fingerprint-readers
+    if any matching file's whole content == value
+      exit 0                          # reader present
   scan USB by product string, then vendor with no kernel driver bound

On Apple Silicon, omarchy-mac would ship /sys/bus/platform/drivers/apple_sep/*/diag/touchid ready. The match is on the whole value, so not-ready doesn't count, and a platform file never hides a USB reader. The docs (file-layout.md, lifecycle-dispatch.md) give the line format, say the file is read as the session user (the real file is 0444 root:root), and note that the line follows the kernel's apple_sep / diag/touchid names.

Evidence

test/shell.d/hw-fingerprint-test.sh runs a copy of the command against a fixture platform root and fixture USB devices, never the host's /usr/share/omarchy-platform or /sys.

  • Before (base command, no platform loop): not ok - a reader the platform names is detected once its file reads the value
  • After: 23/23 ok. Substring matching fails the not-ready case, and a platform file that hides USB fails the "USB reader beside a not-ready Touch ID" case.

On an M2 Max with the aurora kernel, diag/touchid is -r--r--r-- root root and reads ready.

Merge Danger

Door: two-way. It adds a branch that only runs when the platform file exists.

Blast Radius: none until a platform package ships fingerprint-readers. After that, the first-run fingerprint invitation and the Setup › Security › Fingerprint menu item show up on that platform.

🤖 Generated with Claude Code

scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 9, 2026
Brings in #18, #19, #20 and #22. The runtime pin conflicted: main pins
omacom/omarchy 4d9bdc49 (#14431), which has no platform-root fingerprint
detection, so this branch now pins omacom/omarchy#14675's head
f317ea50, the fingerprint-readers detector on #14431. Move it to the
merge commit once #14675 lands. omarchy-mac stays at #12's 0.2.0; main
is still at 0.1.0.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@scottjones
scottjones marked this pull request as ready for review October 10, 2026 00:02
@greptile-apps

greptile-apps Bot commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 3/5

[High impact] Adds platform detection and hardware provisioning infrastructure.

Fix the disk-key recovery and first-boot rebuild checks before merging.

Summary

The PR adds platform-provided fingerprint detection and includes broader platform, first-boot, boot, audio, recording, and package changes in the current diff.

  • Fingerprint detection can find readers named by the platform.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Fingerprint check] --> B{Platform file readable?}
  B -- Yes --> C{Any named file has the expected value?}
  C -- Yes --> D[Reader present]
  C -- No --> E[Existing USB scan]
  B -- No --> E
  E --> F{USB reader found?}
  F -- Yes --> D
  F -- No --> G[No reader found]
Loading

Reviews (2) · Last reviewed commit: "Test Touch ID's other values and note th..." · Reviewed by Greptile

@scottjones
scottjones marked this pull request as draft October 10, 2026 00:17
scottjones and others added 3 commits October 9, 2026 20:28
omarchy-hw-fingerprint only scanned USB, so a reader the kernel drives
another way, such as a Mac's Touch ID behind its Secure Enclave, was never
found: no first-run invitation, and the setup stopped at "No fingerprint
sensor detected". A platform package now names such readers in
/usr/share/omarchy-platform/fingerprint-readers, each as a file and the
value it reads once the reader is usable.

Ported from omacom/omarchy-mac 916a912, detection only.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…e it

The docs now say the comparison drops trailing newlines, a space splits a
line's fields and the file is read as the session user. A platform file that
matches nothing must never hide a USB reader, so the test pairs one with a
real USB reader both ways. lifecycle-dispatch.md lists the file with the
others.

Ported from omacom/omarchy-mac d94c8d7.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
diag/touchid also reads not-ready, unknown and failed, and not-ready
contains ready, so the test now rejects each one and finds a USB reader
beside a not-ready Touch ID. file-layout.md says the value is the whole
file, that the file is 0444 root:root, and that the line follows the
kernel's apple_sep and diag/touchid names, so a rename stops detection
without an error.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@scottjones
scottjones force-pushed the fingerprint/platform-readers branch from f317ea5 to 00fcc45 Compare October 10, 2026 00:51
@scottjones
scottjones changed the base branch from omabot/pr-13362 to quattro October 10, 2026 00:51
@scottjones
scottjones marked this pull request as ready for review October 10, 2026 00:51
@greptile-apps

greptile-apps Bot commented Oct 10, 2026

Copy link
Copy Markdown
Contributor

Comments Outside Diff

These findings could not be posted inline.

  • P1 Recovery deletes another key bin/omarchy-drive-password:313 ▶

    finish_interrupted_change treats any single new key slot as one created by the interrupted password change. If the change stops before adding a key, and the owner then enrolls a recovery key with cryptsetup luksAddKey, rerunning with the old password deletes that recovery key. Entering the recovery key instead deletes the old owner's slot. The count > 1 guard misses both cases.

    Record which slot the change creates, or refuse to delete slots when their origin cannot be confirmed.

  • P1 Failed rebuild loses its retry bin/omarchy-provision-hardware:150 ▶

    omarchy-provision-hardware trusts a zero exit from limine-mkinitcpio, then clears the rebuild request and disables its retry service. The new migration documents that limine-mkinitcpio can return zero when a kernel image fails to build, including when the boot partition is full. First-boot hardware changes then remain absent from the boot image, but setup marks the work complete and will not retry.

    Check that the required boot images were actually rebuilt before clearing the saved work.

scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 10, 2026
Brings in #23. omarchy-mac stays at #12's 0.2.0 over main's 0.1.1, in
the version file and the README. The runtime pin moves to
omacom/omarchy#14675's head 00fcc451, the fingerprint-readers detector
on quattro, since f317ea50 is no longer any PR's head. Quattro renames
the platform from apple-silicon to aarch64-apple, so the platform-name
tests need #24 before this pin passes.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 10, 2026
Brings in #26's platform names. omarchy-mac stays at #12's 0.2.0, above
main's 0.1.2, in the version file and the README. The runtime pin stays
on omacom/omarchy#14675's head 00fcc451, which sits on main's pinned
quattro e1b0e5e9b; its note now says so. #12's one platform check, the
unit's ExecCondition, already goes through omarchy-hw-apple-silicon.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 12, 2026
…ONTRIBUTING.md

AGENTS.md said #12 brought both the platform file and the detector that
reads it. #12 adds fingerprint-readers; omacom/omarchy#14675 teaches the
runtime's omarchy-hw-fingerprint to read it. CONTRIBUTING.md now states
the release rule for one-time prompts beside the cold-boot evidence rule,
so merging the AGENTS.md rule doesn't make policy the contributor guide
leaves out.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 18, 2026
It skipped unless the pinned runtime named fingerprint-readers, so CI was
green without running it. The pin now names omacom/omarchy#14675's head
(00fcc451: the detector on upstream quattro e1b0e5e9b), and the test no
longer skips. Before this lands the pin moves to #14675's merge commit.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

@maralcbr maralcbr left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed at 00fcc45, merged onto current quattro (clean). In a Linux container hw-fingerprint-test.sh passes 23/23, and with #15512 merged as well, 23/23 and 18/18.

Approve. The whole-value match, CRLF handling, ignored relative paths, extra words and comments, and the USB fallback when no platform file matches are all right, and nothing changes until a platform ships fingerprint-readers. Greptile's P1 on bin/omarchy-drive-password isn't in this PR's files.

@ryanrhughes
ryanrhughes merged commit 81fd2d2 into omacom:quattro Oct 19, 2026
1 check passed
@omarchybot omarchybot added the enhancement New feature or request label Oct 19, 2026
scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 19, 2026
#14675, the runtime's fingerprint-readers detector, merged into quattro
as 81fd2d23ca6e. The pin moves from its head to that merge commit, and
both Touch ID integration tests run against it.

That runtime also has omacom/omarchy#15326, so the reset prints its
prompts through omarchy-i18n. The factory-reset test sources the reset's
functions with only its stubs and the system PATH, so every prompt
failed with "command not found"; it now links the runtime's omarchy-i18n
and its catalogs into the fixture.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
scottjones added a commit to scottjones/omarchy-mx-mac that referenced this pull request Oct 19, 2026
limine-mkinitcpio skips a kernel it cannot build or install, a full boot
partition for one, and still exits 0. First-boot hardware setup took that
as done: it cleared the rebuild request and disarmed its service, so the
machine kept booting an image without the hardware changes. The rebuild
now counts only when every image Limine started reports success and
nothing reported an error, limine-entry-tool's own "Failed to" lines
included. Otherwise it stays owed for the next boot, for up to three
tries, after which setup finishes with a warning in the journal and the
install log rather than holding every boot on a rebuild.

Found by Greptile on omacom#14675.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
ryanrhughes pushed a commit that referenced this pull request Oct 21, 2026
The rerun after an interrupted change treated any one slot added since as
the change's new key. If the change stopped before luksChangeKey and a
recovery key was enrolled before the rerun, entering the old password
removed the recovery key, and entering the recovery key removed the old
password's slot. luksChangeKey picks the new slot itself, so the journal
can't name it, and LUKS2 leaves both keys between its two header updates.

With both slots on the disk the rerun now asks for the new password, and
the old one when it has only the new, and removes a slot only once the new
password opens the added slot and the old password the old one. Otherwise
it removes nothing and says how to settle the disk by hand.

Found by Greptile on #14675.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
omarchybot added a commit to alanwcurry-dev/omarchy that referenced this pull request Oct 21, 2026
quattro's omacom#14675 added platform-named readers to omarchy-hw-fingerprint and its test. The script merged cleanly; the test conflicted only because both appended cases at the end, so the FocalTech cases now follow the platform ones, after the platform file is removed, and still exercise the USB scan alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
omarchybot added a commit to themodev/omarchy that referenced this pull request Oct 21, 2026
Both sides appended cases to hw-fingerprint-test.sh. The platform-reader cases from omacom#14675 run first and remove their fingerprint-readers file, so the wedged-reader cases still exercise the USB scan alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@emirb emirb added this to the 4.5 milestone Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants