Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(936)

Unified Diff: net/test/test_server.cc

Issue 6804032: Add TLS-SRP (RFC 5054) support Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: remove "httpsv" scheme, minor NSS/OpenSSL changes Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/test/test_server.h ('k') | net/third_party/nss/README.chromium » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/test/test_server.cc
diff --git a/net/test/test_server.cc b/net/test/test_server.cc
index 8f5f3d2618200cecfd11a4e62e7a8b056b7acd2f..9da02898664accb9eab1021830187ffa27017b34 100644
--- a/net/test/test_server.cc
+++ b/net/test/test_server.cc
@@ -62,13 +62,15 @@ std::string GetHostname(TestServer::Type type,
TestServer::HTTPSOptions::HTTPSOptions()
: server_certificate(CERT_OK),
request_client_certificate(false),
- bulk_ciphers(HTTPSOptions::BULK_CIPHER_ANY) {}
+ bulk_ciphers(HTTPSOptions::BULK_CIPHER_ANY),
+ use_tls_srp(0), only_tls_srp(0) {}
TestServer::HTTPSOptions::HTTPSOptions(
TestServer::HTTPSOptions::ServerCertificate cert)
: server_certificate(cert),
request_client_certificate(false),
- bulk_ciphers(HTTPSOptions::BULK_CIPHER_ANY) {}
+ bulk_ciphers(HTTPSOptions::BULK_CIPHER_ANY),
+ use_tls_srp(0), only_tls_srp(0) {}
TestServer::HTTPSOptions::~HTTPSOptions() {}
@@ -107,8 +109,10 @@ TestServer::~TestServer() {
bool TestServer::Start() {
if (type_ == TYPE_HTTPS) {
- if (!LoadTestRootCert())
+ if (!LoadTestRootCert()) {
+ LOG(ERROR) << "Failed to load test root cert";
return false;
+ }
}
// Get path to python server script
@@ -123,14 +127,19 @@ bool TestServer::Start() {
.Append(FILE_PATH_LITERAL("testserver"))
.Append(FILE_PATH_LITERAL("testserver.py"));
- if (!SetPythonPath())
+ if (!SetPythonPath()) {
+ LOG(ERROR) << "Failed to set Python path";
return false;
+ }
- if (!LaunchPython(testserver_path))
+ if (!LaunchPython(testserver_path)) {
+ LOG(ERROR) << "Failed to launch Python test server";
return false;
+ }
if (!WaitToStart()) {
Stop();
+ LOG(ERROR) << "Failed in WaitToStart()";
return false;
}
@@ -392,6 +401,11 @@ bool TestServer::AddCommandLineArguments(CommandLine* command_line) const {
command_line->AppendSwitchASCII(kBulkCipherSwitch, "aes256");
if (https_options_.bulk_ciphers & HTTPSOptions::BULK_CIPHER_3DES)
command_line->AppendSwitchASCII(kBulkCipherSwitch, "3des");
+
+ if (https_options_.use_tls_srp)
+ command_line->AppendSwitch("use-tls-srp");
+ if (https_options_.only_tls_srp)
+ command_line->AppendSwitch("only-tls-srp");
}
return true;
« no previous file with comments | « net/test/test_server.h ('k') | net/third_party/nss/README.chromium » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698