]> granicus.if.org Git - shadow/log
shadow
15 years ago * src/newgrp.c: Close the databases before changing the UDI and
nekral-guest [Sun, 26 Apr 2009 17:11:38 +0000 (17:11 +0000)]
* src/newgrp.c: Close the databases before changing the UDI and
GID.

15 years ago * libmisc/myname.c: Updated splint annotations.
nekral-guest [Sun, 26 Apr 2009 17:10:49 +0000 (17:10 +0000)]
* libmisc/myname.c: Updated splint annotations.

15 years ago * lib/commonio.c: Added splint annotations.
nekral-guest [Sun, 26 Apr 2009 16:48:51 +0000 (16:48 +0000)]
* lib/commonio.c: Added splint annotations.
* lib/commonio.c: old_context should be local to commonio_close(),
not global.

15 years ago * src/passwd.c: Do not freecon strings duplicated with strdup.
nekral-guest [Sun, 26 Apr 2009 16:44:54 +0000 (16:44 +0000)]
* src/passwd.c: Do not freecon strings duplicated with strdup.
Also avoid allocation of memory.
* src/passwd.c: Use SYSLOG instead of syslog.

15 years agoUpdated Czech translation
bubulle [Sun, 26 Apr 2009 12:26:10 +0000 (12:26 +0000)]
Updated Czech translation

15 years agoUpdated splint annotations.
nekral-guest [Sat, 25 Apr 2009 15:18:49 +0000 (15:18 +0000)]
Updated splint annotations.

15 years agoUpdated splint annotations.
nekral-guest [Sat, 25 Apr 2009 14:16:22 +0000 (14:16 +0000)]
Updated splint annotations.

15 years ago * lib/commonio.c: Do not assumes eptr is always notnull.
nekral-guest [Sat, 25 Apr 2009 13:41:52 +0000 (13:41 +0000)]
* lib/commonio.c: Do not assumes eptr is always notnull.
Updated splint annotations.

15 years agoUpdated splint annotations.
nekral-guest [Sat, 25 Apr 2009 13:13:50 +0000 (13:13 +0000)]
Updated splint annotations.

15 years ago * lib/commonio.h, lib/commonio.c: Added splint annotations.
nekral-guest [Sat, 25 Apr 2009 12:43:27 +0000 (12:43 +0000)]
* lib/commonio.h, lib/commonio.c: Added splint annotations.

15 years ago * NEWS, po/pt.po: Updated Portuguese translation.
nekral-guest [Sat, 25 Apr 2009 11:06:35 +0000 (11:06 +0000)]
* NEWS, po/pt.po: Updated Portuguese translation.

15 years ago * libmisc/copydir.c: Added splint annotations.
nekral-guest [Fri, 24 Apr 2009 23:41:28 +0000 (23:41 +0000)]
* libmisc/copydir.c: Added splint annotations.
* libmisc/copydir.c: Added assert to help splint.
* libmisc/copydir.c: Free allocated structures in cas of failure.
* libmisc/copydir.c: Avoid implicit conversion of pointers to
booleans.
* libmisc/copydir.c: Use buffers of size PATH_MAX instead of 1024
for filenames.
* libmisc/copydir.c: Use fchmod and fchown to change the mode of
the opened file.
* libmisc/copydir.c: Indicate the mode to open(), even if we chmod
later.

15 years ago * lib/prototypes.h: Added prototypes of getulong() and get_pid().
nekral-guest [Fri, 24 Apr 2009 23:35:57 +0000 (23:35 +0000)]
* lib/prototypes.h: Added prototypes of getulong() and get_pid().
* lib/prototypes.h: Added splint annotations.

15 years ago * lib/commonio.c: Use get_pid() instead of strtol.
nekral-guest [Fri, 24 Apr 2009 23:35:01 +0000 (23:35 +0000)]
* lib/commonio.c: Use get_pid() instead of strtol.
* lib/commonio.c: Replace an int by a size_t.

15 years ago * lib/commonio.h: Added splint annotations.
nekral-guest [Fri, 24 Apr 2009 23:33:47 +0000 (23:33 +0000)]
* lib/commonio.h: Added splint annotations.

