Package: sudo Version: 1.8.19p1-2.1 Severity: normal Dear Maintainer,
I have the following in my sudoers file: www-data ALL=(root) NOPASSWD: /usr/bin/whomai www-data ALL=(root) NOPASSWD: /home/whoami `sudo -l` reflects this: $ sudo sudo -u www-data sudo -n -l Matching Defaults entries for www-data on r-passerv: env_reset, mail_badpass, secure_path=/usr/local/sbin\:/usr/local/bin\:/usr/sbin\:/usr/bin\:/sbin\:/bin User www-data may run the following commands on r-passerv: (root) NOPASSWD: /usr/bin/whomai (root) NOPASSWD: /home/whoami Running /home/whoami as root works: $ sudo sudo -u www-data sudo -n -u root /home/whoami root However, even though it is configuraed virtually the same, running /usr/bin/whoami as root does not work: $ sudo sudo -u www-data sudo -n -u root /usr/bin/whoami sudo: a password is required I am pretty flabbergasted by how the *path* of the binary seemingly makes a difference here... Kind regards, Ralf -- System Information: Debian Release: 9.4 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 4.9.0-6-amd64 (SMP w/2 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages sudo depends on: ii libaudit1 1:2.6.7-2 ii libc6 2.24-11+deb9u3 ii libpam-modules 1.1.8-3.6 ii libpam0g 1.1.8-3.6 ii libselinux1 2.6-3+b3 ii lsb-base 9.20161125 sudo recommends no packages. sudo suggests no packages. -- Configuration Files: /etc/sudoers [Errno 13] Permission denied: '/etc/sudoers' /etc/sudoers.d/README [Errno 13] Permission denied: '/etc/sudoers.d/README' -- no debconf information