Commit Graph
100 Commits
Author SHA1 Message Date
Dirk 4aabc3f999 Merge branch 'skip_offensive' into 2.9dev 2018-06-26 13:10:18 +02:00
Dirk 33cf1d524c Fine tuning if Jac2NL's commit of IDS evasion
Reduce the offensive tests to 4: the others are "just" / mostly cipher
based checks which should not cause an IDS to block. (This maybe
subject to reconsider at a later time.)

Added a switch --ids-friendly

Updated VULN_COUNT accordingly

Added this (including PHONE_OUT to env debugging output)

Added help()

Manual section added
2018-06-26 13:04:30 +02:00
Dirk 01f177199c Merge branch 'Jac2NL-2.9dev' into skip_offensive 2018-06-26 12:36:01 +02:00
Dirk 3ce22ed8df Merge branch '2.9dev' of https://github.com/Jac2NL/testssl.sh into Jac2NL-2.9dev 2018-06-26 12:35:29 +02:00
Dirk 87f0cda234 Fix #1071 : typos and link in docu 2018-06-25 18:31:55 +02:00
Dirk WetterandGitHub 0355145576 Merge pull request #1074 from dcooper16/fix615
Fix #615
2018-06-22 14:18:23 +02:00
Dirk aa0f33e984 Update RFC section in ~/doc with soon to be TLS 1.3 RFC
See PR #1072, title taken from
https://github.com/ietf/draft-ietf-tls-tls13/blob/master/rfc8446.xml
(maybe subject to change).

Todo: Handle the obsolted ones, maybe by adding "obsolete"
2018-06-20 09:41:51 +02:00
Dirk WetterandGitHub 8e144e8e6f Merge pull request #1072 from dcooper16/rfc8446
TLS 1.3 will be RFC 8446
2018-06-20 09:25:10 +02:00
Dirk f2944205b9 Fix output error when $HEADERFILE was empty 2018-06-19 10:27:42 +02:00
Dirk d23241b8cd Fix to-be-expired-soon certificate
The certificate from self-signed.badssl.com was about to expire
which raises a MEDIUM type issue in testssl.

This commit does a workaround for this, so that those certificates
will be ok in Travis CI.

(Same problem exists in 2.9.5)
2018-06-13 14:30:35 +02:00
Dirk b6cc01a558 Fix line feeds in vulnerabilty output when running in wide mode
This commit is a FIX for #1069, thus when running in
wide mode it corrects an additional line feed which
happened sometimes.

As @dcooper16 pointed out it also cleans up the needless
if-statements in run_rc4(), run_lucky13() and run_beast().

It also inserts for wide mode lines a blank so the alignment
is not at the left border anymore (check for leftovers
needed).
2018-06-13 13:25:02 +02:00
Dirk WetterandGitHub 1be25f9cf7 Merge pull request #1067 from dcooper16/revocation_checking_errors
Fix false "revoked" results for CRL and OCSP checking
2018-06-05 10:33:42 +02:00
Dirk WetterandGitHub 626e0fc65a Merge pull request #1066 from dcooper16/ocsp_error_responses
OCSP error handling
2018-05-25 22:28:05 +02:00
Dirk c21ed3212e add a small hint how to use the tuning vars 2018-05-24 13:09:56 +02:00
Dirk 770f3ea832 fix typo in cmd line arg for -oA 2018-05-24 10:48:25 +02:00
Dirk WetterandGitHub ec57b64339 Merge pull request #1064 from dcooper16/ocsp_checking
OCSP improvements
2018-05-23 22:38:50 +02:00
Dirk f426a3bb21 Merge branch 'crl_ocsp' into 2.9dev
OCSP revocation checks ran with a 100% success rate for the Alexa ~Top 1000
(basis: all hosts supporting TLS and having an OCSP URI)
2018-05-23 15:09:03 +02:00
Dirk WetterandGitHub d578adb05c Merge pull request #1062 from dcooper16/certificate_validity_dates
Fix extraction of certificate validity dates
2018-05-23 10:51:29 +02:00
Dirk 92eaa3e7d3 Merge #1047 before processing #1051 2018-05-18 22:39:19 +02:00
Dirk WetterandGitHub 31b26da691 Merge pull request #1060 from dcooper16/multicomponent_ocsp_uris
HTTP URLs with multiple components in path
2018-05-18 21:40:56 +02:00
Dirk 7d36734a96 Handle host header in OCSP request properly
My previous commit added a host header but didn't properly
format the host header (trailing slashes / path). This commit
corrects that so that the 305 times HTTP 400 in #1056
should now be gone (TBC), including Google CA responders.

