Home | History | Annotate | Download | only in gen
History log of /src/lib/libc/gen/getpass.c
RevisionDateAuthorComments
 1.30  31-Jan-2016  christos PR/50695: coypu: ctrl-c in su password input breaks shell (bash, csh)
Always restore the tty settings.
 1.29  18-Sep-2014  christos make more descriptors that we open as close-on-exec
 1.28  16-Jun-2014  christos branches: 1.28.2;
Recognize CR as end of line too. the telnet client passes that to us instead
of linefeed.
 1.27  26-May-2012  christos branches: 1.27.2; 1.27.8;
make getpass and getpass_r print a newline like they did before.
 1.26  02-May-2012  christos test for both NUL and _POSIX_VDISABLE, because _POSIX_VDISABLE propagation
between different daemons and OS's does not seem reliable.
 1.25  14-Apr-2012  christos - If fd == NULL, do the dance with opening /dev/tty
- Add a flag to enter a newline when we are done.
 1.24  13-Apr-2012  christos prefer ETIMEDOUT.
 1.23  13-Apr-2012  christos add timeout.
 1.22  13-Apr-2012  christos - don't update the length of the buffer until the allocation succeeds
- print only printable characters otherwise print '?'
 1.21  13-Apr-2012  christos unconfuse lint; XXX: should really fix lint.
 1.20  12-Apr-2012  christos add GETPASS_ECHO_STAR
 1.19  12-Apr-2012  christos add getpassfd() that gives us even more fine grain control on how to get
the password.
 1.18  12-Apr-2012  christos raise signals for the tty characters that do.
 1.17  12-Apr-2012  christos Add a new getpass implementation that does not mess with signals, and
include getpass_r
 1.16  01-Jan-2008  christos branches: 1.16.28;
block signals before playing with files. From Anon Ymous
 1.15  07-Aug-2003  agc branches: 1.15.22;
Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22280, verified by myself.
 1.14  22-Jan-2000  mycroft Delint.
Remove trailing ; from uses of __weak_alias(). The macro inserts this if
needed.
 1.13  16-Sep-1999  lukem * use _DIAGASSERT() to check pointer arguments against NULL and file
descriptors against -1 (as appropriate).
* add actual checks which to detect stuff that would trigger_DIAGASSERT(),
and attempt to return a sane error condition.
* knf some code
* remove some `register' decls.

the first two items result in the addition of code similar to the
following in various functions:

_DIAGASSERT(path != NULL)
#ifdef _DIAGNOSTIC
if (path == NULL) {
errno = EFAULT;
return (-1);
}
#endif
 1.12  03-Feb-1998  perry remove obsolete register declarations
 1.11  21-Jul-1997  jtc If port provides __weak_alias(), provide an Standard C and POSIX pure
identifier namespace by renaming non standard functions and variables
such that they have a leading underscore. The library will use those
names internally. Weak aliases are used to provide the original names
to the API.

This is only the first part of this change. It is most of the functions
which are implemented in C for all NetBSD ports. Subsequent changes are
to add the same support to the remaining C files, to assembly files, and
to the automagically generated assembly source used for system calls.
When all of the above is done, ports with weak alias support should add
a definition for __weak_alias to <sys/cdefs.h>.
 1.10  13-Jul-1997  christos Fix RCSID's
Fix gcc warning
 1.9  20-May-1996  jtc branches: 1.9.2;
Signal mask was not restored correctly.
Fix from James Chacon <jmc@pobox.com> in PR #2442.
 1.8  16-May-1996  christos Use the POSIX signal mask interface
 1.7  16-Jun-1995  jtc <sys/termios.h> -> <termios.h>
 1.6  28-Feb-1995  jtc Changed <sys/signal.h> to <signal.h>
 1.5  27-Feb-1995  cgd update from Lite, with local changes. fix Ids, etc.
 1.4  04-Jan-1994  jtc branches: 1.4.4;
Use _PATH_TTY constant instead of "/dev/tty".
 1.3  26-Aug-1993  jtc Declare rcsid strings so they are stored in text segment.
 1.2  30-Jul-1993  mycroft Add even more RCS frobs.
 1.1  21-Mar-1993  cgd branches: 1.1.1;
Initial revision
 1.1.1.2  25-Feb-1995  cgd from lite, with minor name rearrangement to fit.
 1.1.1.1  21-Mar-1993  cgd initial import of 386bsd-0.1 sources
 1.4.4.2  02-May-1995  jtc #include "namespace.h"
 1.4.4.1  26-Apr-1995  jtc #include "namespace.h" where appropriate.
 1.9.2.1  19-Sep-1996  jtc snapshot namespace cleanup: gen
 1.15.22.1  09-Jan-2008  matt sync with HEAD
 1.16.28.3  30-Oct-2012  yamt sync with head
 1.16.28.2  23-May-2012  yamt sync with head.
 1.16.28.1  17-Apr-2012  yamt sync with head
 1.27.8.1  10-Aug-2014  tls Rebase.
 1.27.2.1  20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.28.2.1  26-Feb-2016  snj Pull up following revision(s) (requested by christos in ticket #1101):
lib/libc/gen/getpass.c: revision 1.30
PR/50695: coypu: ctrl-c in su password input breaks shell (bash, csh)
Always restore the tty settings.

RSS XML Feed