aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/extra_tests/fuzzers/jigs/tls_client.cpp17
-rw-r--r--src/extra_tests/fuzzers/jigs/tls_server.cpp13
2 files changed, 3 insertions, 27 deletions
diff --git a/src/extra_tests/fuzzers/jigs/tls_client.cpp b/src/extra_tests/fuzzers/jigs/tls_client.cpp
index f70e1eb75..d3fbd069c 100644
--- a/src/extra_tests/fuzzers/jigs/tls_client.cpp
+++ b/src/extra_tests/fuzzers/jigs/tls_client.cpp
@@ -32,7 +32,6 @@ void fuzz(const uint8_t in[], size_t len)
TLS::Policy policy;
TLS::Protocol_Version client_offer = TLS::Protocol_Version::TLS_V12;
TLS::Server_Information info("server.name", 443);
- const std::vector<std::string> protocols_to_offer = { "fuzz/1.0", "http/1.1", "bunny/1.21.3" };
Fuzzer_TLS_Client_Creds creds;
TLS::Client client(dev_null,
@@ -44,23 +43,11 @@ void fuzz(const uint8_t in[], size_t len)
policy,
fuzzer_rng(),
info,
- client_offer,
- protocols_to_offer);
+ client_offer);
try
{
- while(len > 0)
- {
- const size_t write_len = in[0];
- const size_t left = len - 1;
-
- const size_t consumed = std::min(left, write_len);
-
- client.received_data(in + 1, consumed);
-
- in += consumed + 1;
- len -= consumed + 1;
- }
+ client.received_data(in, len);
}
catch(std::exception& e)
{
diff --git a/src/extra_tests/fuzzers/jigs/tls_server.cpp b/src/extra_tests/fuzzers/jigs/tls_server.cpp
index acf7ce08e..a4e0d5f00 100644
--- a/src/extra_tests/fuzzers/jigs/tls_server.cpp
+++ b/src/extra_tests/fuzzers/jigs/tls_server.cpp
@@ -145,18 +145,7 @@ void fuzz(const uint8_t in[], size_t len)
try
{
- while(len > 0)
- {
- const size_t write_len = in[0];
- const size_t left = len - 1;
-
- const size_t consumed = std::min(left, write_len);
-
- server.received_data(in + 1, consumed);
-
- in += consumed + 1;
- len -= consumed + 1;
- }
+ server.received_data(in, len);
}
catch(std::exception& e)
{