diff --git a/front_pwquality.sh b/front_pwquality.sh index 7beaaac..3a1a1a4 100644 --- a/front_pwquality.sh +++ b/front_pwquality.sh @@ -32,8 +32,8 @@ var="$(yad --title=$"linux-infosec-setupper" --form \ --width=800 \ --height=800 \ --button=$"Load defaults!view-refresh:3" --button=$"yad-save:0" --button=$"yad-close:1" \ - --field=$"Number of characters in the new password that must not be present in the old password::LBL" "!" \ - --field=$"Value (difok)::NUM" "$difok!1..9999!1" \ + --field=$"Number of characters in the new password that must not be present in the old password::LBL" "!" \ + --field=$"Value (difok):NUM" "$difok!1..9999!1" \ --field=$"Minimum acceptable size for the new password:LBL" "!" \ --field=$"Value (minlen):NUM" "$minlen!6..9999!1" \ --field=$"The maximum credit for having digits in the new password::LBL" "!" \ diff --git a/parse_pwquality.sh b/parse_pwquality.sh new file mode 100755 index 0000000..d03a3f6 --- /dev/null +++ b/parse_pwquality.sh @@ -0,0 +1,8 @@ +_pw_parse_conf() { +while read -r line; do + case "$line" in + *=*) echo "${line// /}" ;; + *) echo "${line}=1" ;; + esac +done < "${DESTDIR}/etc/security/pwquality.conf" +}