Fix no-dh builds
authorMatt Caswell <matt@openssl.org>
Thu, 12 Jan 2017 09:48:38 +0000 (09:48 +0000)
committerMatt Caswell <matt@openssl.org>
Thu, 12 Jan 2017 11:15:12 +0000 (11:15 +0000)
One of the new tests uses a DH based ciphersuite. That test should be
disabled if DH is disabled.

Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2217)

test/recipes/70-test_sslsignature.t

index 732e17eb6fbe4783ad4a19cd1cc43e42369df248..78928234067a62ed9ca027c9954cedbd7655c08b 100755 (executable)
@@ -93,14 +93,19 @@ SKIP: {
     $proxy->start();
     ok(TLSProxy::Message->fail, "Corrupt <=TLSv1.2 CertVerify");
 
-    #Test 4: Corrupting a ServerKeyExchange signature in <=TLSv1.2 should fail
-    $proxy->clear();
-    $testtype = CORRUPT_TLS1_2_SERVER_KEY_EXCHANGE;
-    $proxy->clientflags("-no_tls1_3");
-    $proxy->cipherc('DHE-RSA-AES128-SHA');
-    $proxy->ciphers('DHE-RSA-AES128-SHA');
-    $proxy->start();
-    ok(TLSProxy::Message->fail, "Corrupt <=TLSv1.2 ServerKeyExchange");
+    SKIP: {
+        skip "DH disabled", 1 if disabled("dh");
+
+        #Test 4: Corrupting a ServerKeyExchange signature in <=TLSv1.2 should
+        #fail
+        $proxy->clear();
+        $testtype = CORRUPT_TLS1_2_SERVER_KEY_EXCHANGE;
+        $proxy->clientflags("-no_tls1_3");
+        $proxy->cipherc('DHE-RSA-AES128-SHA');
+        $proxy->ciphers('DHE-RSA-AES128-SHA');
+        $proxy->start();
+        ok(TLSProxy::Message->fail, "Corrupt <=TLSv1.2 ServerKeyExchange");
+    }
 }
 
 sub signature_filter