One issue which needs to be addressed (same as in CRL
revocation checks): Not trusted certificates (zhanqi.tv,
taken from my Alexa scans) fail for obvious reasons.
2018-05-18 20:30:37 +02:00
Dirk 82aae158ba Minor additions to OCSP revocation check
Error from OCSP responder is now being displayed (and logged to JSON, ...)

Whole replay is kept in $tmpfile for debugging purposes

JSON output added for OCSP responderi query failures

Furtermore wget was replaced by "type -p" and grep by fgrep.
2018-05-16 19:52:10 +02:00
Dirk fac65d82b0 Add host header to OCSP Request
Some OCSP responder seems to need a host header, see e.g.
https://blog.ivanristic.com/2014/02/checking-ocsp-revocation-using-openssl.html .

This commit adds this header.

It addresses not all errors though. E.g. "https://testssl.sh" is fine now,
"https://google.com" still returns "Code=400,Reason=Bad Request" which
needs further investigation,

Also this commit gives a warning if the OCSP request fails (fileout needs
to be added)
2018-05-16 15:51:45 +02:00
Dirk WetterandGitHub 567cc05fca Merge pull request #1055 from dcooper16/ocsp_checking
Add OCSP checking
2018-05-16 11:11:00 +02:00
Dirk WetterandGitHub e68b1ce025 Merge pull request #1054 from dcooper16/fix1053
Fix #1053
2018-05-15 17:54:09 +02:00
Dirk WetterandGitHub be743e0c9b Merge pull request #1052 from dcooper16/draft28
TLS 1.3 draft 28
2018-05-07 10:58:49 +02:00
Dirk WetterandGitHub a787ba0ec5 Merge pull request #1048 from dcooper16/ldap_get_failure
ldap_get() should fail if curl fails
2018-05-07 10:55:54 +02:00
Dirk WetterandGitHub b6c527598b Merge pull request #1049 from dcooper16/dont_offer_compression
Don't offer TLS compression by default
2018-05-02 11:08:51 +02:00
Dirk WetterandGitHub 4b39039209 Merge pull request #1050 from dcooper16/remove_extra_space
Remove extra space in BEAST output
2018-05-02 11:00:01 +02:00
Dirk 470f8b62e6 jsonID HTTP status code as variable 2018-04-28 22:38:53 +02:00
Dirk 168eec447a Merge branch 'crl_ocsp' into 2.9dev 2018-04-28 22:36:27 +02:00
Dirk 0851599a4e Polish existing CRL revocation check code
* Extra function for ldap_get()
  * Hint when curl is not installed and LDAP URI is encountered
  * Rename jsonID cert_cRLDistributionPoints to cert_crlDistributionPoints
  * Fix trailing _ in jsonID

Open/to be clarified:

   * Proxy for curl / proxy needs to come from testssl.sh
   * Proxy support for HTTP bash socket GET
   * cert_CRLrevoked comes before cert_cRLDistributionPoints
   * Unit tests

