NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

getlogin, su, and passwd



Hello,

Consider the following scenario:

$ whoami
jschauma
$ su - jdoe
Password:
$ whoami
jdoe
$ passwd
Changing password for jschauma.
Old Password:

That is, passwd(1) will act on the current login name as returned by
getlogin(2), regardless of whatever the current (effective or real) UID
may be.

This came as a surprise to me.

Brief testing suggests that at least some other platforms do not behave
this way.

Bug or feature?

-Jan

Attachment: pgp7hgQXZdNEG.pgp
Description: PGP signature



Home | Main Index | Thread Index | Old Index