diff options
| author | Hugo Osvaldo Barrera <hugo@whynothugo.nl> | 2025-10-15 01:39:09 +0200 |
|---|---|---|
| committer | Kenny Levinsen <kl@kl.wtf> | 2025-10-15 11:02:24 +0200 |
| commit | eaaffd96a4b3c1e6217f926cedc2feb69a073b4e (patch) | |
| tree | 00cc157f734a8ab032566938f81da3932357dace /README.md | |
| parent | 56c5025e9584c673031519a9a6109cff0056b827 (diff) | |
Clarify setup instructions without PAM
- Mention that using a TCB-like setup doesn't require SUID.
- Recommend using SGID instead of SUID.
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 18 |
1 files changed, 17 insertions, 1 deletions
@@ -42,8 +42,24 @@ Run these commands: ninja -C build sudo ninja -C build install -On systems without PAM, you need to suid the swaylock binary: +##### Without PAM + +On systems without PAM, swaylock uses `shadow.h`. + +Systems which rely on a tcb-like setup (either via musl's native support or via +glibc+[tcb]), require no further action. + +[tcb]: https://www.openwall.com/tcb/ + +For most other systems, where passwords for all users are stored in `/etc/shadow`, +swaylock needs to be installed suid: sudo chmod a+s /usr/local/bin/swaylock +Optionally, on systems where the file `/etc/shadow` is owned by the `shadow` +group, the binary can be made sgid instead: + + sudo chgrp shadow /usr/local/bin/swaylock + sudo chmod g+s /usr/local/bin/swaylock + Swaylock will drop root permissions shortly after startup. |
