summaryrefslogtreecommitdiffstats
path: root/usr.sbin/pwd_mkdb
Commit message (Collapse)AuthorAgeFilesLines
* Rename the pwd_mkdb(8) option '-c' to '-C' for better compatiblitywosch1998-01-102-9/+9
| | | | with BSD/OS.
* Staticize usage(). Cosmetics.charnier1997-10-103-16/+24
|
* db close routine actually writes data out to disk; return value wasjlemon1997-08-181-2/+4
| | | | | | not being checked. Change code to fail if db->close errors. PR: 4202
* Document the -u option.mpp1997-04-041-1/+6
| | | | Forgotten by: guido
* compare return value from getopt against -1 rather than EOF, per the finalimp1997-03-311-1/+1
| | | | posix standard on the topic.
* Fix possible (not stack) overflow from -d <dir> commandline option.davidn1997-03-201-1/+1
|
* Allow comments in password database. The comments are copied fromwosch1997-03-082-4/+26
| | | | | | | | | | | | | the password file into /etc/master.passwd and optional (-p) into /etc/passwd. Enable this feature with the compile option -DPASSWD_IGNORE_COMMENTS. The character `#' introduces a comment. Leading spaces and tabs are ignored: '^[ \t]*#.*\n$' Count an empty line - only spaces, tabs or newline - also as a comment. An empty line at the bottom of /etc/master.passwd is a common novice error and increased my mail load: '^[ \t]*\n$'
* Begin closing out PR #1519 (this requires a change to chpass too,wpaul1996-10-221-4/+12
| | | | | | | | | | and both changes need to be pulled into the stable branch). The problem here is that when pwd_mkdb creates /etc/passwd, it turns empty UID and GID fields into zeroes. To fix this, we check the _PWF_UID and _PWF_GID bits in the pw_fields flag: if the bits are not set, we print an empty field instead of a zero. This way, you don't get zeroes in the UID or GID fields unless you explicit want them.
* New option: [-c]wosch1996-08-192-3/+17
| | | | | Check if the password file is in the correct format. Do not change, add, or remove any files.
* Fixed brackets in usage message.bde1996-07-121-8/+10
| | | | Reformatted some of recent changes to KNF.
* Check if username is a NULL pointer before dereferencing it.martin1996-07-031-1/+1
|
* Implement incremental passwd database updates. This is done by ading a '-u'guido1996-07-011-133/+218
| | | | | | | | | | | | | | option to pwd_mkdb and adding this option to utilities invoking it. Further, the filling of both the secure and insecure databases has been merged into one loop giving also a performance improvemnet. Note that I did *not* change the adduser command. I don't read perl (it is a write only language anyway). The change will drastically improve performance for passwd and friends with large passwd files. Vipw's performance won't change. In order to do that some kind of diff should be made between the old and new master.passwd and depending the amount of changes, an incremental or complete update of the databases should be agreed upon.
* Submitted by: archie@whistle.comjulian1996-06-201-2/+2
| | | | | This program should COMPLAIN about uids > 65K but not abort.. they are after all legal, and some of us NEED them!
* NIS cleanups and fixes, the next generation, continued.wpaul1996-04-161-56/+11
| | | | | | | | | | | | | | | pwd_mkdb.c: - Don't save the PLUSCNT and MINUSCNT tokens: we don't need them anymore. - Count the + and - entires for NIS together instead of counting + and - entries seperately. Index all special NIS entries using new _PW_KEYYPBYNUM token. pwd.h: - Remove the PLUSBYNUM, MINUSBYNUM, PLUSCNT and MINUSCNT tokens and replace then with a single _PW_KEYYPBYNUM token.
* Remove trailing whitespace.rgrimes1995-05-302-3/+3
|
* Add what looks to be the right fix to this bogus code.jkh1995-03-241-1/+1
|
* Re-enable +::::::::: wildcards that I had previously disallowed.wpaul1995-03-231-5/+3
| | | | | | | | | | Note: if you put +::0:0:::::: in /etc/master.passwd as your only NIS entry, it will cause all NIS uids and gids to be remapped to zero. This is *intentional*. That's the way it's supposed to work. Enabling NIS with no remapping at all is done with +:::::::::, not +::0:0::::::. Similarly, +:::::::::/bin/csh will remap the shells of all NIS users to /bin/csh. Or, you could do +wpaul:::::::::/bin/csh to remap NIS user wpaul's shell to /bin/csh but leave everyone else alone.
* Summarily enable YP as soon as any a '+' is detected instead of generatingwpaul1995-03-231-9/+4
| | | | | special values when +user substitutions are in effect. The new getpwent code can handle all the special cases itself now.
* - Add support for embedding special entries in the password databaseswpaul1995-03-231-3/+72
| | | | | | | | | | for +@netgroup/-@netgroup entries. This saves the getpwent functions from having to do all the work. - Fix potential bug: when pwd_mkdb writes the YP-enabled flag to the secure password database, it uses the wrong database descriptor. (It uses the descriptor from the non-secure database, which is already closed by the time things are being written into the secure dastabase).
* Be sure to properly fail if there are not enough fields. Problemdg1995-01-271-2/+4
| | | | reported by MARC Giannoni <marc@cmc.eng.comsat.com>, this fix is by me.
* Fix security hole in YP password support, which wouldmake +user entrieswollman1994-09-201-3/+12
| | | | | act like + entries in some cases. Requires support in libc from next commit.
* Maintain pw_fields, and output same to password database.wollman1994-09-202-1/+39
| | | | | | | | | | | !!!!!!!! NB !!!!!!!! You MUST pwd_mkdb /etc/master.passwd before attempting to use the new libc, or things may go wrong. (I doubt anything actually /will/ go wrong, but the actual behavior is undefined. YOU HAVE BEEN WARNED.) The database format is, however, backwards-compatible, so old executables will still work.
* Added the -d <directory> functionality to allow construction of thegpalmer1994-09-072-17/+31
| | | | password databases somewhere other than /etc.
* Get rid of update. Make man page installation work with our schemewollman1994-08-051-1/+1
| | | | (and rename a few in the process).
* BSD 4.4 Lite usr.sbin Sourcesrgrimes1994-05-265-0/+680
OpenPOWER on IntegriCloud