15 years ago * lib/sgroupio.c: Free allocated structures on failure.
nekral-guest [Fri, 24 Apr 2009 23:32:52 +0000 (23:32 +0000)]
* lib/sgroupio.c: Free allocated structures on failure.
* lib/sgroupio.c: Added splint annotations.

15 years ago * lib/Makefile.am, lib/get_pid.c, lib/getulong.c: Added get_pid()
nekral-guest [Fri, 24 Apr 2009 23:28:15 +0000 (23:28 +0000)]
* lib/Makefile.am, lib/get_pid.c, lib/getulong.c: Added get_pid()
and getulong().

15 years ago * lib/getlong.c: Do not check for NULL string but empty string.
nekral-guest [Fri, 24 Apr 2009 23:27:12 +0000 (23:27 +0000)]
* lib/getlong.c: Do not check for NULL string but empty string.

15 years ago * lib/groupio.c: Updated splint annotations.
nekral-guest [Fri, 24 Apr 2009 23:26:31 +0000 (23:26 +0000)]
* lib/groupio.c: Updated splint annotations.
* lib/groupio.c: Added assert to help splint.

15 years ago * src/useradd.c: Check assumptions on snprintf().
nekral-guest [Fri, 24 Apr 2009 23:23:51 +0000 (23:23 +0000)]
* src/useradd.c: Check assumptions on snprintf().
* src/useradd.c: Replace peror by an strerror and avoid an
intermediate buffer.
* src/useradd.c: Save errno between the failure and the report by
perror/strerror.
* src/useradd.c: Prefer xmalloc to malloc.

15 years ago * src/lastlog.c: Remove function calls from within assert().
nekral-guest [Fri, 24 Apr 2009 23:05:29 +0000 (23:05 +0000)]
* src/lastlog.c: Remove function calls from within assert().

15 years ago * libmisc/obscure.c: Change some int to size_t.
nekral-guest [Fri, 24 Apr 2009 23:04:27 +0000 (23:04 +0000)]
* libmisc/obscure.c: Change some int to size_t.

15 years ago * libmisc/console.c: Use a less disturbing construct for splint.
nekral-guest [Fri, 24 Apr 2009 23:03:14 +0000 (23:03 +0000)]
* libmisc/console.c: Use a less disturbing construct for splint.

15 years ago * libmisc/limits.c: Parse the limits, umask, nice, maxlogin, file
nekral-guest [Fri, 24 Apr 2009 22:56:42 +0000 (22:56 +0000)]
* libmisc/limits.c: Parse the limits, umask, nice, maxlogin, file
limit with getlog() / getulong(). This also means, in case of
non-PAM enabled systems, that the umask specified on the GECOS
fields should start with a 0 if specified in octal. (it used to be
force to octal). Do the appropriate cast and range checking.

15 years ago * libmisc/salt.c: In case gettimeofday() fails, get some entropy
nekral-guest [Fri, 24 Apr 2009 22:49:20 +0000 (22:49 +0000)]
* libmisc/salt.c: In case gettimeofday() fails, get some entropy
from the PID.

15 years ago * libmisc/setupenv.c: Prefer snprintf to sprintf, even if a small
nekral-guest [Fri, 24 Apr 2009 22:46:06 +0000 (22:46 +0000)]
* libmisc/setupenv.c: Prefer snprintf to sprintf, even if a small
context indicates no issues.
* libmisc/setupenv.c: Avoid implicit conversion of pointers to
booleans.

15 years ago * libmisc/loginprompt.c: Prefer snprintf to sprintf, even if a
nekral-guest [Fri, 24 Apr 2009 22:27:58 +0000 (22:27 +0000)]
* libmisc/loginprompt.c: Prefer snprintf to sprintf, even if a
small context indicates no issues.

15 years ago * src/faillog.c: Remove function calls from within assert().
nekral-guest [Fri, 24 Apr 2009 22:27:09 +0000 (22:27 +0000)]
* src/faillog.c: Remove function calls from within assert().

15 years ago * libmisc/mail.c: Ignore the return value of puts().
nekral-guest [Fri, 24 Apr 2009 22:22:57 +0000 (22:22 +0000)]
* libmisc/mail.c: Ignore the return value of puts().
* libmisc/mail.c: Prefer snprintf to sprintf, even if a small
context indicates no issues.

