Commit Graph
100 Commits
Author SHA1 Message Date
Dirk c5cee3ddb6 Address further potential license restriction
.. see https://github.com/drwetter/testssl.sh/issues/1590#issuecomment-623526604

Added some formatting and verbal improvements in the intruductory comment section.
2020-05-04 20:24:24 +02:00
Dirk WetterandGitHub 85faf9d096 Merge pull request #1606 from drwetter/add_brotli_3.0
Add brotli compression detection for BREACH (backport)
2020-05-04 17:50:32 +02:00
Dirk Wetter 85a529ee00 Add brotli compression detection for BREACH (backport)
As noted in #1605 the brotli compression check was missing. So hosts
which didn't offer gzip deflate or compress but brotli seemed to
be fine but they shoould have been labled as potentially VULNERABLE.

This also fixes a bug: The HTTP header returned was only checking
for case-sensitive "Content-Encoding". RFC 2616 states in 4.2
(Message Headers): "Field names are case-insensitive"
2020-05-04 13:23:05 +02:00
Dirk WetterandGitHub dbff0f9673 Merge pull request #1604 from drwetter/aes_cgm_doc_3.0
Fix typo in docs: Strong grade Ciphers / AEAD
2020-05-02 20:01:27 +02:00
Dirk e3ecd72deb Fix typo in docs: Strong grade Ciphers / AEAD 2020-05-02 19:57:02 +02:00
Dirk WetterandGitHub 5521063620 Merge pull request #1602 from dcooper16/improve_libressl_302_compat_30branch
Improve compatibility with LibreSSL 3.0.2 and earlier
2020-05-01 20:44:16 +02:00
Dirk WetterandGitHub ef535b6282 Merge pull request #1596 from dcooper16/ticketbleed_no_tls1_3_30branch
Ticketbleed and TLS 1.3
2020-04-30 13:52:27 +02:00
Dirk WetterandGitHub 3d6d1ac9d7 Merge pull request #1594 from dcooper16/ossl30_compat_for_30branch
Improve compatibility with OpenSSL 3.0
2020-04-29 16:14:01 +02:00
Dirk WetterandGitHub 09fe651b36 Merge pull request #1592 from drwetter/1590_readme
Relax the possible GPL license contradiction
2020-04-28 10:03:40 +02:00
Dirk 126e501143 Relax the possible GPL license contradiction
... see also #1590
2020-04-28 10:02:03 +02:00
Dirk WetterandGitHub 3c403a2484 Merge pull request #1587 from drwetter/np_fix30
Negotiated protocol showed no warning for TLS 1.1/1.0
2020-04-25 11:13:49 +02:00
Dirk Wetter 5c73a23cfe Negotiated protocol showed no warning for TLS 1.1/1.0
.. whereas the protocol section did that.

This fixes the inconsistency.
2020-04-25 11:06:35 +02:00
Dirk WetterandGitHub ac53ec2531 Merge pull request #1585 from dcooper16/fix_logjam_ssl_native_3.0
Fix run_logjam() in --ssl-native mode (3.0 branch)
2020-04-24 09:42:43 +02:00
Dirk WetterandGitHub 2fcbcbe9d1 Merge pull request #1577 from drwetter/drwetter-patch-1
Update reference to ZIP file
2020-04-21 20:30:50 +02:00
Dirk WetterandGitHub 11123840a7 Merge pull request #1578 from drwetter/1571_30
Fix misleading phrasing in run of standard ciphers
2020-04-21 20:30:38 +02:00
Dirk WetterandGitHub 5fdeb32f94 Update reference to ZIP file
to 3.0.1
2020-04-21 18:58:27 +02:00
Dirk Wetter 4809c763cc Fix misleading phrasing in run of standard ciphers
see #1571. Bit size doesn't matter. It only matters to the
user which ciphers they are.
2020-04-21 18:46:57 +02:00
Dirk Wetter af86cce011 Better version naming
bugfix releases for 3.0 are    3.0.x instead of 3.0-1
2020-04-15 12:35:51 +02:00
Dirk WetterandGitHub 27948d80a8 Merge pull request #1564 from drwetter/release.3.0-1
Preparing bugfix release for 3.0
2020-04-15 09:28:41 +02:00
Dirk Wetter 3f5735a1a0 make the sneaky user agent sneaky again 2020-04-14 14:14:45 +02:00
Dirk 8b1b9f9f27 Preparing bugfix release for 3.0
* Bump version
* Removed ancient CVS tag detection code
* ~ backported code doc changes (http --> https and more) from @multiflexi
  see 7eba0fbb41
