Red Hat Bugzilla – Bug 1019791
slock does not have suid applied
Last modified: 2013-11-28 03:01:05 EST
Description of problem:
slock is not installed with o+s permissions. This causes that it cannot read shadow file and fail to start.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. start slock
slock: cannot retrieve shadow entry (make sure to suid or sgid slock)
slock successfuly locks the screen
This works great on f19.
Modes of /usr/bin/slock:
slock-1.1-3.fc19.x86_64.rpm: -rwsr-xr-x (4755)
slock-1.1-4.fc20.x86_64.rpm: -rwxr-xr-x (0755)
As a workaround you can run this under root:
# chmod u+s /usr/bin/slock
This is already done in the Makefile and I can even see it happen in the build.log. Still, you're right -- the permissions are incorrect.
This seems to be an intentional mock constraint now.
Setting the bits with %attr solves the issue.
slock-1.1-5.fc20 has been submitted as an update for Fedora 20.
I built rpm from repo.
$ rpm -q slock
$ ls -l /usr/bin/slock
-rwsr-xr-x. 1 root root 15344 Oct 17 15:11 /usr/bin/slock
slock works great now.
Version from updates-testing works great too.
slock-1.1-5.fc20 has been pushed to the Fedora 20 stable repository. If problems still persist, please make note of it in this bug report.