File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -17707,16 +17707,22 @@ run_opossum() {
17707
17707
uri=${URI/https:\/\//}
17708
17708
response=$(http_head_printf http://${uri} 'Upgrade: TLS/1.0\r\n\r\nClose\r\n')
17709
17709
# In any case we use $response but we handle the return codes
17710
- case $? in
17711
- 0) ret=0 ;;
17712
- 1|3) ret=7 ;; # got stuck
17713
- esac
17710
+ # 0: connection was fine, 1 or 3: no http connection
17711
+ ret=$?
17714
17712
if [[ $response =~ Upgrade:\ TLS ]]; then
17715
17713
prln_svrty_high "VULNERABLE (NOT ok)"
17716
17714
fileout "$jsonID" "CRITICAL" "VULNERABLE" "$cve" "$cwe" "$hint"
17717
- else
17715
+ elif [[ $ret -eq 0 ]]; then
17718
17716
prln_svrty_good "not vulnerable (OK)"
17719
- fileout "$jsonID" "OK" "not vulnerable $append" "$cve" "$cwe"
17717
+ fileout "$jsonID" "OK" "not vulnerable" "$cve" "$cwe"
17718
+ else
17719
+ if [[ $ret -eq 3 ]]; then
17720
+ prln_local_problem "direct connection to port 80 failed, better try without proxy"
17721
+ fileout "$jsonID" "WARN" "direct connection to port 80 failed, try w/o no proxy" "$cve" "$cwe"
17722
+ else
17723
+ outln "connection to port 80 failed"
17724
+ fileout "$jsonID" "INFO" "connection to port 80 failed" "$cve" "$cwe"
17725
+ fi
17720
17726
fi
17721
17727
;;
17722
17728
IMAP|FTP|POP3|SMTP|LMTP|NNTP)
You can’t perform that action at this time.
0 commit comments