2017-11-13

HP-UX 11.3: Trusted System - Root password change

How to change an root user of HP-UX when it is a trusted system.

[chronos:root]/root # passwd
Changing password for root
Old password:
Sorry.
[chronos:root]/root # cd /tcb/files/auth/r
[chronos:root]/tcb/files/auth/r # ls -l
total 112
-rw-rw-r--   1 root       root           137 Aug 11  2010 regj
-rw-rw-r--   1 root       root           305 Nov 13 14:59 root

Of course we need to make a backup just in case.

[chronos:root]/tcb/files/auth/r # cp -p root root.old
[chronos:root]/tcb/files/auth/r # vi root
[chronos:root]/tcb/files/auth/r # diff root root.old
2c2
<       :u_pwd=:\
---
>       :u_pwd=FDKPruSmIH4vs:\

The password can now be changed.  And it won't ask for the old password.

[chronos:root]/tcb/files/auth/r # passwd
Changing password for root
Last successful password change for root: Mon Oct 23 16:24:57 2017
Last unsuccessful password change for root: Mon Nov 13 14:59:41 2017
Do you want (choose one letter only):
        pronounceable passwords generated for you (g)
        a string of letters generated (l) ?
        to pick your passwords (p) ?
Enter choice here: p
New password:
Re-enter new password:
Passwd successfully changed

No comments:

Post a Comment