summaryrefslogtreecommitdiff
path: root/jstests/sslSpecial/mixed_mode_sharded_nossl.js
diff options
context:
space:
mode:
Diffstat (limited to 'jstests/sslSpecial/mixed_mode_sharded_nossl.js')
-rw-r--r--jstests/sslSpecial/mixed_mode_sharded_nossl.js20
1 files changed, 20 insertions, 0 deletions
diff --git a/jstests/sslSpecial/mixed_mode_sharded_nossl.js b/jstests/sslSpecial/mixed_mode_sharded_nossl.js
new file mode 100644
index 00000000000..bbe002a2a04
--- /dev/null
+++ b/jstests/sslSpecial/mixed_mode_sharded_nossl.js
@@ -0,0 +1,20 @@
+/**
+ * This test checks if different mixtures of ssl modes
+ * in a sharded clutster can or cannot function
+ */
+
+load("jstests/ssl/libs/ssl_helpers.js");
+
+print("=== Testing disabled cluster ===");
+mixedShardTest(disabled, disabled, true);
+
+print("=== Testing disabled/preferSSL cluster - SHOULD FAIL ===");
+mixedShardTest(disabled, preferSSL, false);
+
+print("=== Testing allowSSL/disabled cluster ===");
+mixedShardTest(disabled, allowSSL, true);
+mixedShardTest(allowSSL, disabled, true);
+
+print("=== Testing allowSSL/preferSSL cluster ===");
+mixedShardTest(preferSSL, allowSSL, true);
+mixedShardTest(allowSSL, preferSSL, true);