This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: getpass obsolete?


On Wed, May 28, 2003 at 10:57:46AM +0800, Carlo Florendo wrote:
> A solution would be to grab the source for the getpass function and cut
> and paste it to my code and modify it as I want so no issues regarding
> linking my code against future libraries that wouldn't support getpass. 
> However, I think it would be better to reuse whatever alternative there
> is. (e.g. the one that is used in linux if indeed it doesn't use getpass
> anymore.)

Section 3.1 of the comp.unix.programmer FAQ gives portable code
for mimicking getpass(3).

	[http://www.erlenstar.demon.co.uk/unix/faq_4.html#SEC48]

> Legacy code issues and functions being obsoleted are really surprising for
> me.  Now, I'm paranoid over some functions that I might still be using but
> are already legacy code.  I thought only java deprecates functions.

this is a wild guess, but i would imagine it's being deprecated because it's
no longer needed and dangerous to keep around. possibly early unix required
user programs to read in passwords for authentication to the system, but now
there are other, safer means for elevating privileges for user apps. and of
course passwords aren't kept in the clear anyhow, and these is no easy and
certainly not portable way to use a plaintext password for privilege
elevation.

just a theory.

- Bill


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]