Still open: OCSP
2018-04-28 22:25:43 +02:00
Dirk 5ff9fe0f0d Merge branch 'dcooper16-ldap_urls' into crl_ocsp 2018-04-27 21:49:00 +02:00
Dirk c3927d00c8 Document --phone-out 2018-04-27 21:37:44 +02:00
Dirk WetterandGitHub da49603c46 Merge pull request #1042 from dcooper16/non_http_crldp
non-HTTP cRLDistributionPoints
2018-04-26 17:08:32 +02:00
Dirk WetterandGitHub 6d919de0ad Merge pull request #1043 from dcooper16/expired_certs
Don't check expired certificates
2018-04-26 16:51:20 +02:00
Dirk ddf5ff6bc9 Minor additions wrt --color=3 and fname prefix 2018-04-26 09:39:30 +02:00
Dirk WetterandGitHub af2f6dd353 Merge pull request #1041 from dcooper16/server_preference_list
Update ciphers for server preference
2018-04-25 23:09:30 +02:00
Dirk c4f42fd6c7 Experimental support for certificate check via CRL
In order to use it one has to use --phone-out  (PHONE_OUT
is the respective ENV) like

``./testssl.sh --phone-out --json-pretty -S wikipedia.org``

This makes use of curl (if available) or wget (if available) and
falls back to bash socket GET. The latter uses HTTP/1.0 as
chunked transfers by the server (used for bigger files normally)
can't be reasonably separated from their HTTP header. (HTTP/1.0
doesn't support chunked transfers).

curl and wget use the enviroment variables automatically. Probably
we want to use those proxies only if told by a switch to testssl.sh.

"-crl_download" would have been an option. Support would have
been needed to check beforehand. Alos information on proper
usage seems limited, so for now a solution which works is
preferred.

Open/to be clarified:

  * Documentation
  * Proxy for curl / proxy needs to come from testssl.sh
  * Proxy support for HTTP bash socket GET
  * JSON ID is cert_CRLrevoked_ (trailing underscore)
  * cert_CRLrevoked_ comes before cert_cRLDistributionPoints
  (* reconsider naming of cert_cRLDistributionPoints)
  * Unit tests

Still open: OCSP
2018-04-25 22:34:47 +02:00
Dirk e84d0cf170 First prototype of CRL checker
As it would be a possible privacy violation a new flag PHONE_OUTSIDE
is introduced (later accompanied by a switch). It determines whether
the client is allowed to retrieve the CRL specified (HTTP only supported).

Tested ok against wikipedia.de and revoked.badssl.com.

To do:
  * look into -crl_download
  * fileout
 * Unit tests

