Fuzz introspector
For issues and ideas: https://github.com/ossf/fuzz-introspector/issues

Project functions overview

The following table shows data about each function in the project. The functions included in this table correspond to all functions that exist in the executables of the fuzzers. As such, there may be functions that are from third-party libraries.

For further technical details on the meaning of columns in the below table, please see the Glossary .

Func name Functions filename Args Function call depth Reached by Fuzzers Runtime reached by Fuzzers Combined reached by Fuzzers Fuzzers runtime hit Func lines hit % I Count BB Count Cyclomatic complexity Functions reached Reached by functions Accumulated cyclomatic complexity Undiscovered complexity

Analyses and suggestions

Optimal target analysis

Remaining optimal interesting functions

The following table shows a list of functions that are optimal targets. Optimal targets are identified by finding the functions that in combination, yield a high code coverage.

Func name Functions filename Arg count Args Function depth hitcount instr count bb count cyclomatic complexity Reachable functions Incoming references total cyclomatic complexity Unreached complexity
http_cancel_test /src/libevent/test/regress_http.c 1 ['void*'] 22 0 84 18 18 727 0 1904 1805
evhttp_read_cb /src/libevent/http.c 2 ['struct bufferevent*', 'void*'] 23 0 28 10 6 401 0 1284 588
thread_libevent_process /src/memcached/thread.c 3 ['evutil_socket_t', 'short', 'void*'] 23 0 60 17 20 522 0 1647 441
be_ssl_enable /src/libevent/bufferevent_ssl.c 2 ['struct bufferevent*', 'short'] 18 0 16 8 8 253 0 601 249
try_read_command_udp /src/memcached/memcached.c 1 ['conn*'] 15 0 11 2 1 395 0 1349 211
client_tcp_read_packet_cb /src/libevent/evdns.c 2 ['struct bufferevent*', 'void*'] 21 0 24 4 6 355 0 827 187
bufferevent_writecb /src/libevent/bufferevent_sock.c 3 ['evutil_socket_t', 'short', 'void*'] 20 0 84 17 28 267 0 578 158

Implementing fuzzers that target the above functions will improve reachability such that it becomes:

Functions statically reachable by fuzzers
26.0%
1123 / 4330
Cyclomatic complexity statically reachable by fuzzers
39.0%
5148 / 13241

All functions overview

If you implement fuzzers for these functions, the status of all functions in the project will be:

Func name Functions filename Args Function call depth Reached by Fuzzers Runtime reached by Fuzzers Combined reached by Fuzzers Fuzzers runtime hit Func lines hit % I Count BB Count Cyclomatic complexity Functions reached Reached by functions Accumulated cyclomatic complexity Undiscovered complexity

Fuzz driver synthesis

New fuzzers

The below fuzzers are templates and suggestions for how to target the set of optimal functions above

regress_http.c

Target file: /src/libevent/test/regress_http.c
Target functions: http_cancel_test
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target http_cancel_test */
  UNKNOWN_TYPE unknown_0;
  http_cancel_test(unknown_0);

  af_safe_gb_cleanup();
}

http.c

Target file: /src/libevent/http.c
Target functions: evhttp_read_cb
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target evhttp_read_cb */
  structbufferevent* new_var1 = calloc(sizeof(structbufferevent), 1);
  UNKNOWN_TYPE unknown_2;
  evhttp_read_cb(new_var1, unknown_2);

  af_safe_gb_cleanup();
}

thread.c

Target file: /src/memcached/thread.c
Target functions: thread_libevent_process
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target thread_libevent_process */
  UNKNOWN_TYPE unknown_3;
  UNKNOWN_TYPE unknown_4;
  UNKNOWN_TYPE unknown_5;
  thread_libevent_process(unknown_3, unknown_4, unknown_5);

  af_safe_gb_cleanup();
}

bufferevent_ssl.c

Target file: /src/libevent/bufferevent_ssl.c
Target functions: be_ssl_enable
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target be_ssl_enable */
  structbufferevent* new_var6 = calloc(sizeof(structbufferevent), 1);
  UNKNOWN_TYPE unknown_7;
  be_ssl_enable(new_var6, unknown_7);

  af_safe_gb_cleanup();
}

