20
6
is there a straight-forward way to allow a user to run (for example)
/usr/bin/pacman -S -u
as root, without allowing him to run
/usr/bin/pacman -S -u some_package
?
The line
user ALL=(root) NOPASSWD: /usr/bin/pacman -S -u
allows both, and
user ALL=(root) NOPASSWD: /usr/bin/pacman -S -u ""
appears to be semantically equivalent.
1Not the best solution, but +1 for security warning – Aaron J Lang – 2014-11-10T12:22:58.587
thats not an elegant way, sudo supports by default the exact given case – matthias krull – 2010-07-26T10:59:42.473