mirror of
https://github.com/stefanocasazza/ULib.git
synced 2025-09-28 19:05:55 +08:00
18 lines
354 B
Bash
Executable File
18 lines
354 B
Bash
Executable File
#/bin/bash
|
|
|
|
# check_passwd.sh
|
|
|
|
# egrep "[ABCDEFGHIJKLMNOPQRSTUVXYZ]" | \
|
|
b=`echo $1 | egrep "^.{8,255}" | \
|
|
egrep "[abcdefghijklmnopqrstuvxyz"] | \
|
|
egrep "[0-9]"`
|
|
|
|
#if the result string is empty, one of the conditions has failed
|
|
|
|
if [ -z $b ]
|
|
then
|
|
echo "Conditions do not match"
|
|
else
|
|
echo "Conditions match"
|
|
fi
|