memcached.c

Target file: /src/memcached/memcached.c
Target functions: try_read_command_udp
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target try_read_command_udp */
  UNKNOWN_TYPE unknown_8;
  try_read_command_udp(unknown_8);

  af_safe_gb_cleanup();
}

evdns.c

Target file: /src/libevent/evdns.c
Target functions: client_tcp_read_packet_cb
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target client_tcp_read_packet_cb */
  structbufferevent* new_var9 = calloc(sizeof(structbufferevent), 1);
  UNKNOWN_TYPE unknown_10;
  client_tcp_read_packet_cb(new_var9, unknown_10);

  af_safe_gb_cleanup();
}

bufferevent_sock.c

Target file: /src/libevent/bufferevent_sock.c
Target functions: bufferevent_writecb
#include "ada_fuzz_header.h"

int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
  af_safe_gb_init(data, size);

  /* target bufferevent_writecb */
  UNKNOWN_TYPE unknown_11;
  UNKNOWN_TYPE unknown_12;
  UNKNOWN_TYPE unknown_13;
  bufferevent_writecb(unknown_11, unknown_12, unknown_13);

  af_safe_gb_cleanup();
}

Files and Directories in report

This section shows which files and directories are considered in this report. The main reason for showing this is fuzz introspector may include more code in the reasoning than is desired. This section helps identify if too many files/directories are included, e.g. third party code, which may be irrelevant for the threat model. In the event too much is included, fuzz introspector supports a configuration file that can exclude data from the report. See the following link for more information on how to create a config file: link

Files in report