2020-04-14 13:18:52 +02:00
Dirk WetterandGitHub e51a90d7e1 Merge pull request #1557 from dcooper16/fix1551_30
Fix #1551 in 3.0
2020-04-01 22:28:47 +02:00
Dirk WetterandGitHub ec6b724433 Merge pull request #1547 from dcooper16/display_ciphernames_bug_3.0
Fix bug in setting DISPLAY_CIPHERNAMES in 3.0
2020-03-25 18:28:30 +01:00
Dirk WetterandGitHub b2252002f4 Merge pull request #1539 from mkauschi/http-basic-auth-backport-patch
backport patch for the http basic auth bug from PR 1538
2020-03-18 14:51:36 +01:00
Dirk WetterandGitHub 4601670bac Merge pull request #1534 from drwetter/breach_output3
Fix output for BEAST when no SSL3 or TLS
2020-03-07 12:15:55 +01:00
Dirk 3f5aa1b7df Fix output for BEAST when no SSL3 or TLS
LF added
2020-03-06 22:09:00 +01:00
Dirk WetterandGitHub 1f6ebae401 Merge pull request #1532 from dcooper16/fix_typo_emphasize_stuff_in_headers_3.0
Fix typo in emphasize_stuff_in_headers()
2020-03-06 21:28:55 +01:00
Dirk WetterandGitHub c4d2c2de48 Merge pull request #1529 from dcooper16/percent_printing_3.0
Fix printing percent characters
2020-03-06 20:04:45 +01:00
Dirk WetterandGitHub 069baa0b6e Merge pull request #1522 from drwetter/pwdfix3
avoid external pwd
2020-03-06 15:04:18 +01:00
Dirk WetterandGitHub 488009d0cd Merge pull request #1528 from dcooper16/fix_html_3.0
Fix HTML generation in 3.0
2020-03-06 14:55:27 +01:00
Dirk Wetter 8e06fcc644 Avoid external "/bin/pwd"
.. as it may not be available everywhere, see #1521 (NixOS).

This commit replaces all instances from pwd or /bin/pwd by $PWD.
It is a bash internal and the fastest. Also it added some quotes
to PWD a it may contain white spaces in the future (currently
there's a check for it that it won't)
2020-03-06 13:31:48 +01:00
Dirk Wetter 4fcfb5d8f8 avoid external pwd
.. as it may not be everywhere available, see #1521 (NixOS).

This commit replaces it by `pwd -P` (-P -> no symbolic link)
2020-03-03 12:30:12 +01:00
Dirk WetterandGitHub 4dbd9a98ba Merge pull request #1511 from drwetter/rDNS_fixes3
Fix for non compliant DNS PTR records (backport)
2020-02-15 15:23:07 +01:00
Dirk bc9cf9f428 Fix for non compliant DNS PTR records
This commit addresses two bugs: #1506 and #1508.

First, the variable rDNS can contain multiple lines due to multiple PTR DNS
records, though this is not recommended.  In those cases the multiple PTR DNS
were concatenated on the screen, without any blank.

Secondly - depending on the name server entries and on the output of the DNS
binaries used it can contain non-printable characters or characters which are
printable but later on interpreted on the output device (\032 was mentioned
in #1506) which on the screen was interpreted as octal 32 (decimal 26 = ▒,
try echo "\032"), so basically a terminal escape sequence was smuggled
from the DNS server to the screen of the users. In JSON pretty output we
had also this escape sequence which was fine for jsonlint but caused jq
to hiccup.

