Commit Graph
4 Commits
Author SHA1 Message Date
Eric Gu 2940c9503e Fix broken OpenSSL version check for IPv6 proxy in check_proxy() (#3095)
check_proxy() gated IPv6 proxy support on a home-grown version check
${OSSL_VER_MAJOR$}${OSSL_VER_MINOR} -ge 11 at two places, which had a
stray "$" causing a "bad substitution" error. On non-LibreSSL builds
this aborted the rest of check_proxy() for any IPv6 proxy (literal
[addr]:port, or a hostname resolving only to AAAA), so PROXY was never
rebuilt into a valid "-proxy ..." argument and downstream openssl calls
failed with an error mentioning neither IPv6 nor the proxy.

Beyond the typo, the concatenation approach was itself unsound:
OSSL_VER_MINOR carries the patch component (e.g. "1.1" for OpenSSL
1.1.1), so ${OSSL_VER_MAJOR}${OSSL_VER_MINOR} yields "11.1" and
[[ 11.1 -ge 11 ]] is an arithmetic error. Replace both checks with the
dotted-glob idiom used everywhere else in the file for OpenSSL >= 1.1
gates (e.g. testssl.sh:21441, :8216), which is robust and greppable.
2026-07-12 17:10:45 -04:00
Eric Gu aad4894f77 Fix stored XSS in HTML report via unescaped Location: header (#3090)
pr_url() and pr_boldurl() interpolated their argument directly into
<a href="$1">$1</a> without HTML escaping. The most notable caller
passes the raw HTTP Location: header from the scanned server, so a
malicious HTTPS target could inject arbitrary HTML/JS into an
operator's --htmlfile report. Route both the href attribute and the
link text through the existing html_reserved() escaper, matching the
pattern already used by every other pr_* HTML-output function.
2026-07-11 22:53:36 -04:00
Eric Gu (@ericguuu)andGitHub 5a69b1c344 bugfix: aesgcm_used --> enc_aesgcm_used 2026-07-09 08:45:38 -04:00
Eric Gu (@ericguuu)andGitHub 09a17c0cc1 fix: nverted return check in sym-encrypt() at testssl.sh:14741 makes the function return error 7 on every success.
[BUG / possible BUG] Inverted return check in sym-encrypt() at testssl.sh:14741 makes the function return error 7 on every success. The tm_out line at testssl.sh:14743 is unreachable.
 #3079
2026-07-08 08:28:33 -04:00