https://github.com/drwetter/testssl.sh
Revision 91367caa71fc961cd6d1ab4be16f239980aecc90 authored by Emmanuel Fusté on 06 March 2024, 12:57:21 UTC, committed by Emmanuel Fusté on 06 March 2024, 12:57:21 UTC
There is a race condition if openssl exit during a renego but after
the RENEGOTIATING printing.
In this case we could issue a R before the process exit and be blocked
in the waiting loop.
With the safety guards in place (loop count + timeout) this is harmless
but not optimal.
Fix this by:
- reordering the sleep vs echo to let the process exit and catch the
  pipe error more frequently.
- exit the while loop if RENEGOTIATING is not the last log line. We
  will catch the pipe error on the next for loop echo.
- correct the k variable initialisation
- correct the for (( ; ; )) variable $ convention usage
- reduce the while loop count limit to 120 to align with the global
  timeout
1 parent 35496e5
History
Tip revision: 91367caa71fc961cd6d1ab4be16f239980aecc90 authored by Emmanuel Fusté on 06 March 2024, 12:57:21 UTC
Fix and optimisation
Tip revision: 91367ca
File Mode Size
.github
bin
doc
etc
t
utils
.dockerignore -rw-r--r-- 198 bytes
.editorconfig -rw-r--r-- 98 bytes
.gitattributes -rw-r--r-- 175 bytes
.gitignore -rw-r--r-- 246 bytes
CHANGELOG.md -rw-r--r-- 19.6 KB
CONTRIBUTING.md -rw-r--r-- 1.3 KB
CREDITS.md -rw-r--r-- 4.9 KB
Coding_Convention.md -rw-r--r-- 5.7 KB
Dockerfile -rw-r--r-- 2.1 KB
Dockerfile.git -rw-r--r-- 684 bytes
Dockerfile.md -rw-r--r-- 1.4 KB
LICENSE -rw-r--r-- 17.7 KB
Readme.md -rw-r--r-- 7.2 KB
openssl-iana.mapping.html -rw-r--r-- 60.8 KB
testssl.sh -rwxr-xr-x 1.2 MB

Readme.md

back to top