File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17080,7 +17080,13 @@ run_renego() {
1708017080 pr_svrty_medium "VULNERABLE (NOT ok)"; outln ", potential DoS threat"
1708117081 fileout "$jsonID" "MEDIUM" "VULNERABLE, potential DoS threat" "$cve" "$cwe" "$hint"
1708217082 else
17083- (for ((i=0; i < ssl_reneg_attempts; i++ )); do echo R; sleep $ssl_reneg_wait; done) | \
17083+ # Clear the log to not get the content of previous run before the execution of the new one.
17084+ echo -n > $TMPFILE
17085+ # If we dont wait for the session to be established on slow server, we will try to re-negotiate
17086+ # too early losing all the attempts before the session establishment as OpenSSL will not buffer them
17087+ # (only the first will be till the establishement of the session).
17088+ (while [[ $(grep -ac '^SSL-Session:' $TMPFILE) -ne 1 ]]; do sleep 1; done; \
17089+ for ((i=0; i < ssl_reneg_attempts; i++ )); do echo R; sleep $ssl_reneg_wait; done) | \
1708417090 $OPENSSL s_client $(s_client_options "$proto $legacycmd $STARTTLS $BUGS -connect $NODEIP:$PORT $PROXY $SNI") >$TMPFILE 2>>$ERRFILE &
1708517091 pid=$!
1708617092 ( sleep $(($ssl_reneg_attempts*3)) && pkill -HUP -P $pid && wait $pid && touch $TEMPDIR/was_killed ) >&2 2>/dev/null &
You can’t perform that action at this time.
0 commit comments