Skip to content

soc: apple: guard Touch ID enrolment and recover exact identities - #517

Closed
RyanTheTide wants to merge 13 commits into
integration/aurorafrom
fix/sep-bio-orphan-delete-20261027
Closed

RyanTheTide wants to merge 13 commits into
integration/aurorafrom
fix/sep-bio-orphan-delete-20261027

Conversation

@RyanTheTide

@RyanTheTide RyanTheTide commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Require resolved account/finger metadata and durable Linux SEP bindings before ENROL_START; prepare an empty owner context only after userspace account validation.
  • Expose a scoped list of Linux built-in enclave identities and exact-ID recovery deletion. Save user, master and owner Catacombs; snapshot the identity bag when bound, with an owner-Catacomb recovery path for an unbound orphan.
  • Log the identity returned by SEP at match time so a same-finger match against a different stored UUID can be distinguished from no enclave match.
  • Package an exact-ID recovery utility that requires a named identity to preserve when multiple identities exist.

Paired userspace change: aurora-silicon/aurora-sep-userspace#3.

Verification

  • KUnit cases added for enrol admission, exact Linux identity scope, match-result identity and recovery target selection. The arm64 Apple SEP Rust module and C shims compile in CI with CONFIG_APPLE_SEP_KUNIT_TEST=y. Runtime KUnit execution is still pending.
  • Local CLI, packaging and synthetic admission/owner-preparation/deletion tests: nine pass. They execute the driver functions for the refusal classes, preserve a corrupt owner file, and verify index retention until a failed save is retried. Rust source parses under rustfmt; checkpatch has zero errors and one MAINTAINERS warning.
  • Hardware persistence, single-print reboot verify, Neo/M1 Pro regression and macOS-lane xART ledger diffs remain pending. A late host or SEP I/O failure after capture starts remains a recovery case; the upfront checks cannot predict future writes. This PR is draft until the hardware tests pass. The utility has no DELETE_ALL entry and filters to the selected SEP OS identity's built-in Linux user context. OS identity provenance and macOS-lane isolation still require the requested ledger diff.

Assisted-by: LLM

RyanTheTide and others added 13 commits October 27, 2026 23:32
Validate enrolment metadata and durable Linux bindings before capture. Prepare an empty owner context only after userspace has validated the account. Expose Linux user-context identities and an exact-ID recovery delete, saving owner, user and master Catacombs before reporting success. Report the identity returned by the enclave at match time.

Assisted-by: LLM
Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
Install a utility that lists the selected Linux SEP user context and deletes one named identity while requiring the operator to name identities that must remain. Document the recovery and admission sequence and test the CLI and package sources.

Assisted-by: LLM
Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
Use the identity-bag snapshot when recovery still has a verified bag binding. Reserve the owner-Catacomb fallback for an unbound orphan and require the persisted Linux bag file before the irreversible enclave delete.

Assisted-by: LLM
Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
The scoped list, exact-ID delete and empty-owner preparation require the Linux identity bag to be designated and persisted before issuing SBIO commands.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Run the scoped ioctl size check and existing recovery/package tests on Linux for SEP pull requests.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
The Fedora and Arch packages install the utility with mode 0755; keep the source mode aligned with kernel checkpatch conventions.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Compile and execute the driver deletion orchestration with scripted enclave and persistence outcomes. Check that an indexed fprintd orphan is removable by exact ID and that failed saves retain the host index for retry.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Compile the kernel admission functions in a host harness and exercise missing UID, unknown finger, OS identity, bag, Catacomb and storage-capacity refusals before hardware testing.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Check sensor availability, identity-bag file writability and host index capacity before PREPARE_ENROL selects or saves an empty owner context.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Create and sync the missing Linux owner file before SELECT_CONTEXT writes to the enclave. Refuse an existing invalid file without truncating its failure evidence.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Execute the driver preflight function with a scripted file backend and verify that a corrupt existing owner file is not truncated before SEP context writes.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Add a targeted arm64 module build so the biometric driver changes receive a kernel type-check in addition to the source and synthetic tests.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Enable KUnit and the SEP test configuration for the targeted Rust module build so the new admission and identity tests are compiled.

Assisted-by: LLM
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Merged into aurora-wip through #534 (2026-10-28 consolidation). aurora-wip is the home for WIP from here on.

@RyanTheTide
RyanTheTide deleted the fix/sep-bio-orphan-delete-20261027 branch October 28, 2026 05:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant