diff options
author | Thomas Orgis | 2007-01-22 12:58:33 +0100 |
---|---|---|
committer | Jaka Kranjc | 2007-01-23 12:05:50 +0100 |
commit | c01ca957777a2ea4dfdd26214debc6560f19bb92 (patch) | |
tree | 418f5bcafb565c57fabb375bbe9642adfd6fc055 | |
parent | 381907a61eb92c15eca9782fbb6c0ed0f69d462d (diff) |
shadow: fixing bug 8834 for good, hopefully
-rwxr-xr-x | security/shadow/CONFIGURE | 18 | ||||
-rwxr-xr-x | security/shadow/FINAL | 9 | ||||
-rw-r--r-- | security/shadow/HISTORY | 4 |
3 files changed, 28 insertions, 3 deletions
diff --git a/security/shadow/CONFIGURE b/security/shadow/CONFIGURE new file mode 100755 index 0000000000..d796932297 --- /dev/null +++ b/security/shadow/CONFIGURE @@ -0,0 +1,18 @@ +config_query SHADOW_CONV "Attempt to convert/fix accounts (with installed shadow utils)" y && +if [[ "$SHADOW_CONV" == y ]]; then + message "OK, checking your user and group accounts" && + grpck -r "$INSTALL_ROOT/etc/group" "$INSTALL_ROOT/etc/gshadow" || + { + message "there are problems with group... runinng grpck +interactively" && + grpck "$INSTALL_ROOT/etc/group" "$INSTALL_ROOT/etc/gshadow" + } + pwck -q -r "$INSTALL_ROOT/etc/passwd" "$INSTALL_ROOT/etc/shadow" || + { + message "there are problems with passwd... runinng grpck +interactively" && + grpck "$INSTALL_ROOT/etc/passwd" "$INSTALL_ROOT/etc/shadow" + } +fi +# the tools give negative return even after successfully fixing stuff +true diff --git a/security/shadow/FINAL b/security/shadow/FINAL index 0ab04306e6..eca5bd2d18 100755 --- a/security/shadow/FINAL +++ b/security/shadow/FINAL @@ -1,3 +1,6 @@ -#Create or update necessary files for shadow -${INSTALL_ROOT}/usr/sbin/pwconv && -${INSTALL_ROOT}/usr/sbin/grpconv +if [ "$SHADOW_CONV" == y ]; then + #Create or update necessary files for shadow + message "running pwconv and grpconv" && + ${INSTALL_ROOT}/usr/sbin/pwconv && + ${INSTALL_ROOT}/usr/sbin/grpconv +fi diff --git a/security/shadow/HISTORY b/security/shadow/HISTORY index bd4348bec8..b129ae4cc5 100644 --- a/security/shadow/HISTORY +++ b/security/shadow/HISTORY @@ -1,3 +1,7 @@ +2007-01-22 Thomas Orgis <sobukus@sourcemage.org> + * CONFIGURE,FINAL: optionally check/correct the account files + that's final (hopefully) for bug 8834 + 2007-01-20 Thomas Orgis <sobukus@sourcemage.org> * pam.d/su: move that to coreutils as the su binary comes from there now |