mirror of
https://github.com/mozilla/cipherscan.git
synced 2024-11-22 14:23:41 +01:00
Fix test of all ciphers individually
This commit is contained in:
parent
d6556f5620
commit
7c55288a7e
@ -170,17 +170,16 @@ for result in "${results[@]}"; do
|
|||||||
echo $result|grep -v '(NONE)'
|
echo $result|grep -v '(NONE)'
|
||||||
done|column -t
|
done|column -t
|
||||||
|
|
||||||
|
# If asked, test every single cipher individually
|
||||||
if [ $ALLCIPHERS -gt 0 ]; then
|
if [ $ALLCIPHERS -gt 0 ]; then
|
||||||
echo; echo "All accepted ciphersuites"
|
echo; echo "All accepted ciphersuites"
|
||||||
for cipher in $($OPENSSLBIN ciphers -v ALL:COMPLEMENTOFALL 2>/dev/null |awk '{print $1}'|sort|uniq); do
|
for c in $($OPENSSLBIN ciphers -v ALL:COMPLEMENTOFALL 2>/dev/null |awk '{print $1}'|sort|uniq); do
|
||||||
osslcommand="timeout $TIMEOUT $OPENSSLBIN s_client -connect $TARGET -cipher $cipher"
|
r="fail"
|
||||||
|
osslcommand="timeout $TIMEOUT $OPENSSLBIN s_client -connect $TARGET -cipher $c"
|
||||||
test_cipher_on_target "$osslcommand"
|
test_cipher_on_target "$osslcommand"
|
||||||
r=$?
|
if [ $? -eq 0 ]; then
|
||||||
if [ $r -eq 0 ]; then
|
r="pass"
|
||||||
echo -en '\E[40;32m'"OK"; tput sgr0
|
|
||||||
else
|
|
||||||
echo -en '\E[40;31m'"KO"; tput sgr0
|
|
||||||
fi
|
fi
|
||||||
echo " $cipher"
|
echo "$c $r"|awk '{printf "%-35s %s\n",$1,$2}'
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user