[glib-networking/mcatanzaro/session-resumption: 9/13] Run connection tests under TLS 1.2



commit addb8e1aec1482620c59cdc448bb67f83feebfcf
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Sat Aug 17 16:59:56 2019 -0500

    Run connection tests under TLS 1.2
    
    Currently the tests are run only using the current protocol version, TLS
    1.3 (unless your GnuTLS is so old as to not support TLS 1.3). But TLS
    1.2 is still important and we should be testing this too.

 tls/tests/meson.build | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)
---
diff --git a/tls/tests/meson.build b/tls/tests/meson.build
index 0b15a72..ac5d88a 100644
--- a/tls/tests/meson.build
+++ b/tls/tests/meson.build
@@ -88,16 +88,15 @@ foreach backend: backends
       'GIO_MODULE_DIR=' + join_paths(meson.build_root(), 'tls', backend)
     ]
 
-    if backend == 'gnutls'
-      test_envs += [
-        'G_TLS_GNUTLS_PRIORITY=NORMAL:%COMPAT:-VERS-TLS1.3'
-      ]
-    endif
-
-    # OpenSSL tests are disabled until we fix https://gitlab.gnome.org/GNOME/glib-networking/issues/54
+    # FIXME: OpenSSL tests are disabled until we fix https://gitlab.gnome.org/GNOME/glib-networking/issues/54
     if backend != 'openssl'
       test(program_name, exe, env: test_envs, depends: program[4])
     endif
+
+    if backend == 'gnutls' and program[0] == 'connection' or program[0] == 'dtls-connection'
+      # Run the tests again, this time with TLS 1.3 disabled so we can test TLS 1.2.
+      test(program_name + '-tls1.2', exe, env: test_envs + 
['G_TLS_GNUTLS_PRIORITY=NORMAL:%COMPAT:!VERS-TLS1.3'])
+    endif
   endforeach
 endforeach
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]