15 years ago * lib/commonio.c, lib/commonio.h, lib/groupio.c, lib/groupio.h,
nekral-guest [Thu, 23 Apr 2009 21:19:02 +0000 (21:19 +0000)]
* lib/commonio.c, lib/commonio.h, lib/groupio.c, lib/groupio.h,
lib/pwio.c, lib/pwio.h, lib/shadowio.c, lib/shadowio.h: Added
splint annotations. The *_locate() and *_next() functions
currently return an observer. As the structure are often modified
by the caller, it could maybe be changed to exposed later. (and
non-const).

15 years ago * lib/pwauth.c: Use a boolean for wipe_clear_pass and use_skey.
nekral-guest [Thu, 23 Apr 2009 20:46:01 +0000 (20:46 +0000)]
* lib/pwauth.c: Use a boolean for wipe_clear_pass and use_skey.
* lib/pwauth.c: Added splint annotations.
* lib/pwauth.c: Added brackets and parenthesis.
* lib/pwauth.c: Avoid assignments in comparisons.
* lib/pwauth.c: Avoid implicit conversion of pointers or
characters to booleans.

15 years ago * src/groupmod.c: Cast ID to ulongs and use ulong formats for IDs.
nekral-guest [Thu, 23 Apr 2009 20:39:29 +0000 (20:39 +0000)]
* src/groupmod.c: Cast ID to ulongs and use ulong formats for IDs.

15 years ago * src/newgrp.c: Added splint annotations.
nekral-guest [Thu, 23 Apr 2009 20:37:00 +0000 (20:37 +0000)]
* src/newgrp.c: Added splint annotations.
* src/newgrp.c: audit_buf is only used in newgrp. Make it static.
* src/newgrp.c: Ignore the return value of fputs().
* src/newgrp.c: Use exit(EXIT_FAILURE) instead of exit(1).

15 years ago * libmisc/pwdcheck.c (passwd_check): The progname is not used.
nekral-guest [Thu, 23 Apr 2009 20:17:02 +0000 (20:17 +0000)]
* libmisc/pwdcheck.c (passwd_check): The progname is not used.
* libmisc/pwdcheck.c: Ignore the return value of sleep().
* libmisc/pwdcheck.c: Use exit(EXIT_FAILURE) instead of exit(1).

15 years ago * libmisc/setupenv.c: Avoid assignments in comparisons.
nekral-guest [Thu, 23 Apr 2009 17:45:42 +0000 (17:45 +0000)]
* libmisc/setupenv.c: Avoid assignments in comparisons.
* libmisc/setupenv.c: Added brackets and parenthesis.
* libmisc/setupenv.c: Ignore the return value of fclose (file
opened read-only)
* libmisc/setupenv.c: Ignore the return value of puts().
* libmisc/setupenv.c:Avoid implicit conversion of pointers to
booleans.

15 years ago * libmisc/find_new_gid.c, libmisc/find_new_uid.c,
nekral-guest [Thu, 23 Apr 2009 17:43:27 +0000 (17:43 +0000)]
* libmisc/find_new_gid.c, libmisc/find_new_uid.c,
libmisc/isexpired.c, src/groupadd.c, lib/pwauth.h, lib/groupmem.c,
lib/shadowmem.c, lib/pwmem.c, lib/prototypes.h: Added splint
annotations.

15 years ago * libmisc/loginprompt.c: Use exit(EXIT_FAILURE) instead of
nekral-guest [Thu, 23 Apr 2009 17:34:46 +0000 (17:34 +0000)]
* libmisc/loginprompt.c: Use exit(EXIT_FAILURE) instead of
exit(1).
* libmisc/loginprompt.c: Avoid implicit conversion of pointers to
booleans.
* libmisc/loginprompt.c: Ignore return value of putc().

15 years ago * libmisc/env.c, libmisc/age.c: Added splint annotations.
nekral-guest [Thu, 23 Apr 2009 17:33:21 +0000 (17:33 +0000)]
* libmisc/env.c, libmisc/age.c: Added splint annotations.
* libmisc/age.c: Added brackets and parenthesis.
* libmisc/age.c: Ignore the return value of fclose (file opened
read-only)
* libmisc/age.c: Ignore puts() return value.
* libmisc/age.c: Use exit(EXIT_FAILURE) instead of exit(1).
* libmisc/age.c: Avoid assignments in comparisons.

