1832423 Members
3455 Online
110042 Solutions
New Discussion

Re: passwd -f

 

passwd -f

Hi, I have the following error when using passwd -f xxxx --- Access denied.

It's 11.23 OS.

Anyone have any ideas ?
5 REPLIES 5
Peter Godron
Honored Contributor

Re: passwd -f

Hi,
the -f option is a priviledged user option, so are running this as root ?
What are the permissions on passwd ?
ll `which passwd`

What user are you trying to force to change password ?

Please also read:
http://forums1.itrc.hp.com/service/forums/helptips.do?#33 on how to reward any useful answers given to your questions.
You have awarded points to 14 of 30 answers.
Steven E. Protter
Exalted Contributor

Re: passwd -f

Shalom,

Either permissions on the /etc/passwd file are denied or this command is being run as an unpriviledged user or the passwd command itself has lost its suid powers.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
PC_7
Frequent Advisor

Re: passwd -f

Hello Walter,

I can duplicate the error if it is run by non-root user:

$ passwd -f testuser
Permission denied

But it should works if run by user with root capability:

# passwd -f testuser

login: testuser
Password:
Your password has expired. Choose a new one
Changing password for testuser
Old password:

Please let us know if you have executed it as root user but still received "Permission denied" message.

Cheers,
Pau Cen

Re: passwd -f

Thanks all for the replies.

We are root when trying this command but it's still not working.

I'll check the permissions of the passwd and /etc/passwd command and let you all know.
PC_7
Frequent Advisor

Re: passwd -f

Hi,

Please also ensure you don't have duplicate entries in your /etc/passwd.

Is the system converted to trusted system?
Are you using NIS?

Regards.