Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Validate input of pw usermod -h and pwusermod -H | Baptiste Daroussin | 2015-07-04 | 1 | -0/+30 |
| | | | | | | | Push the code that set the password into a separate function to improve readability Add regression tests about pw usermod -h and pw usermod -H | ||||
* | backout remove of -q option for pw [user|group] next | Baptiste Daroussin | 2015-06-08 | 1 | -3/+5 |
| | | | | | | While the return code is broken, some corner case usage depends on the functionnality, so backout until we get better regression tests covering those corner case usage. | ||||
* | Fix mistakes than came along with r284139 | Baptiste Daroussin | 2015-06-07 | 1 | -2/+2 |
| | |||||
* | Remove '-q' support for pw [user|group] next | Baptiste Daroussin | 2015-06-07 | 1 | -5/+3 |
| | | | | | | the intent of -q in this command is to return as exit status the value of the next group/user id, which does not make sense given exit status are limited to values between 0 and 255. | ||||
* | Fix setting uid/gid min/max via pw | Baptiste Daroussin | 2015-06-07 | 1 | -4/+13 |
| | |||||
* | Fix generating configuration file | Baptiste Daroussin | 2015-06-07 | 1 | -1/+2 |
| | |||||
* | Fix duplicate checking | Baptiste Daroussin | 2015-06-07 | 1 | -0/+4 |
| | |||||
* | In case of rename validate the length of the new name | Baptiste Daroussin | 2015-06-07 | 1 | -0/+5 |
| | | | | Check early that the new name fits MAXLOGNAME and store it in pwconf | ||||
* | Refactor input validation | Baptiste Daroussin | 2015-06-07 | 1 | -6/+43 |
| | | | | | Mutualize code to validate inputs of both 'user' and 'group' command Test that the input name fits into MAXLOGNAME | ||||
* | Handle -7 via gloval pwconf | Baptiste Daroussin | 2015-06-07 | 1 | -0/+3 |
| | |||||
* | Initialize conf using menset(3) | Baptiste Daroussin | 2015-06-07 | 1 | -3/+1 |
| | |||||
* | Handle pretty print (-P) via global pwconf | Baptiste Daroussin | 2015-06-07 | 1 | -0/+4 |
| | |||||
* | Handle dryrun (-N) via global pwconf | Baptiste Daroussin | 2015-06-07 | 1 | -1/+5 |
| | |||||
* | Handle -C and -Y locally and stop adding them to arglist | Baptiste Daroussin | 2015-06-07 | 1 | -5/+15 |
| | |||||
* | Add a new global struct pwconf to store etcpath, rootdir and struct userconf | Baptiste Daroussin | 2015-06-07 | 1 | -30/+26 |
| | | | | | Do not add anymore -R and -V to arglist Add an error message if both -V and -R are set in arguments | ||||
* | New pw -R rootdir option | Baptiste Daroussin | 2015-06-03 | 1 | -27/+52 |
| | | | | | | | | This allows to set an alternate root directory in which the users/groups will be manipulated Requested by: gjb, ian Tested by: gjb | ||||
* | Use asprintf instead of malloc + snprintf and test the memory allocation | Baptiste Daroussin | 2015-05-31 | 1 | -2/+3 |
| | |||||
* | Fix wrong message when using pw -V with a non existent directory | Baptiste Daroussin | 2014-11-12 | 1 | -0/+8 |
| | | | | | | | Add a regression test about it PR: 194971 Submitted by: Freddy DISSAUX <bugzilla@dsx.bsdsx.fr> | ||||
* | Teach pw(8) about how to use pw/gr API to reduce code duplication | Baptiste Daroussin | 2012-10-30 | 1 | -4/+0 |
| | | | | MFC after: 2 months | ||||
* | Add the groupmod '-d' option to pw to allow the deletion of existing users | Sean Farley | 2008-02-23 | 1 | -1/+2 |
| | | | | | | | | | | from a group without the need to perform the same operation by replacing the existing list via the '-M' option. The '-M' option requires someone to fetch the existing members with pw, deleting the undesired members from the list and sending the altered list back to pw. Approved by: wes (mentor) MFC after: 5 days | ||||
* | style(9) (verified no object changes) | Sean Farley | 2008-02-23 | 1 | -1/+1 |
| | | | | | Approved by: wes (mentor) MFC after: 5 days | ||||
* | Add home directory creation mode to pw.conf(5) and be a bit | Lukas Ertl | 2007-03-30 | 1 | -0/+1 |
| | | | | more specific about the effect of the current umask on -M. | ||||
* | Add -M argument to usage() output. | Lukas Ertl | 2007-03-30 | 1 | -0/+2 |
| | |||||
* | Introduce the new option -M to allow to set the permissions of | Lukas Ertl | 2007-03-26 | 1 | -3/+2 |
| | | | | | | | | the user's newly created home directory. If omitted, it's derived from the current umask. PR: bin/16880, bin/83253 (partially), bin/104248 MFC in: 1 month | ||||
* | o Fix groupadd getopt line and make 'pw groupadd -o' work. | Maxim Konovalov | 2006-09-18 | 1 | -1/+1 |
| | | | | | | PR: bin/100684 Submitted by: Devon H. O'Dell MFC after: 3 weeks | ||||
* | Add a `-H <fd>' option that is like `-h <fd>', but accepts an already | Ian Dowse | 2004-01-11 | 1 | -4/+6 |
| | | | | | | | encrypted password on the specified file descriptor. PR: bin/22033 MFC after: 2 weeks | ||||
* | Fix the type of the NULL arg to execl() | Brian Somers | 2001-07-09 | 1 | -1/+1 |
| | | | | Idea from: Theo de Raadt <deraadt@openbsd.org> | ||||
* | Fix a harmless format string bogon and mark a function as __printflike(). | Kris Kennaway | 2001-07-05 | 1 | -1/+1 |
| | | | | | | | There is still one instance of non-constant format string use inside that function, but it's hard to fix. MFC after: 1 week | ||||
* | Document the lock and unlock commands. This fixes a segmentation fault. | Dima Dorfman | 2001-03-14 | 1 | -0/+10 |
| | | | | | PR: 25187 Approved by: nik | ||||
* | Convert to use the <sys/queue.h> macros rather than fiddling with the queue | Ben Smithurst | 2000-12-29 | 1 | -2/+2 |
| | | | | | | structure internals. Reviewed by: markm | ||||
* | Add `_PATH_DEVZERO'. | David E. O'Brien | 2000-12-09 | 1 | -1/+1 |
| | | | | Use _PATH_* where where possible. | ||||
* | Localize ctype too. | Andrey A. Chernov | 2000-06-24 | 1 | -1/+1 |
| | | | | Add weekday to showuser expired fields | ||||
* | Localize time/date. | Andrey A. Chernov | 2000-06-22 | 1 | -0/+3 |
| | | | | | Use ISO 8601 date in logs. Fix wrong argument type in ctype functions. | ||||
* | Be a little more strict about handling command line args. This allows user and | David Nugent | 2000-06-18 | 1 | -4/+6 |
| | | | | | | group names like 'help' 'mod' 'user' 'group' etc. to work correctly without requiring the -n style invocation. PR: misc/17069 | ||||
* | Portability fixes for other bsd4.4 derivatives. | David Nugent | 2000-01-15 | 1 | -1/+4 |
| | |||||
* | Add new functionality "lock" and "unlock" to provide a simple password | David Nugent | 1999-10-26 | 1 | -4/+10 |
| | | | | | | locking mechanism for users. This works by prepending the string "*LOCKED*" to the password field in master.passwd to prevent successful decoding. | ||||
* | $Id$ -> $FreeBSD$ | Peter Wemm | 1999-08-28 | 1 | -1/+1 |
| | |||||
* | Add the ability to print user records in unix version 7 (old) format. | David Nugent | 1999-03-02 | 1 | -3/+4 |
| | |||||
* | Fix minor nit with command line parsing for pw -V DIR action. | David Nugent | 1999-02-23 | 1 | -2/+2 |
| | |||||
* | Fix tpyo (sic) and missing 'else' (bad cut n' paste). | David Nugent | 1999-02-23 | 1 | -13/+13 |
| | |||||
* | 1) Do not blindly ignore file update errors which may occur due to concurrent | David Nugent | 1999-02-23 | 1 | -16/+96 |
| | | | | | | updating 2) Add -V <etcdir>, which allows maintaining user/group database in alternate locations other than /etc. | ||||
* | Remove bogus file locking in main(). | David Nugent | 1999-01-08 | 1 | -13/+1 |
| | |||||
* | - On second thought, attempt to get the read-only lock, but don't | Nate Williams | 1998-08-04 | 1 | -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 FIX | Nate Williams | 1998-08-04 | 1 | -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 being | Nate Williams | 1998-07-16 | 1 | -2/+23 |
| | | | | | | | | | | | | | | | | | 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> | ||||
* | Use err(3) instead of local redefinition. Add rcsid string. | Philippe Charnier | 1997-10-10 | 1 | -52/+26 |
| | |||||
* | getuid() -> geteuid(). | David Nugent | 1997-07-17 | 1 | -2/+2 |
| | |||||
* | Revert $FreeBSD$ to $Id$ | Peter Wemm | 1997-02-22 | 1 | -1/+1 |
| | |||||
* | Fix useage of MAXLOGNAME to include terminating NUL, by using | David Nugent | 1997-02-07 | 1 | -1/+1 |
| | | | | | max(MAXLOGNAME-1,UT_NAMESIZE). Tidy up "pretty" printing format for longer usernames. | ||||
* | Make the long-awaited change from $Id$ to $FreeBSD$ | Jordan K. Hubbard | 1997-01-14 | 1 | -1/+1 |
| | | | | | | | | 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. |