15 years ago * lib/fputsx.c, lib/gshadow.c, lib/commonio.h: Added splint
nekral-guest [Thu, 23 Apr 2009 11:54:30 +0000 (11:54 +0000)]
* lib/fputsx.c, lib/gshadow.c, lib/commonio.h: Added splint
annotations.

15 years ago * lib/gshadow.c, lib/commonio.h: Added splint annotations.
nekral-guest [Thu, 23 Apr 2009 11:53:55 +0000 (11:53 +0000)]
* lib/gshadow.c, lib/commonio.h: Added splint annotations.

15 years ago * lib/getdef.c: Added splint annotations.
nekral-guest [Thu, 23 Apr 2009 11:46:46 +0000 (11:46 +0000)]
* lib/getdef.c: Added splint annotations.
* lib/getdef.c: Ignore fputs() return value.
* lib/getdef.c: Use EXIT_FAILURE / EXIT_SUCCESS for exit()

15 years ago * lib/get_gid.c: gidstr should not be NULL, but the check was
nekral-guest [Thu, 23 Apr 2009 11:46:06 +0000 (11:46 +0000)]
* lib/get_gid.c: gidstr should not be NULL, but the check was
meant to make sure it is not empty.
* lib/get_uid.c: Likewise.

15 years ago * src/faillog.c: Added splint annotations.
nekral-guest [Thu, 23 Apr 2009 11:23:53 +0000 (11:23 +0000)]
* src/faillog.c: Added splint annotations.
* src/faillog.c: Cast ID to ulongs and use ulong formats for IDs.
* src/faillog.c: Ignore fflush() return value.
* src/faillog.c: Added parenthesis.

15 years ago * src/grpck.c: Ignore puts return value.
nekral-guest [Thu, 23 Apr 2009 11:21:57 +0000 (11:21 +0000)]
* src/grpck.c: Ignore puts return value.
* src/grpck.c: Avoid variable format string.

15 years ago * src/lastlog.c: Use EXIT_FAILURE / EXIT_SUCCESS for exit()
nekral-guest [Thu, 23 Apr 2009 11:21:01 +0000 (11:21 +0000)]
* src/lastlog.c: Use EXIT_FAILURE / EXIT_SUCCESS for exit()
* src/lastlog.c: Added splint annotations.
* src/lastlog.c: Avoid global pwent.
* src/lastlog.c: Cast ID to ulongs and use ulong formats for IDs.
* src/lastlog.c: Avoid assignment in comparisons.
* src/lastlog.c: Ignore fclose() return value since the file is
only opened for reading.

15 years ago * src/newgrp.c: Added assertion to guide splint (and me).
nekral-guest [Thu, 23 Apr 2009 11:17:22 +0000 (11:17 +0000)]
* src/newgrp.c: Added assertion to guide splint (and me).

15 years ago * libmisc/find_new_gid.c: Use booleans instead of char fo
nekral-guest [Thu, 23 Apr 2009 11:16:38 +0000 (11:16 +0000)]
* libmisc/find_new_gid.c: Use booleans instead of char fo
used_gids.
* libmisc/find_new_gid.c: Use getdef_ulong and cast to git_t to
get GID values.
* libmisc/find_new_gid.c: Use UL as a prefix for ulong values.
* libmisc/find_new_uid.c: Likewise.

15 years ago * libmisc/yesno.c: Ignore the return value of puts.
nekral-guest [Thu, 23 Apr 2009 11:14:56 +0000 (11:14 +0000)]
* libmisc/yesno.c: Ignore the return value of puts.

15 years ago * libmisc/age.c: Use exit(EXIT_FAILURE) instead of exit(1).
nekral-guest [Thu, 23 Apr 2009 11:14:18 +0000 (11:14 +0000)]
* libmisc/age.c: Use exit(EXIT_FAILURE) instead of exit(1).
* libmisc/age.c: The return value of execl() is not used.

