diff options
author | William Harrington <kb0iic@berzerkula.org> | 2021-12-11 00:52:08 -0600 |
---|---|---|
committer | William Harrington <kb0iic@berzerkula.org> | 2021-12-11 00:52:08 -0600 |
commit | 2c8204d6325a1a6607392d5905227b9043da17cc (patch) | |
tree | 5a2d9047d0a3fb5664c17284b92c6e572507d062 /chapter8/shadow.sh | |
parent | f699702e72de8200632cfb95350ad51bb68c4b6f (diff) |
Major updates.
Diffstat (limited to 'chapter8/shadow.sh')
-rw-r--r-- | chapter8/shadow.sh | 58 |
1 files changed, 29 insertions, 29 deletions
diff --git a/chapter8/shadow.sh b/chapter8/shadow.sh index 075caad..de902bc 100644 --- a/chapter8/shadow.sh +++ b/chapter8/shadow.sh @@ -1,29 +1,29 @@ -#!/bin/bash -set -e - -# shellcheck disable=SC2016 -ROOTPW='$1$5RPAAd$oejpw8ErihLIB7vmGE4SV1' - -# shellcheck disable=SC2016 -sed -i 's/groups$(EXEEXT) //' src/Makefile.in && -find man -name Makefile.in -exec sed -i 's/groups\.1 / /' {} \; && -find man -name Makefile.in -exec sed -i 's/getspnam\.3 / /' {} \; && -find man -name Makefile.in -exec sed -i 's/passwd\.5 / /' {} \; && - -sed -e 's:#ENCRYPT_METHOD DES:ENCRYPT_METHOD SHA512:' \ - -e 's:/var/spool/mail:/var/mail:' \ - -i etc/login.defs && - -sed -i 's/1000/999/' etc/useradd && - -touch /usr/bin/passwd && -./configure --sysconfdir=/etc \ - --with-group-name-max-length=32 && - -make && -make -j1 install && - -pwconv && -grpconv && - -usermod -p "${ROOTPW}" root +#!/bin/bash
+set -e
+
+# shellcheck disable=SC2016
+ROOTPW='$1$5RPAAd$oejpw8ErihLIB7vmGE4SV1'
+
+# shellcheck disable=SC2016
+sed -i 's/groups$(EXEEXT) //' src/Makefile.in &&
+find man -name Makefile.in -exec sed -i 's/groups\.1 / /' {} \; &&
+find man -name Makefile.in -exec sed -i 's/getspnam\.3 / /' {} \; &&
+find man -name Makefile.in -exec sed -i 's/passwd\.5 / /' {} \; &&
+
+sed -e 's:#ENCRYPT_METHOD DES:ENCRYPT_METHOD SHA512:' \
+ -e 's:/var/spool/mail:/var/mail:' \
+ -i etc/login.defs &&
+
+sed -i 's/1000/999/' etc/useradd &&
+
+touch /usr/bin/passwd &&
+./configure --sysconfdir=/etc \
+ --with-group-name-max-length=32 &&
+
+make &&
+make -j1 install &&
+
+pwconv &&
+grpconv &&
+
+usermod -p "${ROOTPW}" root
|