OCSP verification
2018-04-24 17:52:01 +02:00
Dirk WetterandGitHub 90b671fbb3 Merge pull request #1040 from dcooper16/fix_typo
Fix typo
2018-04-23 21:37:13 +02:00
Dirk WetterandGitHub 1a03e31a7d Merge pull request #1039 from dcooper16/csv_json_mass_testing
JSON and CSV output problem with mass testing
2018-04-23 18:19:47 +02:00
Dirk 8149c2d5cf CCS injection: better handling of TLS alert protocols
In certain situations while testting for CCS injection it could have happened
that an error code was sent which was not interpreted properly by testssl.sh.
(https://tools.ietf.org/html/rfc5246#section-7.2)

This has now been fixed and thus addresses #906. Also it has been made sure
that other error codes are reported appropiately.

The case where this test failed before was a non-patched Ubuntu 12.04
with openssl/postfix on port 25.
2018-04-20 11:31:05 +02:00
Dirk 39647d1703 Shellcheck, bump version to 3.0beta
For the upcoming release this commit initiated the beta phase: important features
will be allowed. On the agenda is otherwise to fix bugs.

I ran shellcheck (see #434), and fixed some complaints and adjusted some coding
style mismatches.
2018-04-19 17:57:52 +02:00
Dirk cd01351f96 Merge branch '2.9dev' of github.com:drwetter/testssl.sh into 2.9dev 2018-04-19 08:26:57 +02:00
Dirk b8e9b09ca7 FIX #592 (double header)
There were some cases where security headers were served two times by the
server. The result (screen+html) wasn't properly formatted in those cases.

match_httpheader_key() was improved so that it keeps track when
a CR or an indentation needs to be done.

Some egrep statements were replaced by grep -E as this has been used
already and it is the thing testssl.sh should settle for. (precursor
to #1022).

run_more_flags was renamed to sun_security_headers and names of
variables is better.

HAS_SPDY is now HAS_NPN (similar to renaming the function a while
back)

mktemp should only be used when not avoidable (performance, code). For
temporarily local variables names can often be borrowed from globals
which were already generated by mktemp (SOCK_REPLY_FILE).
2018-04-19 08:11:28 +02:00
Dirk e8d7ba547a remove old client_simulation.txt 2018-04-18 21:09:31 +02:00
Dirk c15e0425dc Update client simulation
This is a fix for #722. It updates the client simulation data from
the SSLlabs API. As usual data was pulled, resorted and clients
to display were hand-selected.

Wishlist: Missing is Oreo, OpenSSL 1.1.1, Safari on OX 11, Firefox
52.x (ESR)

With the recent PR #1033 from @dcooper it can also show TLS 1.3
handshakes.
2018-04-16 11:13:44 +02:00
Dirk WetterandGitHub 55adbf905f Merge pull request #1033 from dcooper16/client_sim_data_tls13
TLS 1.3 clients in update_client_sim_data.pl
2018-04-16 09:07:35 +02:00
Dirk WetterandGitHub e38a30d54e Merge pull request #1034 from dcooper16/client_sim_grease_ciphers
update_client_sim_data.pl and GREASE ciphers
2018-04-16 08:52:57 +02:00
Dirk WetterandGitHub ea4fb5517f Merge pull request #1032 from dcooper16/fix_mass_testing
Fix mass testing
2018-04-13 07:01:30 +02:00
Dirk 42e3f4ea14 "Resource" has only one "s" in English 2018-04-12 18:15:54 +02:00
Dirk e7619fa8d9 Documenting exit error codes improvements
See prevoius commit b2be380b54 and
issue #985 / #752.
2018-04-12 18:14:14 +02:00
Dirk b2be380b54 Exit error codes improvements, some formatting
According to programming standards e.g. C-style defines) testssl.sh has now
internal error variables (ERR_*) which are defined to deal with exit codes in
error conditions. Details see ``testssl.sh(1)``, section exit.  Thus exit codes
because of an error are now standardized and if needed can be easily changed to
other values.

This is part of a cleanup mentioned in #985 and #752. Codes for monitoring
tools (#327) which imply some kind of rating are still to be done.

The beginning section was reformatted and some items were reordered to keep
variables and functions together which serve similar purposes.

``readonly`` was replaced by ``declare -r`` (closer to C's define and it
makes more sense to settle on one variable if both are being used
for the same purpose)
2018-04-12 17:53:53 +02:00
Dirk WetterandGitHub 24a392d6eb Merge pull request #1031 from dcooper16/client_simulation_ssl_native
Improve SSL native client simulation
2018-04-12 12:25:11 +02:00
Dirk 36247fecf2 fix no-DNS related error in documentation 2018-04-12 01:19:02 +02:00
Dirk 4370cb9aa1 no-DNS fixes
Add equal sign parser for command line fix. Readjust help to not-square
brackets as values are not optional (anymore)
2018-04-12 01:11:23 +02:00
Dirk 2a4de68c59 Merge branch 'nodns-935' into 2.9dev 2018-04-12 01:06:33 +02:00
Dirk 9f0e442b9f remove some no-DNS related logic
... from "Further IP addresses" and before calling ``get_aaaa_record``
in ``determine_ip_addresses()``. Logic appeared needlessly to difficult
and was as far as the "Further IP addresses" line was concerned incomplete.
2018-04-12 00:53:26 +02:00
Dirk 557942cb0a Change logic and add conservative value for -n/--nodns (#935)
This PR changes the logic the no-DNS switch works. The switch
now expects a value. "min" does minimum lookups, "none" does
no lookups at all (details see testssl.sh(1) ). "none" is
equivalent to the paranoid (boolean) value "true" before.
2018-04-12 00:19:52 +02:00
Dirk WetterandGitHub c357ea7356 Merge pull request #1030 from dcooper16/fix_dh_groups_output
Fix RFC 7919 DH groups
2018-04-10 18:47:23 +02:00
Dirk WetterandGitHub a0c17fda9f Merge pull request #1029 from knweiss/typos
Fix typos found by codespell
2018-04-10 17:45:17 +02:00
Dirk WetterandGitHub 7ac63ec84b Merge pull request #1028 from dcooper16/fix_false_connectivity_problems
Fix false connectivity problem error
2018-04-10 17:18:12 +02:00
Dirk eb3b3a1988 be more verbose what --warnings=batch means (see #1027) 2018-04-05 22:02:35 +02:00
Dirk 6b8f6f82c3 Fix comments in run_logjam, replace awk by bash internal match expr
``run_logjam()`` contained in certain cases additional quotes
and a typo where only the word comment ended up in JSON/CSV.

Instead of ``$(awk '/Master-Key: / { print $2 }' "$2")`` the
admittedly performance sensitive function ``sclient_connect_successful()``
contains now a bash internal match according to #997 . First
tests didn't show much benefit (only default run with mostly
sockets was tested).

Unit tests showed no problems so far, but coverage is low.
2018-03-28 19:46:55 +02:00
Dirk 1924c9a0a6 Connectivity problems, man page update
See previous commit

This commit finally fixes #1005 so that either a --ssl-native scan
terminates on the next (defined) occasion if there are network connectivity
problems. It introduces another set of variables (MAX_OSSL_FAIL vs. NR_OSSL_FAIL).
As "openssl s_client connect" is sometimes still being used without --ssl-native
it also shortens the wait for regular scans if an outage is encountered.
To make things easier bot sets (incl. *_SOCKET_FAIL) of variables are independent.

For the seldom case that somebody uses --ssl-native with client checks an exception
had to be made as otherwise only MAX_OSSL_FAIL client check would be performed.
This hasn't been understood yet...

As sometimes HTTP header requests (over OpenSSL) fail repeatedly in a way that an empty
reply is returned, the same strategy of detecting problems is applied here,
using MAX_HEADER_FAIL and NR_HEADER_FAIL.

All three detection mechanisims share a new function connectivity_problem().
2018-03-28 17:48:04 +02:00
Dirk baabf2a61e Connectivity problems, readd some CVEs+CWEs
This commit finally fixes #1005 so that either a --ssl-native scan
terminates on the next (defined) occasion if there are network connectivity
problems. It introduces another set of variables (MAX_OSSL_FAIL vs. NR_OSSL_FAIL).
As "openssl s_client connect" is sometimes still being used without --ssl-native
it also shortens the wait for regular scans if an outage is encountered.
To make things easier bot sets (incl. *_SOCKET_FAIL) of variables are independent.

For the seldom case that somebody uses --ssl-native with client checks an exception
had to be made as otherwise only MAX_OSSL_FAIL client check would be performed.
This hasn't been understood yet...

As sometimes HTTP header requests (over OpenSSL) fail repeatedly in a way that an empty
reply is returned, the same strategy of detecting problems is applied here,
using MAX_HEADER_FAIL and NR_HEADER_FAIL.

All three detection mechanisims share the new function connectivity_problem().

In addition unit tests showed that some vulnerability checks lost their
CVEs+CWEs whcich have been readded. For ROBOT a CVE was added (F5)
2018-03-28 17:28:55 +02:00
Dirk 991521957d housekeeping and FIX #406 2018-03-28 11:46:53 +02:00
Dirk WetterandGitHub 653827cfe1 Merge pull request #1024 from dcooper16/fix_client_simulation
Fix client simulations
2018-03-27 09:10:55 +02:00
Dirk 224d851f7b workaround for missing date format conversion (OpenBSD) in http date 2018-03-24 19:37:05 +01:00
Dirk 7c015c5a13 Dealing with OpenSSL connect problems (part1, framework)
In addition to 080840f655 and to
address #1005 eventually this is the first part of dealing
with connectivity problems. As opposed to the commit mentioned
above this is the counterpart for openssl which is useful for
just normal usage and for using --ssl-native.

It adds another global MAX_OSSL_FAIL (preset to 2) representing
a threshold how many unsucessful openssl connections are needed to
quit the whole scan. It should again reduce scan time in those
cases.

This is the framework part in sclient_connect_successful() which
is mainly commented out. The hooks will follow soon.
2018-03-22 16:59:57 +01:00
Dirk 4a24454880 FIX #1021 and make testssl.sh work again ;-( 2018-03-21 15:00:16 +01:00
Dirk ffd89f8dea Address 4xx after STARTTLS handshake seems to have succeeded
In certain cases (see e.g. #939) the server side "kind of" falls back
from a TLS channel to the underlying plaintext STARTTLS with a 5xx
or 4xx.

This PR adds the detection of 4xx for all protocols (if STARTTLS has been
used) and labels the detection as "likely not av" (and keeps the warning). This
leads to two JSON/CSV objects in those cases.

The detection isn't quite perfect as the issue #939 shows the first
TLS message fragment resembles a TLS alert.

As noticed it also removes the recommendation to increase the
debug level if the level is already sufficient.
2018-03-21 12:36:25 +01:00
Dirk 50f7c93046 missing HSTS in JSON had wrong severity
FIX #1010 where a missing HSTS header lead to HIGH severity
whereas screen output was on info level.

In order to emphasize the importance of HSTS a missing header
flag will now be slighly penalized. To be in line with HSTS=0
the latter needed to be readjusted to medium as well.

As suggested by krissi for better readability a missing HSTS
header will now be 'not offered' instead of '--' on screen.
2018-03-21 10:08:38 +01:00
Dirk WetterandGitHub 83b09067a4 Merge pull request #1017 from dcooper16/fix1013
Fix #1013
2018-03-21 09:35:35 +01:00
Dirk WetterandGitHub 27b217b301 Merge pull request #1020 from dcooper16/ossl_ver_appendix
Fix OSSL_VER_APPENDIX
2018-03-19 16:52:20 +01:00
Dirk WetterandGitHub a7d195fb89 Merge pull request #1018 from dcooper16/fix1015
Fix #1015
2018-03-19 16:15:49 +01:00
Dirk WetterandGitHub 2c8bdcd205 Merge pull request #1019 from dcooper16/ossl_ver
Extracting OpenSSL version information
2018-03-19 16:13:47 +01:00
Dirk a178f3e183 relax host+domain names to contain underscore, see #1015 2018-03-18 23:38:23 +01:00
Dirk c91a771465 FIX #1009 and leftover fix for #988
In cases where HTTP/2 was the only ALPN protocol, the
JSON output was missing the finding as the additional
protocol was empty.

This fix tests whether there's an additional protcol
and only calls fileout() if there's one.
2018-03-17 20:37:00 +01:00
Dirk 4eb6ab5976 better naming of variables from previous commit 2018-03-17 19:44:40 +01:00
Dirk 377bde14cc Fixes ssl-native and LOGJAM: no common primes
When testssl.sh was using -ssl-native and the local openssl version
didn't support any DH ciphers the deliberately lazy approach was to
not complete the second part of the test: check for common primes.
This is a FIX for issue #1016.
2018-03-17 15:40:28 +01:00
Dirk WetterandGitHub f6dc501aed Merge pull request #1014 from dcooper16/tls13_cipher_pre_check
Check for TLSv1.3 in OpenSSL
2018-03-15 21:51:44 +01:00
Dirk WetterandGitHub 15ca770980 Merge pull request #1012 from dcooper16/tls13_draft26
TLS 1.3 drafts 25 and 26
2018-03-15 21:51:02 +01:00
Dirk WetterandGitHub 107d2dd12e Merge pull request #1007 from dcooper16/revert_read_sigalg_from_file
Revert change to read_sigalg_from_file()
2018-03-12 21:38:44 +01:00
Dirk WetterandGitHub f718592960 Merge pull request #1006 from dcooper16/X448
Add X448 support in TLS 1.3
2018-03-12 19:43:35 +01:00
Dirk 9618ed993d Better parsing of HPKP
Previously testssl.sh ran into problems when both Public-Key-Pins
and Public-Key-Pins-Report-Only were present in the header.

Now if both are present only Public-Key-Pins is evalutated and a
hint is given. If Public-Key-Pins-Report-Only is only present
a hint is given and those are evaluated.

If more than 1 from either Public-Key-Pins-Report-Only or
Public-Key-Pins is detected only the first one will be processed
and a warning will be displayed.
2018-03-03 21:40:46 +01:00
Dirk 1011ef1399 polish 2018-03-02 21:07:33 +01:00
Dirk 2e5dd0439a document variable for previous commit 080840f 2018-03-02 20:57:06 +01:00
Dirk 080840f655 fix uninitialized variables, proper exit if fail2van and friends
This commit improves assessments of server which decides after
a few connects either to drop all tcp packets or send a tcp
reset, see #1005 . It adds another global MAX_SOCKET_FAIL
(preset to 2) representing a threshold how many bash socket
connections are needed to quite the whole scan. It dramatically
reduces scan time and makes sure that the user is clear that
the scan had a problem and the results at maximum partly useful
(CSV, HTML, JSON). It also writes a valid JSON file.
See also #769.

It also fixes non-initialized variables in ``fileout_json_finding()``
and ``fileout()``
2018-03-02 20:39:07 +01:00
Dirk b1b30b3fb8 better matching of empty server banners
.. which could have led to borken JSON too
2018-03-01 16:01:05 +01:00
Dirk 8c9fdc6cc9 Fix HPKP regression where it stated that only one SPKI was used 2018-03-01 15:29:28 +01:00
Dirk b5fcc00031 reflect previous commit of changed treatment of --severity
... and some minor polishing
2018-03-01 15:13:55 +01:00
Dirk d344a1ee04 JSON(PRETTY) + CSV output when scan interrupted, WARN severity
If a severity level >= INFO was supplied,JSON* and CSV output were
not writing error conditions in fileout(). As those indicate a problem
of the assessment, this has been fixed so that if any severity is
supplied to testssl.sh it will always write WARN conditions
to file when detected.

Also if the scan was interrupted on the client side where previously
a scanTime of 0 was written to the log file now it will raise a warning
that the scan was interrupted.

See also #769. Error conditions after starting a scan on the server side
(TCP Reset, DROP after a while) still won't be treated accurately in the file output
with an error message but the resulting JSON should be still valid.
2018-03-01 13:47:34 +01:00
Dirk abc956344a Address/FIX #876 (empty addcmd2 variable) 2018-02-27 13:06:29 +01:00
Dirk WetterandGitHub 3cf591f513 Merge pull request #1002 from danielchodusov/2.9dev
Using generic HAProxy name
2018-02-22 14:49:32 +01:00
Dirk 415f98b655 Some improvements added. bash >= 3.2 is required 2018-02-19 11:55:12 +01:00
Dirk 5add07a798 make sure bash is at least 3.2, see #999 2018-02-19 11:31:03 +01:00
Dirk f812403292 Workaround for missing date conversion in OpenBSD
OpenBSD doesn't seem to be able to convert from $(date)
output to a more readable format as performed on notBefore
and notAfter from x509(1). Thus an exemption is made and
just display the format like x509(1) shows.

Also newer OpenBSD come with a newer LibreSSL version,
thus the pattern when to display a warning when the
"too unreliable to determine trust" warning is displayed.
2018-02-16 23:47:48 +01:00
Dirk WetterandGitHub 6f0a9aee11 Merge pull request #994 from dcooper16/extended_tls_sockets
TLSv1.3 draft 24
2018-02-15 21:18:45 +01:00