Fix: we use a loop to check for each FQDN returned. There we remove chars which
under those circumstances can show up. The blacklist is taken from RFC 1912
("Allowable characters in a label for a host name are only ASCII, letters, digits,
and the `-' character").
2020-02-15 13:56:25 +01:00
Dirk WetterandGitHub 7d38f3c365 Merge pull request #1494 from dcooper16/fix_typos_3.0
Fix typos
2020-02-04 17:56:58 +01:00
Dirk WetterandGitHub 20daaa667c Merge pull request #1493 from drwetter/dotasurl_fix_3.0
Fix URL when hostname with trailing dot supplied
2020-02-04 17:17:57 +01:00
Dirk Wetter f11b9023d6 Fix URL when hostname with trailing dot supplied
Hostnames can contain a trailing dot (and sometimes they should).
If they are supplied to testssl.sh however they will be also interpreted
as a URL PATH when the servive is HTTP.

This commit fixes that.

See also #1490
2020-02-04 16:32:34 +01:00
Dirk WetterandGitHub 0252316637 Merge pull request #1485 from drwetter/fix_ids_friendly
Fix --ids-friendly
2020-01-31 08:46:37 +01:00
Dirk Wetter c4920f61e4 rename query_globals() --> count_do_variables()
.. and fix one problem instroduced with last patch (testssl.sh
din't work correclty if only an URI was supplied)
2020-01-30 22:25:10 +01:00
Dirk Wetter 073d383f76 Fix switch --ids-friendly
This switch had no effect. There was probably a regression
problem as it worked before.

Besides fixing that the large case statement in parse_cmd_line()
was simplified, in a sense that banner and help functions were
moved to a separate case statement.
2020-01-30 21:49:56 +01:00
Dirk WetterandGitHub b0b084dcda Merge pull request #1442 from drwetter/bump_version
bump version to final
2020-01-23 18:08:23 +01:00
Dirk WetterandGitHub a11a060acb Merge pull request #1456 from drwetter/changes_etc
Update attributions and changes for release
2020-01-23 18:05:50 +01:00
Dirk WetterandGitHub a9e5bcc30c Merge pull request #1470 from drwetter/1xmsg_squash
Squash the last futile -msg for $OPENSSL
2020-01-23 11:03:46 +01:00
Dirk ace4098693 Squash the last futile -msg for $OPENSSL
... see also https://github.com/drwetter/testssl.sh/pull/1468#discussion_r369786007
2020-01-23 09:46:33 +01:00
Dirk WetterandGitHub 631755ceb1 Merge pull request #1464 from drwetter/further_handshakes
Further handshakes / minor changes
2020-01-22 22:30:16 +01:00
Dirk WetterandGitHub fa4f1e4366 Merge pull request #1468 from nosnilmot/fix-xmpp-starttls
Fix XMPP starttls
2020-01-22 21:09:51 +01:00
Dirk 5083e950d2 Move debugging remainders detection to t/00_testssl_help.t 2020-01-22 21:04:23 +01:00
Dirk WetterandGitHub ec722e0e9c Merge pull request #1469 from dcooper16/simplify_draft_tls13_version_determination
Simplify code to determine draft TLS 1.3 version
2020-01-22 20:39:10 +01:00
Dirk WetterandGitHub f7ab5a0821 Move quotes...
as David suggested.
2020-01-22 20:34:00 +01:00
Dirk WetterandGitHub 7619e430f2 Merge pull request #1466 from dcooper16/fix_run_ssl_poodle
Fix run_ssl_poodle()
2020-01-22 18:05:08 +01:00
Dirk WetterandGitHub 2602e14191 Merge pull request #1465 from dcooper16/undo_copy_paste_error
Undo copy and paste error
2020-01-22 17:25:33 +01:00
Dirk WetterandGitHub 2181061c6e Merge pull request #1463 from drwetter/shortcurt_vulns
Shortcuts for vulnerability tests for TLS 1.3 only servers
2020-01-22 15:37:11 +01:00
Dirk Wetter eeb1acd749 Android 9 still has 2 signature hash algos: x0201 + x0203 2020-01-22 11:41:42 +01:00
Dirk d4d5a61a0b Hopefully make Travis shut up now
picked a TLS 1.2 host
2020-01-22 11:30:21 +01:00
Dirk cae052cfab Address some HTML check failures in travis
(shouldn't work too late)
2020-01-22 11:29:04 +01:00
Dirk Wetter 7c66ed47c0 All self retrieved Android handshakes modified to service ANY 2020-01-22 10:58:00 +01:00
Dirk Wetter a50a660d6c Add Android 10 client simulation 2020-01-22 10:54:50 +01:00
Dirk Wetter ca8054184b remove also leading colon in helper script bc of GREASE 2020-01-22 10:52:07 +01:00
Dirk 39abb27dd9 cloudflare seems not good for html travis checks 2020-01-22 00:28:59 +01:00
Dirk 80530aa34c remove fast as it makes problems especially with Travis+testssl.net 2020-01-21 23:53:52 +01:00
Dirk e0f8c8d43e Relax misunderstanding of DEBUG statemement
There's a check for >825 days certificate lifetime. That
check emits a debug statement when the lifetime is within
this limit. It does that also when the certificate expired.

This commit adds now the word "total"

DEBUG: all is fine with total certificate life time

to make sure the life time left not is what should be understood.
2020-01-21 22:47:53 +01:00
Dirk 26a8f23ec1 Shutup Travis
... by adding the formerly intruoced "DEBUG" statement as a filter.
Note: "DEBUG" can now / should now be taken preferably for extra
output on debug level 1.

Replacing badssl.com by testssl.net. The former needed almost 5 min
for a run, whereas one IP of testssl.net needs ~80 secs. With --fast
even less.
2020-01-21 22:41:50 +01:00
Dirk 952231dd94 Shortcuts for vulnerability tests
Several vulnerability checks add a time penalty when the server
side only support TLS 1.3 as The TLS 1.3 RFC 8446 and implementations
known so far don't support the flaws being checked for.

This PR adds "shortcut" checks for all TLS 1.3, assuming that the
TLS 1.3 implementation is correct which seems at this time a valid
assumpution. That either saves a TCP connect or at least some logic to
be executed.  Also in some cases a TLS 1.3 only server emitted unnecessary
warnings, see #1444.

If $DEBUG -eq 1 then it outputs information that a shortcut was
used. It doesn't do that in other cases because the screen output
seems too obtrusive.

It also adds a shortcut for beast when SSL 3 or TLS 1.0 is is known
not to be supported.

This commit radds 747fb039ed which
was accidenially reverted in 45f28d8166.
It fixes #1462.

See also #1459.
2020-01-20 21:37:02 +01:00
Dirk 431f4fbe5f last walk through the changelog 2020-01-20 12:50:31 +01:00
Dirk 3e8d1983b3 reorder / rephrase some points 2020-01-20 12:49:49 +01:00
Dirk WetterandGitHub c08250d1bb Merge pull request #1461 from drwetter/ci_setx
add check for forgotten "set -x" + provide defined start conditions
2020-01-20 12:20:07 +01:00
Dirk 45f28d8166 Revert "Shortcuts for TLS13 only servers in renegotiation checks"
This reverts commit 747fb039ed.
2020-01-18 21:55:35 +01:00
Dirk 44d1139e99 Revert "Complete shortcut checks (Renegotiation and CRIME)"
This reverts commit 8c24d1a6f2.
2020-01-18 21:54:42 +01:00
Dirk f109d3bbd6 add unlink / start with a clean state
... good when running "prove -v" locally and previously
the run was interrrupted by e.g. ^C
2020-01-18 21:47:44 +01:00
Dirk cb6677e2d3 removed comment 2020-01-18 21:45:32 +01:00
Dirk bec9ebdda8 only one ip 2020-01-18 21:44:24 +01:00
Dirk 2563dfb5e5 add set -x 2020-01-18 21:36:19 +01:00
Dirk 8c24d1a6f2 Complete shortcut checks (Renegotiation and CRIME)
This also makes a short exit when the server side
supports TLS 1.3 only as this protocol doesn't support
TLS renegotiation or compression.

Also it fixes the logic flaw from the previous
commit that "-no_tls1_3" has to be supplied.

Furthermore, it unifies the output presented to the user.
2020-01-18 12:31:38 +01:00
Dirk WetterandGitHub 155824214b Merge pull request #1460 from drwetter/drwetter-patch-1
add also here -z
2020-01-17 15:26:09 +01:00
Dirk WetterandGitHub adfa411e24 add also here -z 2020-01-17 15:24:36 +01:00
Dirk 747fb039ed Shortcuts for TLS13 only servers in renegotiation checks
As noted in #1444 a few vulnerability checks don't make sense
or aren't working.  This commit addresses the renegotiation checks.

Also a few redundant quotes in parse_tls_serverhello() and
run_crime() were removed.
2020-01-17 15:16:26 +01:00
Dirk WetterandGitHub 71b6305e00 Merge pull request #1458 from drwetter/drwetter-patch-2
fix language
2020-01-17 11:59:50 +01:00
Dirk WetterandGitHub ddc7a56ab0 fix language 2020-01-17 11:59:41 +01:00
Dirk WetterandGitHub a094ebc981 Merge pull request #1457 from drwetter/drwetter-patch-2
fix missing -z
2020-01-17 11:57:36 +01:00
Dirk WetterandGitHub 1fb2db02a7 Update docker-debian10.tls13only.start.sh 2020-01-17 11:57:13 +01:00
Dirk 2ea57f0701 Update attributions and Changes for release
If anything is missing or wrong please let us know or do a PR.

(This is until from earlier time to ~2018. >2019 need to follow)
2020-01-17 11:01:41 +01:00
Dirk WetterandGitHub 03fb04a9f9 Merge pull request #1455 from drwetter/drwetter-patch-1
Warning for handshake retrieved by Google apps
2020-01-16 22:48:07 +01:00
Dirk WetterandGitHub ac7a20f018 Update client-simulation.wiresharked.md 2020-01-16 22:46:43 +01:00
Dirk WetterandGitHub 86afeabf8f Merge pull request #1438 from drwetter/update_clienthandshakes
Update clienthandshakes
2020-01-16 22:26:21 +01:00
Dirk WetterandGitHub c2060c08f3 Merge pull request #1454 from dcooper16/basic_auth_polishing
More polishing of http basic auth
2020-01-16 20:24:39 +01:00
Dirk WetterandGitHub 91e14a3840 Merge pull request #1452 from drwetter/add_1451
Last fine tuning for http basic auth
2020-01-16 16:34:09 +01:00
Dirk WetterandGitHub 0691dc1bf8 Merge pull request #1453 from mkauschi/add-cache-control-header-check
Check for the Cache-Control and Pragma header
2020-01-16 16:25:18 +01:00
Dirk Wetter 4603d924be Last fine tuning for http basic auth
* create roff file and HTML
* add hint to $ENV

Avoid 1x subshell

See #1451.
2020-01-16 14:29:53 +01:00
Dirk WetterandGitHub 700a727f3f Merge pull request #1451 from mkauschi/http-basic-auth-support
Add support for HTTP Basic Auth
2020-01-16 14:13:59 +01:00
Dirk WetterandGitHub 787e575085 Merge pull request #1450 from drwetter/826days_towarn
Add one second for 825 day validity test
2020-01-15 15:38:26 +01:00
Dirk Wetter 38a00f7170 Add one second for 825 day validity test
The CA browser form agreed on a validity period of 825 days or less
(https://cabforum.org/wp-content/uploads/CA-Browser-Forum-BR-1.5.3-redlined.pdf,
p4).

PR #1427 addressed that. However when an issuer signed/issued a certificate
with exactly 825 days, the check reported incorrectly that the life time
is too long.

This commit addressed that by adding a second to the calulation. Also the
output takes into account that it must be over ('>') 825 days, not '>='.
2020-01-15 15:32:32 +01:00
Dirk WetterandGitHub 520a4fbf75 Merge pull request #1449 from drwetter/pr_1070
Reimplement mitigation check (renegotiation->node.js)
2020-01-15 13:09:39 +01:00
Dirk Wetter 2ed317441f Reimplement mitigation check (renegotiation->node.js)
See #1070, kudos @poupas.

In addition it checks whether the first result was positive (in
terms of a finding). If so it does 4 rounds and checks the
result. So that other servers won't be penalized with 4 seconds.
2020-01-15 12:11:57 +01:00
Dirk WetterandGitHub 2a87f7505d Merge pull request #1445 from drwetter/alternative_temppath
Try temp file creation in a different location
2020-01-15 09:59:12 +01:00
Dirk Wetter 50ea6b1891 $PWD check : negate pattern + add $BASH_REMATCH 2020-01-14 22:52:47 +01:00
Dirk Wetter 50c9075ba8 Provide whitelist for $PWD
see #1445
2020-01-14 20:41:08 +01:00
Dirk WetterandGitHub e75ed94573 Merge pull request #1446 from dcooper16/add_missing_declarations
Add missing variable declarations
2020-01-14 20:17:07 +01:00
Dirk Wetter f0f8f3a318 Remove TEMPPATH, make sure PWD doesn't contain a blank 2020-01-14 20:09:46 +01:00
Dirk Wetter 8518284795 Try temp file creation in a different location
... if the standard directory /tmp is not allowed to write to.
As noted in #1273 this might be the case for Termux on Android.
2020-01-14 18:55:09 +01:00
Dirk Wetter 8d864aba2e Output adjustments closer to a more common format 2020-01-14 18:44:11 +01:00