15 years ago * libmisc/xgetXXbyYY.c, libmisc/myname.c, libmisc/getgr_nam_gid.c,
nekral-guest [Thu, 23 Apr 2009 09:57:03 +0000 (09:57 +0000)]
* libmisc/xgetXXbyYY.c, libmisc/myname.c, libmisc/getgr_nam_gid.c,
libmisc/salt.c, libmisc/list.c, libmisc/cleanup.c, src/login.c,
lib/getdef.h, lib/groupio.c, lib/getlong.c, lib/gshadow_.h,
lib/sgroupio.c, lib/shadowio.c, lib/pwio.c, lib/commonio.h,
lib/fputsx.c, lib/prototypes.h: Added splint annotations.
* lib/groupio.c: Avoid implicit conversion of pointers to
booleans.
* lib/groupio.c: Free allocated buffers in case of failure.

15 years agoFix typo.
nekral-guest [Wed, 22 Apr 2009 21:33:09 +0000 (21:33 +0000)]
Fix typo.

15 years ago * lib/defines.h: Added splint definitions to replace <locale.h>
nekral-guest [Wed, 22 Apr 2009 21:22:32 +0000 (21:22 +0000)]
* lib/defines.h: Added splint definitions to replace <locale.h>

15 years ago * libmisc/utmp.c, libmisc/age.c, libmisc/shell.c, lib/groupio.c,
nekral-guest [Wed, 22 Apr 2009 21:21:14 +0000 (21:21 +0000)]
* libmisc/utmp.c, libmisc/age.c, libmisc/shell.c, lib/groupio.c,
lib/groupio.h, lib/sgroupio.c, lib/sgroupio.h, lib/shadowio.c,
lib/pwio.c, lib/commonio.c, lib/shadowio.h, lib/pwio.h,
lib/commonio.h, lib/prototypes.h: Added splint annotations.

15 years ago * libmisc/utmp.c: Added splint annotations.
nekral-guest [Wed, 22 Apr 2009 21:07:33 +0000 (21:07 +0000)]
* libmisc/utmp.c: Added splint annotations.

15 years ago * libmisc/utmp.c: Only set ut_time and ut_tv if gettimeofday()
nekral-guest [Wed, 22 Apr 2009 21:06:13 +0000 (21:06 +0000)]
* libmisc/utmp.c: Only set ut_time and ut_tv if gettimeofday()
succeeds.

15 years ago * libmisc/utmp.c: Fix the check for empty host in prepare_utmp()
nekral-guest [Wed, 22 Apr 2009 21:04:16 +0000 (21:04 +0000)]
* libmisc/utmp.c: Fix the check for empty host in prepare_utmp()
and prepare_utmpx().

15 years ago * libmisc/utmp.c: The ut argument of prepare_utmp() might be NULL.
nekral-guest [Wed, 22 Apr 2009 21:02:46 +0000 (21:02 +0000)]
* libmisc/utmp.c: The ut argument of prepare_utmp() might be NULL.
ut_id needs to be forged in that case.

15 years ago * libmisc/utmp.c: Removed old documentation of setutmp().
nekral-guest [Wed, 22 Apr 2009 21:00:18 +0000 (21:00 +0000)]
* libmisc/utmp.c: Removed old documentation of setutmp().

15 years ago * libmisc/utmp.c: Use xmalloc() rather than malloc().
nekral-guest [Wed, 22 Apr 2009 20:59:23 +0000 (20:59 +0000)]
* libmisc/utmp.c: Use xmalloc() rather than malloc().

15 years ago * libmisc/utmp.c: The name returned by ttyame() needs to be copied
nekral-guest [Wed, 22 Apr 2009 20:57:29 +0000 (20:57 +0000)]
* libmisc/utmp.c: The name returned by ttyame() needs to be copied
locally.

15 years ago * src/login.c: Added splint annotations.
nekral-guest [Wed, 22 Apr 2009 20:53:15 +0000 (20:53 +0000)]
* src/login.c: Added splint annotations.

15 years ago * src/login.c: Added assert()s for NULL (or ! NULL) username, and
nekral-guest [Wed, 22 Apr 2009 20:51:13 +0000 (20:51 +0000)]
* src/login.c: Added assert()s for NULL (or ! NULL) username, and
pwd. This helps splint.

15 years agoRe-indent.
nekral-guest [Wed, 22 Apr 2009 20:48:42 +0000 (20:48 +0000)]
Re-indent.

15 years ago * src/login.c: After login_prompt(), do not check for unset
nekral-guest [Wed, 22 Apr 2009 20:46:49 +0000 (20:46 +0000)]
* src/login.c: After login_prompt(), do not check for unset
username, but for empty username.

