From f5ab3e4c5cd37b76d60f657190b315183dbefeba Mon Sep 17 00:00:00 2001 From: Fedor Indutny Date: Fri, 6 Dec 2013 14:30:13 +0400 Subject: [PATCH] benchmark: fixate `ciphers` in tls benchmarks Benchmark should always use the same cipher in order to be truthful. --- benchmark/tls/throughput.js | 3 ++- benchmark/tls/tls-connect.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/benchmark/tls/throughput.js b/benchmark/tls/throughput.js index 88118af..442eba3 100644 --- a/benchmark/tls/throughput.js +++ b/benchmark/tls/throughput.js @@ -39,7 +39,8 @@ function main(conf) { options = { key: fs.readFileSync(cert_dir + '/test_key.pem'), cert: fs.readFileSync(cert_dir + '/test_cert.pem'), - ca: [ fs.readFileSync(cert_dir + '/test_ca.pem') ] }; + ca: [ fs.readFileSync(cert_dir + '/test_ca.pem') ], + ciphers: 'AES256-GCM-SHA384' }; server = tls.createServer(options, onConnection); setTimeout(done, dur * 1000); diff --git a/benchmark/tls/tls-connect.js b/benchmark/tls/tls-connect.js index 0da448e..96c9c5a 100644 --- a/benchmark/tls/tls-connect.js +++ b/benchmark/tls/tls-connect.js @@ -23,7 +23,8 @@ function main(conf) { var cert_dir = path.resolve(__dirname, '../../test/fixtures'), options = { key: fs.readFileSync(cert_dir + '/test_key.pem'), cert: fs.readFileSync(cert_dir + '/test_cert.pem'), - ca: [ fs.readFileSync(cert_dir + '/test_ca.pem') ] }; + ca: [ fs.readFileSync(cert_dir + '/test_ca.pem') ], + ciphers: 'AES256-GCM-SHA384' }; server = tls.createServer(options, onConnection); server.listen(common.PORT, onListening); -- 2.7.4