| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/test/spawned_test_server/base_test_server.h" | 5 #include "net/test/spawned_test_server/base_test_server.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 #include <limits> | 8 #include <limits> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_AES128) | 78 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_AES128) |
| 79 values->AppendString("aes128"); | 79 values->AppendString("aes128"); |
| 80 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_AES256) | 80 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_AES256) |
| 81 values->AppendString("aes256"); | 81 values->AppendString("aes256"); |
| 82 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_3DES) | 82 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_3DES) |
| 83 values->AppendString("3des"); | 83 values->AppendString("3des"); |
| 84 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_AES128GCM) | 84 if (cipher & BaseTestServer::SSLOptions::BULK_CIPHER_AES128GCM) |
| 85 values->AppendString("aes128gcm"); | 85 values->AppendString("aes128gcm"); |
| 86 } | 86 } |
| 87 | 87 |
| 88 base::Value* GetTLSIntoleranceType( | 88 std::unique_ptr<base::Value> GetTLSIntoleranceType( |
| 89 BaseTestServer::SSLOptions::TLSIntoleranceType type) { | 89 BaseTestServer::SSLOptions::TLSIntoleranceType type) { |
| 90 switch (type) { | 90 switch (type) { |
| 91 case BaseTestServer::SSLOptions::TLS_INTOLERANCE_ALERT: | 91 case BaseTestServer::SSLOptions::TLS_INTOLERANCE_ALERT: |
| 92 return new base::Value("alert"); | 92 return base::MakeUnique<base::Value>("alert"); |
| 93 case BaseTestServer::SSLOptions::TLS_INTOLERANCE_CLOSE: | 93 case BaseTestServer::SSLOptions::TLS_INTOLERANCE_CLOSE: |
| 94 return new base::Value("close"); | 94 return base::MakeUnique<base::Value>("close"); |
| 95 case BaseTestServer::SSLOptions::TLS_INTOLERANCE_RESET: | 95 case BaseTestServer::SSLOptions::TLS_INTOLERANCE_RESET: |
| 96 return new base::Value("reset"); | 96 return base::MakeUnique<base::Value>("reset"); |
| 97 default: | 97 default: |
| 98 NOTREACHED(); | 98 NOTREACHED(); |
| 99 return new base::Value(""); | 99 return base::MakeUnique<base::Value>(""); |
| 100 } | 100 } |
| 101 } | 101 } |
| 102 | 102 |
| 103 bool GetLocalCertificatesDir(const base::FilePath& certificates_dir, | 103 bool GetLocalCertificatesDir(const base::FilePath& certificates_dir, |
| 104 base::FilePath* local_certificates_dir) { | 104 base::FilePath* local_certificates_dir) { |
| 105 if (certificates_dir.IsAbsolute()) { | 105 if (certificates_dir.IsAbsolute()) { |
| 106 *local_certificates_dir = certificates_dir; | 106 *local_certificates_dir = certificates_dir; |
| 107 return true; | 107 return true; |
| 108 } | 108 } |
| 109 | 109 |
| (...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 679 | 679 |
| 680 return GenerateAdditionalArguments(arguments); | 680 return GenerateAdditionalArguments(arguments); |
| 681 } | 681 } |
| 682 | 682 |
| 683 bool BaseTestServer::GenerateAdditionalArguments( | 683 bool BaseTestServer::GenerateAdditionalArguments( |
| 684 base::DictionaryValue* arguments) const { | 684 base::DictionaryValue* arguments) const { |
| 685 return true; | 685 return true; |
| 686 } | 686 } |
| 687 | 687 |
| 688 } // namespace net | 688 } // namespace net |
| OLD | NEW |