cancel
Showing results for 
Search instead for 
Did you mean: 

getprpw no output

 
SOLVED
Go to solution
bouserg
Regular Visitor

getprpw no output

Hi,

 

With a trusted system, I have no output with the command getprpw.

 

Any suggestion?

 

Thank's

6 REPLIES
James R. Ferguson
Acclaimed Contributor

Re: getprpw no output

Hi:

 

Echoing the return code would be very informative:

 

0 = success

1 = user not privileged

2 =  incorrect usage

3 =  cannot find the password file

4 =  system is not trusted

 

Otherwise:

 

If so, what do these show?

 

# whereis getprpw

# file <path_to_getprpw>

# ls -l <path_to_getprpw>

 

Regards!

 

...JRF...

rariasn
Honored Contributor

Re: getprpw no output

Hi:

 

# /usr/lbin/getprpw -l root

 

getprpw displays the user's protected password database settings. This command is available only to the superuser in a trusted system.

 

# ll -R /tcb/files/auth

# man getprpw

 

rgs,

bouserg
Regular Visitor

Re: getprpw no output

Hi,

 

echo $?:

126

 

whereis getprpw:

getprpw: /usr/lbin/getprpw /usr/share/man/man1m.Z/getprpw.1m

 

 

-r-xr-xr-x   1 bin        bin              0 Jul 19 15:58 /usr/lbin/getprpw

 

file /usr/lbin/getprpw

/usr/lbin/getprpw:      empty

 

this command worked before.

I don't know why it's empty.

 

Regards

 

 

 

Pete Randall
Outstanding Contributor

Re: getprpw no output

You did not show us the output of "# ls -l <path_to_getprpw>" but I expect it would have said 0 bytes.  It's gone missing and you need to restore it from backup or copy it from another, similar server (i.e. same version of HP-UX, roughly the same patch level, etc.)

 

Correction:  I should have said "I missed seeing the ls -l output".  Not sure how I missed that!


Pete
James R. Ferguson
Acclaimed Contributor
Solution

Re: getprpw no output


bouserg wrote:

-r-xr-xr-x   1 bin        bin              0 Jul 19 15:58 /usr/lbin/getprpw

 


Hi (again):

 

And there is the reason for the lack of any output :-)

 

Someone (as root) or some process running as root, has truncated this binary on July 19.  If you have another server with the same, copy it in from there.  Otherwise you could look to reinstalling it from either a patch or a fileset.  To find where is comes from, do:

 

# swlist -l file|grep getprpw

 

Regards!

 

...JRF...

bouserg
Regular Visitor

Re: getprpw no output

thank's for your help.

 

I'll copy it from another server.

 

Regards


James R. Ferguson wrote:

bouserg wrote:

-r-xr-xr-x   1 bin        bin              0 Jul 19 15:58 /usr/lbin/getprpw

 


Hi (again):

 

And there is the reason for the lack of any output :-)

 

Someone (as root) or some process running as root, has truncated this binary on July 19.  If you have another server with the same, copy it in from there.  Otherwise you could look to reinstalling it from either a patch or a fileset.  To find where is comes from, do:

 

# swlist -l file|grep getprpw

 

Regards!

 

...JRF...



James R. Ferguson wrote:

bouserg wrote:

-r-xr-xr-x   1 bin        bin              0 Jul 19 15:58 /usr/lbin/getprpw

 


Hi (again):

 

And there is the reason for the lack of any output :-)

 

Someone (as root) or some process running as root, has truncated this binary on July 19.  If you have another server with the same, copy it in from there.  Otherwise you could look to reinstalling it from either a patch or a fileset.  To find where is comes from, do:

 

# swlist -l file|grep getprpw

 

Regards!

 

...JRF...