Re: "passwd username" asks for current password of user even tho I'm root
- Date: Wed, 10 Oct 2018 17:09:37 -0500
- From: Dennis Wicks <wix@xxxxxxxxxx>
- Subject: Re: "passwd username" asks for current password of user even tho I'm root
Mariusz Gronczewski wrote on 10/10/18 8:17 AM:
> On previous releases, and on our CentOS systems I could change password of user by just sudo-ing to root and typing "passwd testuser"
> In current Debian release, doing that asks me to specify that user password, which is pointless because:
> * I can access /etc/shadow anyway
> * I'm changing it because user forgot it
> Is there any way to set passwd (or PAM) to not ask root for current password on passwd-ing non-root accounts ?
> Mariusz Gronczewski, Administrator
> Efigence S. A.
> ul. Wołoska 9a, 02-583 Warszawa
> T: [+48] 22 380 13 13
> F: [+48] 22 380 13 14
> E: mariusz.gronczewski@xxxxxxxxxxxx <mailto:mariusz.gronczewski@xxxxxxxxxxxx>
When I enter sudo passwd testuser
I get a prompt Enter new UNIX password:
Perhaps your sudoers file is not set up correctly?
I have mine:
(myid) ALL = NOPASSWD: ALL