passwd cmd reenables passwd aging in shadow entry

Hi Folks,

I have Solaris 10, latest release.

We have passwd aging set in /etc/defalut/passwd.

I have an account that passwd should never expire. Acheived by emptying associated users shadow file entries for passwd aging.

When I reset the users passwd using passwd command, it re enables password aging for the user. :confused:

Before passwd command:

testuser:zo7zLiWHAhrq.:14977::::::

After passwd command:

testuser:EuFd69zZXGkp2:14977:7:28::::

Is there any way to turn this off?:wall:

Have you tried manually putting "0" in the shadow entry so it doesnt try to re-write it ?
eg:
testuser:EuFd69zZXGkp2:14977:0:0::::
(Or maybe even "-1")
It might be because the field is empty, it will then apply the defaults.

I hope this helps.

passwd -x -1 username

has to be ran as root i believe.

If you want it to persist through password changes then script it and put it in roots crontab with all users that you want to not be required to change their passwords. Something like this. As far as i know there is no other way to do it, but i may be wrong.

Did you run "pwconv" after the original manual edit of the shadow file?