Skip to content

feat!: the password says who you are, one LUKS slot per account - #7

Merged
lbssousa merged 6 commits into
mainfrom
feat/password-identifies-person
Nov 5, 2026
Merged

lbssousa merged 6 commits into
mainfrom
feat/password-identifies-person

Conversation

@lbssousa

@lbssousa lbssousa commented Nov 5, 2026

Copy link
Copy Markdown
Owner

Summary

Replaces the list of users on the login screen with the model of Omarchy PR omacom/omarchy#16920: each account's password is also its own LUKS key slot, and the password alone says who is logging in. Also brings in what was useful from omacom/omarchy#16100 and from the session-switching findings posted on both.

What changes

  • Disk prompt: the boot image notes which slot opened the disk (omarchy-mu-luks-slot), and omarchy-mu-login-select opens that person's desktop, once. With one account on an encrypted disk, it is logged in. Anything unsure shows the login screen.
  • Login screen: a password box that finds the account (omarchy-mu-login-match, first in SDDM's PAM auth stack). The user list, Other user… and choosing a password at the first login are gone.
  • Passwords: omarchy-mu-user-password changes one everywhere at once, journaled. Each has at least 6 characters and is nobody else's.
  • Lock screen: Switch user no longer leaves a dark screen, and a session in the background can't be opened by a password or fingerprint, or hold the reader.
  • Signing out an automatic login: when removing an account or taking its rights, SDDM is asked for its login screen, since it shows nothing after a forced end.
  • Package removal: the path units go off first, which kept the PAM line in place, and no watcher link is left dangling.

Breaking

  • Every person has to run omarchy-mu-user-password after upgrading. The warning for that only fires when upgrading to 0.10.0 or later, so the next release has to be at least 0.10.0. PKGBUILD is still at 0.9.0: this PR doesn't do the release.
  • omarchy-mu-user-add loses --luks and --set-password. omarchy-mu-luks-enroll and omarchy-mu-accounts first-login are gone.

Review with care

  • afa158a adds a wrapper around cryptsetup to the initramfs. A mistake there could stop the disk from opening, so it is a separate commit that can be reverted alone. Its message says it had not run on a real boot yet; the testing below came after it.
  • omarchy-mu-login-match reads passwords inside SDDM's PAM stack. An owner with failed logins on record deliberately gets the slow refusal, so a fast one doesn't reveal a lockout.

Testing

  • Test suites: 211 shell and 22 JS tests pass.
  • VM, Omarchy 4.5.0 with a real install: two accounts, disk prompt, login screen, migrating from the previous model, removing an account, rollback, and a password with accented letters typed on an ABNT2 layout.
  • Real hardware, a laptop with Intel and NVIDIA graphics: installing, adding an account, the disk prompt with both passwords, the login screen, and switching between two running sessions all worked. This ran the package from before 96dbe78, whose fix was only checked in the VM.

Not yet tested on real hardware:

  • whether the greeter's image freezes after going to another console and back (seen in the VM until the mouse moves, not fixed, may be VM-only)
  • suspending from the lock screen
  • removing an account while its automatic login is running
  • rolling back
  • fingerprint and FIDO2 with the new login flow

Known and left alone

  • Every normal login logs omarchy-mu-login-match failed: exit code 1, because pam_exec reports that script's "carry on" answer as an error. Cosmetic.
  • Reinstalling over a dangling watcher link, left by removing an earlier version, keeps that watcher off until the next boot.

🤖 Generated with Claude Code

lbssousa and others added 6 commits November 5, 2026 11:02
From Omarchy PRs #16100 and #16920, and the session-switching findings posted
there. SDDM 0.21 starts a new greeter on the first console, which fails while an
automatic login's desktop holds it and leaves the screen dark. Switch user now
waits for that console, and goes back to a login screen already running instead
of asking for a second one.

A password or fingerprint accepted once the session is in the background no
longer opens it, and a session in the background doesn't take the fingerprint
reader back on resume. System > Switch User (omarchy-mu-user-switch) does the
same from an open desktop.

Also: Setup > Users' entries stay out of the search of users outside wheel,
omarchy-mu-user-add refuses while /etc/sddm.conf logs someone in automatically,
omarchy-mu-user-remove stops when the account's disk password can't be removed,
a password chosen at the first login has at least 6 characters, and SDDM has
ReuseSession=true set here.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Replaces the list of users on the login screen with the model of Omarchy PR
#16920. Each account's password is also its own LUKS key slot, recorded in
/etc/omarchy-multiuser/slots, with at least 6 characters and nobody else's.

The boot image notes which slot opened the disk (omarchy-mu-luks-slot), and
omarchy-mu-login-select logs that person in, once. Anything unsure shows the
login screen, which is now a password box that finds the account
(omarchy-mu-login-match). omarchy-mu-user-password changes a password everywhere
at once, journaled, through omarchy-mu-user-helper.

This is a separate commit so it can be reverted alone: it adds a wrapper to the
initramfs, which could stop the disk from opening if it is wrong, and it has not
run on a real boot, PAM stack or SDDM yet.

Gone: the user list, Other user..., choosing a password at the first login,
omarchy-mu-luks-enroll, omarchy-mu-accounts first-login, and omarchy-mu-user-add's
--luks and --set-password. Every person has to run omarchy-mu-user-password after
upgrading; the warning for that needs the next release to be 0.10.0 or later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…atic login

Removing an account, or logging it out when taking its rights, ended a desktop
opened by the disk prompt by force. SDDM takes that for a crash and shows nothing
more on the first console, so the machine stayed dark there. It is now asked for
its login screen, which takes over the screen, and the person at another console
is told how to come back. Putting them back at once left the greeter dark for
good, since its compositor had lost the console before setting up the display.

Going to another console and back also left the greeter without the keyboard until
a click, as Qt drops the field's focus. It now takes the focus back.

Found running both on a real install in a VM. Also corrects the README on what a
key does on a dark lock screen, and marks two intended patterns for shellcheck.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The guard watches /etc/sddm.conf.d, so the cleanup in pre_remove ran it, and it put
back the omarchy-mu-login-match line in /etc/pam.d/sddm, naming a script about to
be gone. The path units now go off before anything else is cleaned up.

Found rehearsing the rollback in a VM.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ackage

pre_remove didn't disable omarchy-mu-migrate-record@<admin>.path, so each one's
link in multi-user.target.wants stayed, dangling, once the unit file was gone. They
are now disabled, and a link systemctl can't disable is deleted.

Found rehearsing the rollback in a VM, and checked there with a real removal.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@lbssousa
lbssousa merged commit 5388cf0 into main Nov 5, 2026
1 check passed
@lbssousa lbssousa mentioned this pull request Nov 5, 2026
2 of 3 tasks
@lbssousa
lbssousa deleted the feat/password-identifies-person branch November 5, 2026 18:58
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