summaryrefslogtreecommitdiffstats
path: root/pw
Commit message (Collapse)AuthorAgeFilesLines
* Remove more single-space hard sentence breaks.Sheldon Hearn2000-03-021-1/+2
|
* Remove single-space hard sentence breaks. These degrade the qualitySheldon Hearn2000-03-012-3/+6
| | | | | of the typeset output, tend to make diffs harder to read and provide bad examples for new-comers to mdoc.
* Portability fixes for other bsd4.4 derivatives.David Nugent2000-01-156-20/+33
|
* Revert the libcrypt/libmd stuff back to how it was. This should not havePeter Wemm1999-12-181-2/+2
| | | | | | | | happened as it was working around problems elsewhere (ie: binutils/ld not doing the right thing according to the ELF design). libcrypt has been adjusted to not need the runtime -lmd. It's still not quite right (ld is supposed to work damnit) but at least it doesn't impact all the users of libcrypt in Marcel's cross-build model.
* Add libmd (or move it after libcrypt). We don't want the linker to beMarcel Moolenaar1999-12-161-2/+2
| | | | | smart because it will definitely get it wrong. This popped up during cross-linking.
* Don't try updating the passwd file if no data has changed. This allows thingsDavid Nugent1999-10-261-39/+102
| | | | | | like "pw usermod <name> -m" to work for non-local NIS users; since no attempt is made to update the password entry, the home directory will be created and populated as expected without error.
* Add new functionality "lock" and "unlock" to provide a simple passwordDavid Nugent1999-10-264-8/+47
| | | | | | locking mechanism for users. This works by prepending the string "*LOCKED*" to the password field in master.passwd to prevent successful decoding.
* Missed statement in password update relating to the previous changeDavid Nugent1999-10-261-1/+1
| | | | to fileupdate() which prevented pwd_mkdb(1) from being run.
* Clean up error handling in fileupdate(), which now returns 0 on successDavid Nugent1999-10-265-62/+117
| | | | | | | | | | | | instead of a boolean. This replicated through he front-end sub-functions relating to add, delete, modify entries in passwd & group files Errno is now preserved so output of errc()/warnc() will be less obfuscated by subsequent errors when reporting the problem. Add more intelligent error handling when attempting to modify/delete NIS entries with no corresponding local database entry. [MFC to stable in a couple of weeks to keep both in sync]
* Only do a full pwd_mkdb for deletions; other operations may use the -uSheldon Hearn1999-08-301-2/+6
| | | | | | | option as an optimization. PR: 13346 Submitted by: Neil Blakey-Milner <nbm@rucus.ru.ac.za>
* $Id$ -> $FreeBSD$Peter Wemm1999-08-2823-23/+23
|
* Remove some more warnings.David Nugent1999-07-282-4/+6
|
* Fix date parsing to allow '0' (none) date value.David Nugent1999-03-151-3/+2
|
* Add the ability to print user records in unix version 7 (old) format.David Nugent1999-03-022-11/+19
|
* Fix minor nit with command line parsing for pw -V DIR action.David Nugent1999-02-231-2/+2
|
* Fix tpyo (sic) and missing 'else' (bad cut n' paste).David Nugent1999-02-231-13/+13
|
* 1) Do not blindly ignore file update errors which may occur due to concurrentDavid Nugent1999-02-2314-155/+725
| | | | | | updating 2) Add -V <etcdir>, which allows maintaining user/group database in alternate locations other than /etc.
* Don't assume a_name is a number just because the first characterDag-Erling Smørgrav1999-02-081-2/+4
| | | | | | | is a digit. PR: bin/9484 Submitted by: Matthew D. Fuller <fullermd@futuresouth.com>
* Remove bogus file locking in main().David Nugent1999-01-081-13/+1
|
* -Clarification of last commit-Bill Fumerola1999-01-041-1/+1
| | | | | | | The char that the random letters and numbers are being pulled from is ended with a '\0'. Using sizeof() includes this '\0' in the 'pool' of possible characters. This patch decrements by one the size so we don't accidently end the new password prematurly.
* Let's make sure we're at the end of the password string before we apply a \0Bill Fumerola1999-01-021-2/+2
| | | | | | | | | and terminate it. This patch ensures passwords will be the correct length of 8, which is what is implied in the source (but not reflected in the man page). PR: bin/7817 Reviewed by: Alfred Perlstein <bright@hotjobs.com> Submitted by: Hiroshi Nishikawa <nis@pluto.dti.ne.jp>
* Fix the spelling of `FreeBSD'.Joerg Wunsch1998-12-271-2/+2
| | | | Submitted by: Peter Philipp <pjp@bsd-daemon.net>
* Remove useless `BINOWN=root' now that it is the default.David E. O'Brien1998-09-191-2/+1
|
* Fix inappropriate use of .Ql macro.Joseph Koshy1998-09-181-2/+2
| | | | | PR: docs/7905 Submitted by: kuma@jp.freebsd.org
* The `group{del,mod,show}' take require a '[group|gid]' argument.Joseph Koshy1998-08-311-1/+4
| | | | PR: docs/7788
* - On second thought, attempt to get the read-only lock, but don'tNate Williams1998-08-041-1/+16
| | | | | | | consider it a exit failure if it doesn't work. This means that root processes can safely get the lock, but normal processes can still use the 'pw' utility to get information (which may change out from under them.)
* - Removed read-only lock from 'pw'. This removes portions of the FIXNate Williams1998-08-041-22/+1
| | | | | | | | from PR/6787, but allow non-root users to use pw to get password information. However, this should be safe since the fixes for disallowing multiple instances from modifying the DB are still intact. Bug noted by: dima@best.net (Dima Ruban)
* Fix race condition in pw caused by multiple instances of pwd_mkdb beingNate Williams1998-07-163-7/+39
| | | | | | | | | | | | | | | | | run at the same time. Notes: The fileupdate function is still somewhat broken. Instead of returning a failure code if it can't modify the original file it renames the .new file and continues as though nothing is wrong. This will cause the lock on the original file to be lost and could lead to a similar race condition. I left that portion of the code alone since I feel that the maintainer of the code would have a better concept of how he wants to handle errors in that function than I do. PR: bin/6787 Submitted by: Craig Spannring <cts@internetcds.com>
* .Nm pw -> .Nm.Philippe Charnier1998-03-231-2/+2
|
* Overhaul this manpage - removing typos, awkward phrasing, and addressingSteve Price1998-02-141-111/+123
| | | | | | | a few technical faults. PR: 5692 Submitted by: dannyman@arh0300.urh.uiuc.edu
* pwd_mkdb option '-c' was renamed to -C some weeks ago.Wolfram Schneider1998-02-111-4/+4
| | | | | PR: bin/5715 Submitted by: dannyman <dannyman@arh0300.urh.uiuc.edu>
* Use consistent spelling,Tim Vanderhoek1997-12-251-2/+2
| | | | | | | | writeable -> writable (recall prior debate over this? :-) initialise -> initialize recognise -> recognize Merry Christmas! :)
* Use err(3) instead of local redefinition. Add rcsid string.Philippe Charnier1997-10-1017-216/+228
|
* Unquote default group in pw.conf.David Nugent1997-09-011-1/+2
| | | | | PR: 4365 Submitted by: "Andrew L. Moore" <alm@mclink.com>
* Fix -p switch.David Nugent1997-08-011-2/+2
|
* getuid() -> geteuid().David Nugent1997-07-171-2/+2
|
* Remove srandomdev fallback codeAndrey A. Chernov1997-06-141-5/+7
|
* Fixes skeleton directory test-it-is-a-directory logic.David Nugent1997-05-241-2/+2
| | | | | | | PR: 3666 Reviewed by: Submitted by: iaint@css.tuu.utas.edu.au Obtained from:
* Initialize RNG only onceAndrey A. Chernov1997-03-241-23/+18
| | | | Use srandomdev() now
* Fix srandom arg according to Lite2Andrey A. Chernov1997-03-111-3/+3
|
* Typo fix 'and' -> 'an'.Daniel O'Callaghan1997-03-041-2/+2
| | | | This is a 2.2 candidate.
* Back out MAXLOGNAME fix, Bruce points that copyinstr require NULAndrey A. Chernov1997-03-031-2/+2
|
* Fix MAXLOGNAME usage, the code has wrong assumption thatAndrey A. Chernov1997-03-021-3/+3
| | | | it must be NUL terminated
* Revert $FreeBSD$ to $Id$Peter Wemm1997-02-2222-22/+22
|
* Yet another formatting consistency check.David Nugent1997-02-071-1/+1
|
* Fix useage of MAXLOGNAME to include terminating NUL, by usingDavid Nugent1997-02-072-3/+12
| | | | | max(MAXLOGNAME-1,UT_NAMESIZE). Tidy up "pretty" printing format for longer usernames.
* Sort cross references.Wolfram Schneider1997-01-202-4/+4
|
* Make the long-awaited change from $Id$ to $FreeBSD$Jordan K. Hubbard1997-01-1422-22/+22
| | | | | | | | This will make a number of things easier in the future, as well as (finally!) avoiding the Id-smashing problem which has plagued developers for so long. Boy, I'm glad we're not using sup anymore. This update would have been insane otherwise.
* Adds optional NIS passwd file updating and optionally rebuildingDavid Nugent1997-01-058-22/+202
| | | | | | NIS maps. Suggested by: Peter Wemm
* Remove duplicated #include.David Nugent1997-01-051-2/+1
|