MCPcopy Create free account
hub / github.com/boostorg/beast / LLVMFuzzerTestOneInput

Function LLVMFuzzerTestOneInput

test/fuzz/http_request.cpp:11–25  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9#include <boost/beast/_experimental/test/stream.hpp>
10
11extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size)
12{
13 using namespace boost::beast;
14
15 error_code ec;
16 flat_buffer buffer;
17 net::io_context ioc;
18 test::stream stream{ioc, {reinterpret_cast<const char*>(data), size}};
19 stream.close_remote();
20
21 http::request_parser<http::dynamic_body> parser;
22 http::read(stream, buffer, parser, ec);
23
24 return 0;
25}

Callers

nothing calls this directly

Calls 1

readFunction · 0.50

Tested by

no test coverage detected