15 years ago * lib/defines.h: Define USER_NAME_MAX_LENGTH, based on utmp and
nekral-guest [Wed, 22 Apr 2009 20:42:48 +0000 (20:42 +0000)]
* lib/defines.h: Define USER_NAME_MAX_LENGTH, based on utmp and
default to 32.
* libmisc/chkname.c: Use USER_NAME_MAX_LENGTH.
* src/login.c: Use USER_NAME_MAX_LENGTH instead of the default 32.
username also needs to be bigger than USER_NAME_MAX_LENGTH because
it has to be nul-terminated.

15 years ago * src/login.c: Use xmalloc() instead of malloc().
nekral-guest [Wed, 22 Apr 2009 20:21:17 +0000 (20:21 +0000)]
* src/login.c: Use xmalloc() instead of malloc().

15 years ago * src/login.c: Ignore the return value of puts(), fputs(),
nekral-guest [Wed, 22 Apr 2009 20:17:11 +0000 (20:17 +0000)]
* src/login.c: Ignore the return value of puts(), fputs(),
strftime().

15 years ago * src/login.c: timeout, delay, and retries should be unsigned.
nekral-guest [Wed, 22 Apr 2009 20:15:21 +0000 (20:15 +0000)]
* src/login.c: timeout, delay, and retries should be unsigned.
* src/login.c: Ignore the return value of alarm() and sleep().

15 years ago * src/login.c: If we cannot get the terminal configuration, do not
nekral-guest [Wed, 22 Apr 2009 20:12:06 +0000 (20:12 +0000)]
* src/login.c: If we cannot get the terminal configuration, do not
change the terminal configuration. setup_tty() is just a best
effort configuration of the terminal.
* src/login.c: Ignore failures when setting the terminal
configuration.
* src/login.c: Fail if the ERASECHAR or KILLCHAR configurations
are not compatible with a cc_t type.

15 years ago * src/login.c: utent might be NULL after get_current_utmp().
nekral-guest [Wed, 22 Apr 2009 20:07:34 +0000 (20:07 +0000)]
* src/login.c: utent might be NULL after get_current_utmp().

15 years ago * src/login.c: Removed temp_shell. No more used.
nekral-guest [Wed, 22 Apr 2009 20:03:26 +0000 (20:03 +0000)]
* src/login.c: Removed temp_shell. No more used.
* src/login.c: lastlog is only used #ifndef USE_PAM
* src/login.c: Rename lastlog to ll to avoid name clash with the
lastlog type.

15 years ago * src/login.c: Added update_utmp() to group the prepare_utmp and
nekral-guest [Wed, 22 Apr 2009 19:58:39 +0000 (19:58 +0000)]
* src/login.c: Added update_utmp() to group the prepare_utmp and
setutmp (and the utmpx versions).

15 years ago * src/login.c: Do not include netdb.h. gethostbyname() is no more
nekral-guest [Wed, 22 Apr 2009 19:54:28 +0000 (19:54 +0000)]
* src/login.c: Do not include netdb.h. gethostbyname() is no more
called from within login.c. Also UT_ADDR does not exist anymore.

15 years ago * src/login.c: Check if login is run with effective root
nekral-guest [Tue, 21 Apr 2009 22:46:01 +0000 (22:46 +0000)]
* src/login.c: Check if login is run with effective root
privileges. This should be more helpful to users than a failure to
find an utmp entry or failure to access a file.

15 years agoAdded previous commit changelog.
nekral-guest [Tue, 21 Apr 2009 22:39:52 +0000 (22:39 +0000)]
Added previous commit changelog.

15 years ago * libmisc/utmp.c: Reworked. Get rid of Linux specific stuff. Get rid
nekral-guest [Tue, 21 Apr 2009 22:39:14 +0000 (22:39 +0000)]
* libmisc/utmp.c: Reworked. Get rid of Linux specific stuff. Get rid
of global utent/utxent variables. Only reuse the ut_id and maybe
the ut_host fields from utmp.
* lib/prototypes.h, libmisc/utmp.c: Removed checkutmp(),
setutmp(), setutmpx().
* lib/prototypes.h, libmisc/utmp.c: Added get_current_utmp(),
prepare_utmp(), prepare_utmpx(), setutmp(), setutmpx().
* libmisc/utmp.c (is_my_tty): Only compare the name of the utmp
line with ttyname(). (No stat of the two terminals to compare the
devices).
* libmisc/utmp.c: Use getaddrinfo() to get the address of the
host.
* configure.in: Check for getaddrinfo().
* configure.in: Use AC_CHECK_MEMBERS to check for the existence of
fields in the utmp/utmpx structures.
* configure.in: Reject systems with utmpx support but no ut_id
field in utmp. This could be fixed later if needed.
* src/login.c: Use the new utmp functions. This also simplifies
the failtmp() handling.
* src/login.c: passwd_free() renamed to pw_free() and
shadow_free() renamed to spw_free()

