diff options
author | Evgeny Vereshchagin <evvers@ya.ru> | 2018-02-21 10:34:42 +0300 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2018-02-21 08:34:42 +0100 |
commit | 24a01950a3ce2d6f9f2fd1b2b1750ef5d1076370 (patch) | |
tree | 5b8dde77147b2abd93232a96dd47bb0c71526dd2 /test/udev-test.pl | |
parent | e79d0b59c8d01d35343b21d02d997d2579c32f27 (diff) | |
download | systemd-24a01950a3ce2d6f9f2fd1b2b1750ef5d1076370.tar.gz |
tests: stop using `nobody` in test-udev.pl (#8239)
`nobody` is a special user, whose credentials should be extracted with
`get_user_creds`. `getpwnam` called in `test-udev.pl` is a bit different,
which causes the test to fail with the following error:
```
device '/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/block/sda' expecting node/link 'node'
expected permissions are: nobody::0600
created permissions are : 65534:0:0600
permissions: error
add: ok
remove: ok
```
The ideal fix would probably be to implement `get_user_creds` in Perl, but in this
PR the issue is simply got around by using `daemon` instead of `nobody`.
Closes https://github.com/systemd/systemd/issues/8196.
Diffstat (limited to 'test/udev-test.pl')
-rwxr-xr-x | test/udev-test.pl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/udev-test.pl b/test/udev-test.pl index 20f662eb3b..9e7cc94638 100755 --- a/test/udev-test.pl +++ b/test/udev-test.pl @@ -606,9 +606,9 @@ EOF desc => "textual user id", devpath => "/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/block/sda", exp_name => "node", - exp_perms => "nobody::0600", + exp_perms => "daemon::0600", rules => <<EOF -SUBSYSTEMS=="scsi", KERNEL=="sda", SYMLINK+="node", OWNER="nobody" +SUBSYSTEMS=="scsi", KERNEL=="sda", SYMLINK+="node", OWNER="daemon" EOF }, { |