History log of /openbsd-current/include/pwd.h
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 1.26 13-Sep-2018 millert

Add uid_from_user() and gid_from_group(), derived from pax's cache.c.
It replaces the existing pwcache.c functions user_from_uid(3) and
group_from_gid(3) with the pax equivalents. Adapted from NetBSD
(mycroft) changes from our own pax's cache.c. OK guenther@


Revision tags: OPENBSD_6_1_BASE OPENBSD_6_2_BASE OPENBSD_6_3_BASE
# 1.25 09-Mar-2017 fcambus

As per style.9, prototypes should not have variable names associated
with the types.

OK jca@


Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE
# 1.24 18-Nov-2015 tedu

Add _shadow variants to the two popular getpw functions (uid and nam).
This version of the function will always open the secure/shadow/master
password files. Soon, the regular variants of these functions will not.
(Intermixing shadow and regular gets a little weird; don't do that.)
Not using struct spwd and getspwnam functions to reduce churn in callers.
Should just be a one line diff in most places.
ok deraadt


Revision tags: OPENBSD_5_6_BASE OPENBSD_5_7_BASE OPENBSD_5_8_BASE
# 1.23 16-May-2014 tedu

add prototypes for new crypt functions


# 1.22 12-May-2014 tedu

no md5crypt


Revision tags: OPENBSD_5_3_BASE OPENBSD_5_4_BASE OPENBSD_5_5_BASE
# 1.21 05-Dec-2012 deraadt

Remove excessive sys/cdefs.h inclusion
ok guenther millert kettenis


Revision tags: OPENBSD_4_4_BASE OPENBSD_4_5_BASE OPENBSD_4_6_BASE OPENBSD_4_7_BASE OPENBSD_4_8_BASE OPENBSD_4_9_BASE OPENBSD_5_0_BASE OPENBSD_5_1_BASE OPENBSD_5_2_BASE
# 1.20 25-Jun-2008 millert

Add _PW_BUF_LEN define and use it instead of hard-coding 1024 for
the buffer size. OK deraadt@


# 1.19 24-Jun-2008 deraadt

prototypes for getpwnam_r() and getpwuid_r()


Revision tags: OPENBSD_3_9_BASE OPENBSD_4_0_BASE OPENBSD_4_1_BASE OPENBSD_4_2_BASE OPENBSD_4_3_BASE
# 1.18 13-Dec-2005 millert

First step in include files overhaul. Use __FOO_VISIBLE (as defined
in sys/cdefs.h) instead of _FOO_SOURCE. Also fix several namespace
pollution issues, including the byte order defines. OK deraadt@


Revision tags: OPENBSD_3_6_BASE OPENBSD_3_7_BASE OPENBSD_3_8_BASE
# 1.17 13-Jul-2004 millert

passwd.conf has been deprecated since login.conf was imported.
Today it finally dies. Based on a diff from Gabriel Kihlman.


# 1.16 06-Apr-2004 djm

prototypes for bcrypt and md5crypt, as described in manpage; ok deraadt@


Revision tags: OPENBSD_3_4_BASE OPENBSD_3_5_BASE
# 1.15 02-Jun-2003 millert

Remove the advertising clause in the UCB license which Berkeley
rescinded 22 July 1999. Proofed by myself and Theo.


Revision tags: OPENBSD_3_2_BASE OPENBSD_3_3_BASE
# 1.14 22-Apr-2002 millert

Fix 2 things that should be gid_t. One from Oleg Safiullin, one from me...


Revision tags: OPENBSD_3_1_BASE
# 1.13 16-Feb-2002 millert

Part one of userland __P removal. Done with a simple regexp with some minor hand editing to make comments line up correctly. Another pass is forthcoming that handles the cases that could not be done automatically.


Revision tags: OPENBSD_3_0_BASE
# 1.12 26-Aug-2001 millert

Change the second arg to pw_mkdb() from a boolean flag to a set of
bit flags ORed together. Currently the only flags defined are
_PASSWORD_SECUREONLY and _PASSWORD_OMITV7 but this is enough to
cause pw_mkdb() to run pwd_mkdb with the options we want.

With this change we no longer generate the old V7 passwd file when
only the extra fields in master.passwd (or the encrypted password)
have changed. There are other programs that could probably use
the _PASSWORD_OMITV7 flag; they will be converted at a future date.


Revision tags: OPENBSD_2_9_BASE
# 1.11 13-Feb-2001 pjanzen

_PW_NAME_LEN doesn't include the NUL, MAXLOGNAME does.


# 1.10 31-Jan-2001 deraadt

move utmp to large format, usernames to 32 chars; downsj


# 1.9 21-Nov-2000 millert

Add pw_dup(3), a function to copy 'struct passwd'. It is allocated as
a single chunk with the strings pointing elsewhere in the buffer so
a simple free() of the struct passwd * is all that is needed to decallocate.


Revision tags: OPENBSD_2_6_BASE OPENBSD_2_7_BASE OPENBSD_2_8_BASE
# 1.8 03-Sep-1999 deraadt

proto bcrypt_gensalt()


# 1.7 01-Sep-1999 deraadt

proto bcrypt_gensalt()


Revision tags: OPENBSD_2_4_BASE OPENBSD_2_5_BASE
# 1.6 15-Jul-1998 millert

pw_uid is uid_t, pw_gid is gid_t


Revision tags: OPENBSD_2_1_BASE OPENBSD_2_2_BASE OPENBSD_2_3_BASE
# 1.5 16-Feb-1997 provos

small cleanup


# 1.4 14-Feb-1997 provos

passwd.conf define.


# 1.3 16-Oct-1996 downsj

_PW_YPTOKEN


Revision tags: OPENBSD_2_0_BASE
# 1.2 22-May-1996 deraadt

libutil


# 1.1 18-Oct-1995 deraadt

branches: 1.1.1;
Initial revision


Revision tags: OPENBSD_6_1_BASE OPENBSD_6_2_BASE
# 1.25 09-Mar-2017 fcambus

As per style.9, prototypes should not have variable names associated
with the types.

OK jca@


Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE
# 1.24 18-Nov-2015 tedu

Add _shadow variants to the two popular getpw functions (uid and nam).
This version of the function will always open the secure/shadow/master
password files. Soon, the regular variants of these functions will not.
(Intermixing shadow and regular gets a little weird; don't do that.)
Not using struct spwd and getspwnam functions to reduce churn in callers.
Should just be a one line diff in most places.
ok deraadt


Revision tags: OPENBSD_5_6_BASE OPENBSD_5_7_BASE OPENBSD_5_8_BASE
# 1.23 16-May-2014 tedu

add prototypes for new crypt functions


# 1.22 12-May-2014 tedu

no md5crypt


Revision tags: OPENBSD_5_3_BASE OPENBSD_5_4_BASE OPENBSD_5_5_BASE
# 1.21 05-Dec-2012 deraadt

Remove excessive sys/cdefs.h inclusion
ok guenther millert kettenis


Revision tags: OPENBSD_4_4_BASE OPENBSD_4_5_BASE OPENBSD_4_6_BASE OPENBSD_4_7_BASE OPENBSD_4_8_BASE OPENBSD_4_9_BASE OPENBSD_5_0_BASE OPENBSD_5_1_BASE OPENBSD_5_2_BASE
# 1.20 25-Jun-2008 millert

Add _PW_BUF_LEN define and use it instead of hard-coding 1024 for
the buffer size. OK deraadt@


# 1.19 24-Jun-2008 deraadt

prototypes for getpwnam_r() and getpwuid_r()


Revision tags: OPENBSD_3_9_BASE OPENBSD_4_0_BASE OPENBSD_4_1_BASE OPENBSD_4_2_BASE OPENBSD_4_3_BASE
# 1.18 13-Dec-2005 millert

First step in include files overhaul. Use __FOO_VISIBLE (as defined
in sys/cdefs.h) instead of _FOO_SOURCE. Also fix several namespace
pollution issues, including the byte order defines. OK deraadt@


Revision tags: OPENBSD_3_6_BASE OPENBSD_3_7_BASE OPENBSD_3_8_BASE
# 1.17 13-Jul-2004 millert

passwd.conf has been deprecated since login.conf was imported.
Today it finally dies. Based on a diff from Gabriel Kihlman.


# 1.16 06-Apr-2004 djm

prototypes for bcrypt and md5crypt, as described in manpage; ok deraadt@


Revision tags: OPENBSD_3_4_BASE OPENBSD_3_5_BASE
# 1.15 02-Jun-2003 millert

Remove the advertising clause in the UCB license which Berkeley
rescinded 22 July 1999. Proofed by myself and Theo.


Revision tags: OPENBSD_3_2_BASE OPENBSD_3_3_BASE
# 1.14 22-Apr-2002 millert

Fix 2 things that should be gid_t. One from Oleg Safiullin, one from me...


Revision tags: OPENBSD_3_1_BASE
# 1.13 16-Feb-2002 millert

Part one of userland __P removal. Done with a simple regexp with some minor hand editing to make comments line up correctly. Another pass is forthcoming that handles the cases that could not be done automatically.


Revision tags: OPENBSD_3_0_BASE
# 1.12 26-Aug-2001 millert

Change the second arg to pw_mkdb() from a boolean flag to a set of
bit flags ORed together. Currently the only flags defined are
_PASSWORD_SECUREONLY and _PASSWORD_OMITV7 but this is enough to
cause pw_mkdb() to run pwd_mkdb with the options we want.

With this change we no longer generate the old V7 passwd file when
only the extra fields in master.passwd (or the encrypted password)
have changed. There are other programs that could probably use
the _PASSWORD_OMITV7 flag; they will be converted at a future date.


Revision tags: OPENBSD_2_9_BASE
# 1.11 13-Feb-2001 pjanzen

_PW_NAME_LEN doesn't include the NUL, MAXLOGNAME does.


# 1.10 31-Jan-2001 deraadt

move utmp to large format, usernames to 32 chars; downsj


# 1.9 21-Nov-2000 millert

Add pw_dup(3), a function to copy 'struct passwd'. It is allocated as
a single chunk with the strings pointing elsewhere in the buffer so
a simple free() of the struct passwd * is all that is needed to decallocate.


Revision tags: OPENBSD_2_6_BASE OPENBSD_2_7_BASE OPENBSD_2_8_BASE
# 1.8 03-Sep-1999 deraadt

proto bcrypt_gensalt()


# 1.7 01-Sep-1999 deraadt

proto bcrypt_gensalt()


Revision tags: OPENBSD_2_4_BASE OPENBSD_2_5_BASE
# 1.6 15-Jul-1998 millert

pw_uid is uid_t, pw_gid is gid_t


Revision tags: OPENBSD_2_1_BASE OPENBSD_2_2_BASE OPENBSD_2_3_BASE
# 1.5 16-Feb-1997 provos

small cleanup


# 1.4 14-Feb-1997 provos

passwd.conf define.


# 1.3 16-Oct-1996 downsj

_PW_YPTOKEN


Revision tags: OPENBSD_2_0_BASE
# 1.2 22-May-1996 deraadt

libutil


# 1.1 18-Oct-1995 deraadt

branches: 1.1.1;
Initial revision