34 lines
1.1 KiB
Bash
Executable File
34 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
|
|
# check if webmail.stage-ge.org is up
|
|
|
|
if nc -z -w 2 webmail.stage-ge.org 80 2>/dev/null; then
|
|
echo "[SUCCESS] - webmail.stage-ge.org is started "
|
|
else
|
|
echo "[ERROR] - webmail.stage-ge.org is not started (verify resolv.conf and service)"
|
|
exit
|
|
fi
|
|
|
|
declare -A stage_user=(["stagiaire1"]="MamanL3sP3t!tBato" \
|
|
["stagiaire2"]="LeB0nRo!D@g0bert" \
|
|
["stagiaire3"]="M0nMotD3P@sseSecret" \
|
|
["stagiaire4"]="LesR0IduM0nd3" \
|
|
["stagiaire5"]="AChangerASAP" \
|
|
["stagiaire6"]="Mon5uperP@55w0rd" \
|
|
["stagiaire7"]="0rdreAlphaBetixs!" \
|
|
["stagiaire8"]="TheP@55wOrd!" \
|
|
["stagiaire9"]="TiTiEtGr0sMinet_" \
|
|
#["stagiaire10"]="Ret0urVer5LeFu7ur" \
|
|
)
|
|
|
|
# Tri du tableau
|
|
KEYS=`echo ${!stage_user[@]} | tr ' ' '\012' | sort | tr '\012' ' '`
|
|
|
|
for user in $KEYS; do
|
|
echo "$user - ${stage_user[$user]}"
|
|
curl -s --interface 127.0.0.1 "http:/webmail.stage-ge.org?task=login?&_user=$user&_pass=${stage_user[$user]}" > /dev/null
|
|
curl -s --interface 127.0.0.1 "https://webmail.stage-ge.org?task=login?&_user=$user&_pass=${stage_user[$user]}" > /dev/null
|
|
done
|
|
|