15 years ago * NEWS, configure.in: Enable --enable-account-tools-setuid by
nekral-guest [Tue, 21 Apr 2009 22:22:08 +0000 (22:22 +0000)]
* NEWS, configure.in: Enable --enable-account-tools-setuid by
default for PAM builds, as it used to be before the introduction
of this option.

15 years ago * etc/pam.d/Makefile.am: Distribute all pam.d files, even if
nekral-guest [Tue, 21 Apr 2009 22:16:17 +0000 (22:16 +0000)]
* etc/pam.d/Makefile.am: Distribute all pam.d files, even if
ACCT_TOOLS_SETUID is not enabled.

15 years ago * lib/shadowmem.c: Added spw_free().
nekral-guest [Tue, 21 Apr 2009 22:14:10 +0000 (22:14 +0000)]
* lib/shadowmem.c: Added spw_free().
* lib/shadowio.c: Use spw_free() for shadow_free().
* lib/groupmem.c: Added gr_free().
* lib/groupio.c: Use gr_free() for group_free().
* lib/pwmem.c: Include define.h before prototypes.h
* lib/pwmem.c: Added pw_free().
* lib/pwio.c: Use pw_free() for passwd_free().
* lib/sgroupio.c: Added sgr_free().
* lib/sgroupio.c: Use sgr_free() for gshadow_free().
* lib/prototypes.h: Added gr_free(), pw_free(), sgr_free(),
spw_free().

15 years ago * libmisc/shell.c: Add brackets and parenthesis.
nekral-guest [Tue, 21 Apr 2009 22:07:35 +0000 (22:07 +0000)]
* libmisc/shell.c: Add brackets and parenthesis.
* libmisc/shell.c: Avoid assignments in comparisons.
* libmisc/shell.c: Re-indent.

15 years ago * lib/defines.h: Added MIN and MAX macros.
nekral-guest [Tue, 21 Apr 2009 22:06:09 +0000 (22:06 +0000)]
* lib/defines.h: Added MIN and MAX macros.
* libmisc/salt.c: Removed MIN and MAX macros.

15 years agoFix typo (&nbsp;) and fix a compilation warning (wrong const).
nekral-guest [Tue, 21 Apr 2009 22:03:33 +0000 (22:03 +0000)]
Fix typo (&nbsp;) and fix a compilation warning (wrong const).

15 years agoFix typo.
nekral-guest [Tue, 21 Apr 2009 22:02:37 +0000 (22:02 +0000)]
Fix typo.

15 years agoAdded more comments to the changelog entry.
nekral-guest [Mon, 20 Apr 2009 14:06:06 +0000 (14:06 +0000)]
Added more comments to the changelog entry.

15 years ago * NEWS, src/lastlog.c: Fix regression causing empty reports.
nekral-guest [Mon, 20 Apr 2009 14:04:48 +0000 (14:04 +0000)]
* NEWS, src/lastlog.c: Fix regression causing empty reports.

15 years ago * src/login.c: Get rid of pwent. pwd is sufficient as long as it
nekral-guest [Mon, 20 Apr 2009 13:29:15 +0000 (13:29 +0000)]
* src/login.c: Get rid of pwent. pwd is sufficient as long as it
is always coming from xgetpwnam. There is no need to copy pwd to
pwent, this was not a good idea anyway as the strings from pwd
were not duplicated.
* src/login.c: Always free the pwd and spwd structure when we
retrieve a new one. This will clear the password of the previous
user from the memory.
* src/login.c: user_passwd is used to keep point to the password
of the user being authenticated.
* src/login.c: (non PAM) Fail if the user's entry cannot be found
after the user updated her password (if expire() requested an
update).
* src/login.c: If the user does not exist on the system, there is
no need to build a pwd structure (with shell).

