From dcc27afc0665dedb183d0d9990e2d1bc5da649ea Mon Sep 17 00:00:00 2001 From: "Gerd v. Egidy" Date: Thu, 15 Sep 2022 20:58:33 +0200 Subject: [PATCH] add mkpasswd: hash a password for use in /etc/shadow or htpasswd mkpasswd is finally available packaged on Arch, so add it to allow manually replacing a password in /etc/shadow, for when chroots or pam don't work as wanted. Also supports advanced hash algos like yescrypt that can't be set via the pam stack yet. Because the source for mkpasswd is part of the whois package, it is currently packaged as part of whois. But it might get it's own package in the future, so add a check for /usr/bin/mkpasswd during build time. --- ChangeLog | 1 + airootfs/usr/bin/check-binaries.sh | 12 +++++++++++- packages | 1 + 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index c7ad4f5..c73d56c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -12,6 +12,7 @@ https://gitlab.com/systemrescue/systemrescue-sources/-/issues/278 * Don't waste ram when using the archiso_http_srv option (#56) * mountall: run udevadm settle to mount newly opened cryptodisks, improve messages * Add rclone option to the "sysconfig" scope of YAML config file, it writes a rclone.conf file +* Added packages: whois (mkpasswd) ------------------------------------------------------------------------------ 9.04 (2022-08-07): diff --git a/airootfs/usr/bin/check-binaries.sh b/airootfs/usr/bin/check-binaries.sh index 6a32693..2b5ee47 100755 --- a/airootfs/usr/bin/check-binaries.sh +++ b/airootfs/usr/bin/check-binaries.sh @@ -21,9 +21,19 @@ do done +# check for missing programs +# mkpasswd might be packaged separately from whois in the future +for curfile in /usr/bin/mkpasswd ; \ +do + if ! [[ -x "${curfile}" ]]; then + echo "ERROR: Program ${curfile} is missing" + errcnt=$((errcnt + 1)) + fi +done + if [ ${errcnt} -eq 0 ] then - echo "SUCCESS: Have not found any missing library" + echo "SUCCESS: Have not found any missing library or program" exit 0 else echo "FAILURE: Have found ${errcnt} issues" diff --git a/packages b/packages index 0e19353..583eabc 100644 --- a/packages +++ b/packages @@ -246,6 +246,7 @@ vpnc wget whdd which +whois wimlib wipe wireguard-tools