Upstream version 7.36.149.0
[platform/framework/web/crosswalk.git] / src / net / test / spawned_test_server / base_test_server.h
index 163808c..392a72b 100644 (file)
@@ -72,6 +72,18 @@ class BaseTestServer {
       OCSP_UNKNOWN,
     };
 
+    // Bitmask of key exchange algorithms that the test server supports and that
+    // can be selectively enabled or disabled.
+    enum KeyExchange {
+      // Special value used to indicate that any algorithm the server supports
+      // is acceptable. Preferred over explicitly OR-ing all key exchange
+      // algorithms.
+      KEY_EXCHANGE_ANY     = 0,
+
+      KEY_EXCHANGE_RSA     = (1 << 0),
+      KEY_EXCHANGE_DHE_RSA = (1 << 1),
+    };
+
     // Bitmask of bulk encryption algorithms that the test server supports
     // and that can be selectively enabled or disabled.
     enum BulkCipher {
@@ -134,6 +146,11 @@ class BaseTestServer {
     // field of the CertificateRequest.
     std::vector<base::FilePath> client_authorities;
 
+    // A bitwise-OR of KeyExchnage that should be used by the
+    // HTTPS server, or KEY_EXCHANGE_ANY to indicate that all implemented
+    // key exchange algorithms are acceptable.
+    int key_exchanges;
+
     // A bitwise-OR of BulkCipher that should be used by the
     // HTTPS server, or BULK_CIPHER_ANY to indicate that all implemented
     // ciphers are acceptable.
@@ -165,6 +182,9 @@ class BaseTestServer {
 
     // Whether to staple the OCSP response.
     bool staple_ocsp_response;
+
+    // Whether to enable NPN support.
+    bool enable_npn;
   };
 
   // Pass as the 'host' parameter during construction to server on 127.0.0.1