15 years ago * src/login.c: ttytype already checks for TTYTYPE_FILE and TERM.
nekral-guest [Mon, 20 Apr 2009 13:12:09 +0000 (13:12 +0000)]
* src/login.c: ttytype already checks for TTYTYPE_FILE and TERM.
Just call ttytype.

15 years agoRe-indent.
nekral-guest [Mon, 20 Apr 2009 13:10:20 +0000 (13:10 +0000)]
Re-indent.

15 years ago * src/login.c: Open the PAM session before pam_setcred and before
nekral-guest [Mon, 20 Apr 2009 12:54:17 +0000 (12:54 +0000)]
* src/login.c: Open the PAM session before pam_setcred and before
initgroups. This is more consistent with rfc86.0.

15 years ago * src/login.c: Added helper functions get_pam_user() and
nekral-guest [Mon, 20 Apr 2009 12:47:04 +0000 (12:47 +0000)]
* src/login.c: Added helper functions get_pam_user() and
get_failent_user().

15 years ago * src/login.c: Added parameter to check_nologin. This will help
nekral-guest [Mon, 20 Apr 2009 12:33:01 +0000 (12:33 +0000)]
* src/login.c: Added parameter to check_nologin. This will help
getting rid of the global pwent variable.

15 years ago * src/login.c: Added comments.
nekral-guest [Mon, 20 Apr 2009 12:27:27 +0000 (12:27 +0000)]
* src/login.c: Added comments.
* src/login.c: Close the user and group files before dropping root
privileges.

15 years ago * src/login.c: We do not need to keep the old umask. Discard the
nekral-guest [Mon, 20 Apr 2009 12:17:38 +0000 (12:17 +0000)]
* src/login.c: We do not need to keep the old umask. Discard the
umask() return value.

15 years ago * src/login.c: We do not need to keep the old umask. Discard the
nekral-guest [Mon, 20 Apr 2009 12:16:07 +0000 (12:16 +0000)]
* src/login.c: We do not need to keep the old umask. Discard the
umask() return value.

15 years ago * libmisc/hushed.c, lib/prototypes.h, src/login.c: Change the
nekral-guest [Mon, 20 Apr 2009 11:48:59 +0000 (11:48 +0000)]
* libmisc/hushed.c, lib/prototypes.h, src/login.c: Change the
hushed() prototype to take a username instead of a passwd
structure in argument. The passwd entry is retrieved withing
hushed().

15 years ago * libmisc/setugid.c: Updated comments.
nekral-guest [Mon, 20 Apr 2009 11:43:36 +0000 (11:43 +0000)]
* libmisc/setugid.c: Updated comments.

15 years ago * libmisc/failure.h, libmisc/failure.c, src/login.c: Added
nekral-guest [Mon, 20 Apr 2009 11:39:16 +0000 (11:39 +0000)]
* libmisc/failure.h, libmisc/failure.c, src/login.c: Added
username as first parameter of failtmp to avoid issues with
non-null terminated ut_user, unavailability of ut_user, incomplete
username (that should not happen currently).

15 years ago * libmisc/failure.h, libmisc/failure.c, src/login.c: Added
nekral-guest [Mon, 20 Apr 2009 11:37:41 +0000 (11:37 +0000)]
* libmisc/failure.h, libmisc/failure.c, src/login.c: Added
username as first parameter of failtmp to avoid issues with
non-null terminated ut_user, unavailability of ut_user, incomplete
username (that should not happen currently).

15 years ago * libmisc/ttytype.c: Add brackets and parenthesis.
nekral-guest [Mon, 20 Apr 2009 11:31:05 +0000 (11:31 +0000)]
* libmisc/ttytype.c: Add brackets and parenthesis.
* libmisc/ttytype.c: Avoid assignments in comparisons.

15 years ago * lib/pwio.c, lib/shadowio.c, lib/groupio.c, lib/sgroupio.c: Fill
nekral-guest [Mon, 20 Apr 2009 11:29:17 +0000 (11:29 +0000)]
* lib/pwio.c, lib/shadowio.c, lib/groupio.c, lib/sgroupio.c: Fill
the password fields with zeros before they are freed.