Source file Reached by Covered by
/src/libevent/evutil_rand.c [] []
/src/memcached/logger.c ['fuzzer_proxy.c'] []
/src/memcached/proxy_internal.c ['fuzzer_proxy.c'] []
/src/memcached/vendor/mcmc/mcmc.h [] []
/src/libevent/include/event2/event_struct.h [] []
/src/libevent/bufferevent_pair.c [] []
/src/libevent/minheap-internal.h ['fuzzer_proxy.c'] []
/src/memcached/tls.h [] []
/src/libevent/signalfd.c [] []
/src/libevent/test/bench_http.c [] []
/src/libevent/wepoll.c [] []
/src/libevent/test/test-kq-collision.c [] []
/src/memcached/slab_automove_extstore.c [] []
/src/libevent/test/regress_watch.c [] []
/src/libevent/test/regress_openssl.c [] []
/src/libevent/include/event2/buffer_compat.h [] []
/src/memcached/slabs.c ['fuzzer_proxy.c'] []
/src/memcached/extstore.c ['fuzzer_proxy.c'] []
/src/memcached/crc32c.c [] []
/src/libevent/test/regress_main.c [] []
/src/libevent/test/regress_thread.h [] []
/src/libevent/test/regress_testutils.c [] []
/src/libevent/sample/becat.c [] []
/src/libevent/buffer_iocp.c [] []
/src/libevent/test/test-time.c [] []
/src/memcached/logger.h [] []
/src/memcached/proto_parser.h [] []
/src/memcached/testapp.c [] []
/src/memcached/proxy_tls.c [] []
/src/memcached/md5.c ['fuzzer_proxy.c'] []
/src/libevent/include/event2/event_compat.h [] []
/src/libevent/test/regress_mbedtls.c [] []
/src/memcached/storage.h [] []
/src/libevent/bufferevent_sock.c [] []
/src/libevent/evdns.c [] []
/src/libevent/bufferevent-internal.h [] []
/src/libevent/strlcpy.c [] []
/src/libevent/test/regress_ws.c [] []
/src/memcached/items.c ['fuzzer_proxy.c'] []
/src/libevent/arc4random.c [] []
/src/memcached/hash.c [] []
/src/memcached/proto_text.c ['fuzzer_proxy.c'] []
/src/libevent/test/regress_buffer.c [] []
/src/memcached/thread.c ['fuzzer_proxy.c'] []
/src/memcached/linux_priv.c [] []
/src/memcached/assoc.c ['fuzzer_proxy.c'] []
/src/memcached/storage.c ['fuzzer_proxy.c'] []
/src/libevent/test/regress_zlib.c [] []
/src/libevent/evbuffer-internal.h [] []
/src/libevent/listener.c [] []
/src/memcached/bipbuffer.c ['fuzzer_proxy.c'] []
/src/libevent/epolltable-internal.h [] []
/src/libevent/include/event2/buffer.h [] []
/src/libevent/test/regress_util.c [] []
/src/libevent/test/tinytest.c [] []
/src/memcached/restart.c [] []
/src/libevent/event_tagging.c [] []
/src/memcached/util.c ['fuzzer_proxy.c'] []
/src/libevent/ws.c [] []
/src/libevent/test/test-dumpevents.c [] []
/src/memcached/items.h [] []
/src/libevent/devpoll.c [] []
/src/memcached/proxy_mutator.c [] []
/src/libevent/sample/openssl_hostname_validation.c [] []
/src/memcached/sasl_defs.c [] []
/src/libevent/bufferevent_openssl.c [] []
/src/libevent/sha1.c [] []
/src/libevent/include/event2/rpc_compat.h [] []
/src/libevent/event_iocp.c [] []
/src/libevent/log.c ['fuzzer_proxy.c'] []
/src/libevent/signal.c [] []
/src/memcached/proxy.h [] []
/src/libevent/test/tinytest.h [] []
/src/libevent/http.c [] []
/src/libevent/include/event2/util.h [] []
/src/libevent/watch.c [] []
/src/libevent/sample/http-connect.c [] []
/src/libevent/evmap.c ['fuzzer_proxy.c'] []
/src/memcached/base64.c [] []
/src/libevent/epoll_sub.c [] []
/src/memcached/proxy_ustats.c [] []
/src/libevent/test/regress_dns.c [] []
/src/libevent/test/regress_http.c [] []
/src/memcached/proxy_ring_hash.c ['fuzzer_proxy.c'] []
/src/memcached/proto_proxy.c ['fuzzer_proxy.c'] []
/src/libevent/evthread.c [] []
/src/libevent/bufferevent_ratelim.c [] []
/src/memcached/stats_prefix.c ['fuzzer_proxy.c'] []
/src/libevent/poll.c [] []
/src/libevent/test/regress_rpc.c [] []
/src/memcached/proto_parser.c ['fuzzer_proxy.c'] []
/src/libevent/compat/sys/queue.h [] []
/src/memcached/proxy_request.c ['fuzzer_proxy.c'] []
/src/libevent/bufferevent_ssl.c [] []
/src/memcached/slab_automove.c [] []
/src/libevent/test/regress_ssl.c [] []
/src/memcached/proxy_luafgen.c ['fuzzer_proxy.c'] []
/src/libevent/include/event2/bufferevent_compat.h [] []
/src/libevent/include/event2/event.h [] []
/src/libevent/test/test-fdleak.c [] []
/src/libevent/test/regress_minheap.c [] []
/src/libevent/evthread_win32.c [] []
/src/libevent/evutil.c ['fuzzer_proxy.c'] []
/src/memcached/proxy_ratelim.c [] []
/src/libevent/ht-internal.h [] []
/src/libevent/bufferevent.c [] []
/src/memcached/jenkins_hash.c [] []
/src/libevent/include/event2/keyvalq_struct.h [] []
/src/memcached/memcached.h [] []
/src/libevent/util-internal.h [] []
/src/libevent/sample/hostcheck.c [] []
/src/libevent/sample/https-client.c [] []
/src/libevent/test/regress_thread.c [] []
/src/libevent/test/regress_bufferevent.c [] []
/src/libevent/evport.c [] []
/src/libevent/bufferevent_async.c [] []
/src/libevent/select.c [] []
/src/libevent/test/bench_cascade.c [] []
/src/libevent/test/tinytest_macros.h [] []
/src/libevent/test/tinytest_demo.c [] []
/src/libevent/sample/http-server.c [] []
/src/memcached/vendor/mcmc/example.c [] []
/src/memcached/proxy_inspector.c [] []
/src/memcached/proxy_lua.c ['fuzzer_proxy.c'] []
/src/memcached/slabs_mover.c ['fuzzer_proxy.c'] []
/src/libevent/WIN32-Code/getopt_long.c [] []
/src/memcached/proxy_xxhash.c [] []
/src/memcached/memcached.c ['fuzzer_proxy.c'] []
/src/libevent/event-internal.h [] []
/src/libevent/sample/le-proxy.c [] []
/src/libevent/log-internal.h [] []
/src/libevent/WIN32-Code/tree.h [] []
/src/memcached/xxhash.h [] []
/src/libevent/openssl-compat.h [] []
/src/memcached/queue.h [] []
/src/libevent/test/regress.c [] []
/src/libevent/sample/watch-timing.c [] []
/src/memcached/itoa_ljust.c ['fuzzer_proxy.c'] []
/src/libevent/sample/ssl-client-mbedtls.c [] []
/src/libevent/buffer.c [] []
/src/memcached/authfile.c [] []
/src/memcached/proxy_jump_hash.c [] []
/src/memcached/timedrun.c [] []
/src/libevent/test/regress_iocp.c [] []
/src/libevent/sample/time-test.c [] []
/src/libevent/win32select.c [] []
/src/libevent/test/bench_httpclient.c [] []
/src/libevent/include/event2/tag_compat.h [] []
/src/memcached/sizes.c [] []
/src/memcached/cache.c ['fuzzer_proxy.c'] []
/src/memcached/vendor/mcmc/mcmc.c ['fuzzer_proxy.c'] []
/src/libevent/evthread_pthread.c [] []
/src/memcached/daemon.c [] []
/src/libevent/test/test-changelist.c [] []
/src/memcached/proxy_config.c [] []
/src/libevent/test/regress_listener.c [] []
/src/libevent/test/regress_finalize.c [] []
/src/libevent/sample/hello-world.c [] []
/src/libevent/include/event2/rpc.h [] []
/src/libevent/test/test-closed.c [] []
/src/libevent/bufferevent_mbedtls.c [] []
/src/libevent/evrpc.c [] []
/src/memcached/murmur3_hash.c [] []
/src/libevent/test/regress.h [] []
/src/libevent/evutil_time.c [] []
/src/libevent/epoll.c [] []
/src/memcached/proxy_network.c [] []
/src/libevent/test/test-ratelim.c [] []
/src/libevent/kqueue.c [] []
/src/libevent/sample/dns-example.c [] []
/src/libevent/test/regress_et.c [] []
/src/libevent/evthread-internal.h [] []
/src/memcached/sasl_defs.h [] []
/src/memcached/proxy_result.c ['fuzzer_proxy.c'] []
/src/libevent/event.c ['fuzzer_proxy.c'] []
/src/fuzzer_proxy.c ['fuzzer_proxy.c'] []
/src/memcached/crawler.c [] []
/src/libevent/sample/event-read-fifo.c [] []
/src/libevent/test/print-winsock-errors.c [] []
/src/libevent/bufferevent_filter.c [] []
/src/memcached/tls.c [] []
/src/libevent/test-export/test-export.c [] []
/src/memcached/trace.h [] []
/src/libevent/test/regress_timer_timeout.c [] []
/src/libevent/sample/ws-chat-server.c [] []
/src/memcached/proto_bin.c ['fuzzer_proxy.c'] []
/src/memcached/openbsd_priv.c [] []
/src/libevent/mm-internal.h [] []
/src/libevent/ratelim-internal.h [] []

Directories in report

Directory
/src/libevent/test-export/
/src/libevent/test/
/src/memcached/
/src/libevent/
/src/
/src/libevent/compat/sys/
/src/memcached/vendor/mcmc/
/src/libevent/include/event2/
/src/libevent/WIN32-Code/
/src/libevent/sample/