diff options
author | Håvard Pettersen <havardpe@oath.com> | 2019-01-17 13:58:49 +0000 |
---|---|---|
committer | Håvard Pettersen <havardpe@oath.com> | 2019-01-25 12:36:05 +0000 |
commit | 2ec8f7e3540b5dd4a5521b2f92c47de64ed01869 (patch) | |
tree | ea6d69d65ea79c2cc23c1f29cf91f8890a62dcc4 /vbench/src/vbench/http/http_client.h | |
parent | 02d24b5d24d8c3c3e97dbca86357881a5282601c (diff) |
TLS support in vbench
- vbench/dumpurl applications explicitly run without encryption for
now (config file/command line options should be added).
- configstatus tool uses default encryption which will pick up local
settings via environment where applicable.
Diffstat (limited to 'vbench/src/vbench/http/http_client.h')
-rw-r--r-- | vbench/src/vbench/http/http_client.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/vbench/src/vbench/http/http_client.h b/vbench/src/vbench/http/http_client.h index f2ee5dcbd0d..77a53057740 100644 --- a/vbench/src/vbench/http/http_client.h +++ b/vbench/src/vbench/http/http_client.h @@ -56,22 +56,22 @@ private: bool readChunkSize(bool first, size_t &size); bool skipTrailers(); bool readContent(); - bool perform(); + bool perform(CryptoEngine &crypto); public: ~HttpClient(); - static bool fetch(const ServerSpec &server, const string &url, + static bool fetch(CryptoEngine &crypto, const ServerSpec &server, const string &url, HttpResultHandler &handler) { - HttpClient client(HttpConnection::UP(new HttpConnection(server)), url, handler); - return client.perform(); + HttpClient client(HttpConnection::UP(new HttpConnection(crypto, server)), url, handler); + return client.perform(crypto); } static bool fetch(HttpConnectionPool &pool, const ServerSpec &server, const string &url, HttpResultHandler &handler) { HttpClient client(pool.getConnection(server), url, handler); - if (client.perform()) { + if (client.perform(pool.crypto())) { if (client.serverKeepAlive()) { pool.putConnection(std::move(client._conn)); } |