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

Fuzzer details

Fuzzer: fuzz_services

Call tree

The calltree shows the control flow of the fuzzer. This is overlaid with coverage information to display how much of the potential code a fuzzer can reach is in fact covered at runtime. In the following there is a link to a detailed calltree visualisation as well as a bitmap showing a high-level view of the calltree. For further information about these topics please see the glossary for full calltree and calltree overview

Call tree overview bitmap:

The distribution of callsites in terms of coloring is
Color Runtime hitcount Callsite count Percentage
red 0 9 30.0%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 21 70.0%
All colors 30 100

Fuzz blockers

The following nodes represent call sites where fuzz blockers occur.

Amount of callsites blocked Calltree index Parent function Callsite Largest blocked function
5 9 parse_services call site: 00009 __errno_location
3 15 parse_services call site: 00015 fprintf
1 4 fuzz_write_tempfile call site: 00004 unlink

Runtime coverage analysis

Covered functions
3
Functions that are reachable but not covered
19
Reachable functions
22
Percentage of reachable functions covered
13.64%
NB: The sum of covered functions and functions that are reachable but not covered need not be equal to Reachable functions . This is because the reachability analysis is an approximation and thus at runtime some functions may be covered that are not included in the reachability analysis. This is a limitation of our static analysis capabilities.
Function name source code lines source lines hit percentage hit

Files reached

filename functions hit
tcpreplay/test/fuzz/fuzz_services.c 1
tcpreplay/test/fuzz/fuzz_common.h 1
tcpreplaycommon/services.c 1

Fuzzer: fuzz_fragroute

Call tree

The calltree shows the control flow of the fuzzer. This is overlaid with coverage information to display how much of the potential code a fuzzer can reach is in fact covered at runtime. In the following there is a link to a detailed calltree visualisation as well as a bitmap showing a high-level view of the calltree. For further information about these topics please see the glossary for full calltree and calltree overview

Call tree overview bitmap:

The distribution of callsites in terms of coloring is
Color Runtime hitcount Callsite count Percentage
red 0 140 100.%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 0 0.0%
All colors 140 100

Fuzz blockers

The following nodes represent call sites where fuzz blockers occur.

Amount of callsites blocked Calltree index Parent function Callsite Largest blocked function
139 0 EP call site: 00000 fragroute_process

Runtime coverage analysis

Covered functions
0
Functions that are reachable but not covered
48
Reachable functions
48
Percentage of reachable functions covered
0.0%
NB: The sum of covered functions and functions that are reachable but not covered need not be equal to Reachable functions . This is because the reachability analysis is an approximation and thus at runtime some functions may be covered that are not included in the reachability analysis. This is a limitation of our static analysis capabilities.
Function name source code lines source lines hit percentage hit

Files reached

filename functions hit
tcpreplay/test/fuzz/fuzz_fragroute.c 1
tcpreplay/test/fuzz/fuzz_common.h 2
tcpreplayfragroute/fragroute.c 4
tcpreplaycommon/utils.c 1
tcpreplayfragroute/pkt.c 4
tcpreplayfragroute/bget.c 4
tcpreplayfragroute/mod.c 2
tcpreplayfragroute/argv.c 1
tcpreplaycommon/get.c 5
libpcap/pcap.c 1

Fuzzer: fuzz_pcap

Call tree

The calltree shows the control flow of the fuzzer. This is overlaid with coverage information to display how much of the potential code a fuzzer can reach is in fact covered at runtime. In the following there is a link to a detailed calltree visualisation as well as a bitmap showing a high-level view of the calltree. For further information about these topics please see the glossary for full calltree and calltree overview

Call tree overview bitmap:

The distribution of callsites in terms of coloring is
Color Runtime hitcount Callsite count Percentage
red 0 28 25.4%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 1 0.90%
lawngreen 50+ 81 73.6%
All colors 110 100

Fuzz blockers

The following nodes represent call sites where fuzz blockers occur.

Amount of callsites blocked Calltree index Parent function Callsite Largest blocked function
10 5 pcap_fopen_offline_with_tstamp_precision call site: 00005 pcapint_fmt_errmsg_for_errno
8 22 pcapint_offline_read call site: 00022 pcapint_filter_with_aux_data
4 87 get_l2len_protocol call site: 00087 pcap_datalink_val_to_description
3 55 parse_metadata call site: 00055 fprintf
2 35 get_l2len_protocol call site: 00035 fprintf
1 3 pcap_fopen_offline call site: 00003 snprintf

Runtime coverage analysis

Covered functions
47
Functions that are reachable but not covered
24
Reachable functions
42
Percentage of reachable functions covered
42.86%
NB: The sum of covered functions and functions that are reachable but not covered need not be equal to Reachable functions . This is because the reachability analysis is an approximation and thus at runtime some functions may be covered that are not included in the reachability analysis. This is a limitation of our static analysis capabilities.
Warning: The number of covered functions are larger than the number of reachable functions. This means that there are more functions covered at runtime than are extracted using static analysis. This is likely a result of the static analysis component failing to extract the right call graph or the coverage runtime being compiled with sanitizers in code that the static analysis has not analysed. This can happen if lto/gold is not used in all places that coverage instrumentation is used.
Function name source code lines source lines hit percentage hit

Files reached

filename functions hit
tcpreplay/test/fuzz/fuzz_pcap.c 1
libpcap/savefile.c 3
libpcap/fmtutils.c 2
libpcap/pcap.c 5
libpcap/bpf_filter.c 2
libpcap/extract.h 2
tcpreplaycommon/get.c 9

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
pcap_compile_nopcap /src/libpcap/gencode.c 6 ['int', 'int', 'N/A', 'N/A', 'int', 'int'] 18 0 54 6 3 344 0 2358 2309
pcap_activate_linux /src/libpcap/pcap-linux.c 1 ['N/A'] 8 0 343 45 15 56 0 293 261
pcap_ng_next_packet /src/libpcap/sf-pcapng.c 3 ['N/A', 'N/A', 'N/A'] 6 0 992 70 19 37 0 213 186
pcap_lookupdev /src/libpcap/pcap.c 1 ['N/A'] 9 0 74 14 6 41 0 185 137
pcap_read_linux_mmap_v3 /src/libpcap/pcap-linux.c 4 ['N/A', 'int', 'N/A', 'N/A'] 6 0 522 77 28 27 0 166 92
pcap_open_live /src/libpcap/pcap.c 5 ['N/A', 'int', 'int', 'int', 'N/A'] 8 0 183 29 12 30 0 136 90
print_apply /src/tcpreplay/src/fragroute/mod_print.c 2 ['N/A', 'N/A'] 3 0 142 19 7 22 0 96 86
netfilter_activate /src/libpcap/pcap-netfilter-linux.c 1 ['N/A'] 5 0 598 89 35 28 0 119 78
pcap_setfilter_linux /src/libpcap/pcap-linux.c 2 ['N/A', 'N/A'] 5 0 344 65 21 22 0 105 74
ip_frag_apply /src/tcpreplay/src/fragroute/mod_ip_frag.c 2 ['N/A', 'N/A'] 5 0 69 12 5 13 0 96 63

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

Functions statically reachable by fuzzers
68.0%
474 / 695
Cyclomatic complexity statically reachable by fuzzers
77.0%
3527 / 4587

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

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/libpcap/pcap-linux.c [] []
/src/tcpreplay/src/fragroute/mod_order.c [] []
/src/libpcap/build/scanner.c [] []
/src/tcpreplay/src/fragroute/mod_tcp_opt.c [] []
/src/tcpreplay/test/fuzz/fuzz_pcap.c ['fuzz_pcap'] ['fuzz_pcap']
/src/libpcap/optimize.c [] []
/src/tcpreplay/src/fragroute/mod_delay.c [] []
/src/tcpreplay/test/fuzz/fuzz_services.c ['fuzz_services'] ['fuzz_services']
/src/libpcap/sf-pcapng.c [] []
/src/tcpreplay/src/fragroute/pkt.c ['fuzz_fragroute'] []
/src/libpcap/sf-pcap.c [] []
/src/libpcap/gencode.c [] []
/src/tcpreplay/src/fragroute/mod_ip_chaff.c [] []
/src/tcpreplay/src/fragroute/mod_ip_frag.c [] []
/src/tcpreplay/src/fragroute/mod_drop.c [] []
/src/tcpreplay/src/fragroute/bget.c ['fuzz_fragroute'] []
/src/libpcap/pcap.c ['fuzz_fragroute', 'fuzz_pcap'] ['fuzz_pcap']
/src/libpcap/pcap-usb-linux-common.h [] []
/src/tcpreplay/src/fragroute/mod_echo.c [] []
/src/libpcap/build/grammar.y [] []
/src/libpcap/fmtutils.c ['fuzz_pcap'] []
/src/libpcap/fad-getad.c [] []
/src/tcpreplay/src/fragroute/fragroute.c ['fuzz_fragroute'] []
/src/tcpreplay/src/common/services.c ['fuzz_services'] ['fuzz_services']
/src/libpcap/pcap-netfilter-linux.c [] []
/src/tcpreplay/src/fragroute/mod_ip_tos.c [] []
/src/libpcap/scanner.l [] []
/src/libpcap/extract.h ['fuzz_pcap'] ['fuzz_pcap']
/src/libpcap/bpf_filter.c ['fuzz_pcap'] []
/src/tcpreplay/src/fragroute/randutil.c [] []
/src/libpcap/pcap-util.c [] []
/src/libpcap/missing/strlcpy.c [] []
/src/tcpreplay/src/fragroute/mod_ip6_opt.c [] []
/src/libpcap/savefile.c ['fuzz_pcap'] ['fuzz_pcap']
/src/tcpreplay/src/fragroute/mod_tcp_seg.c [] []
/src/tcpreplay/src/fragroute/iputil.c [] []
/src/libpcap/build/grammar.c [] []
/src/tcpreplay/src/fragroute/mod_ip_opt.c [] []
/src/tcpreplay/test/fuzz/fuzz_fragroute.c ['fuzz_fragroute'] []
/src/tcpreplay/src/fragroute/argv.c ['fuzz_fragroute'] []
/src/tcpreplay/src/fragroute/mod_tcp_chaff.c [] []
/src/libpcap/nametoaddr.c [] []
/src/tcpreplay/src/common/utils.c ['fuzz_fragroute'] []
/src/tcpreplay/src/fragroute/mod_ip_ttl.c [] []
/src/tcpreplay/src/fragroute/mod.c ['fuzz_fragroute'] []
/src/libpcap/pcap-common.c [] []
/src/tcpreplay/test/fuzz/fuzz_common.h ['fuzz_services', 'fuzz_fragroute'] ['fuzz_services']
/src/tcpreplay/src/fragroute/mod_print.c [] []
/src/tcpreplay/src/common/get.c ['fuzz_fragroute', 'fuzz_pcap'] ['fuzz_pcap']
/src/tcpreplay/src/fragroute/mod_ip6_qos.c [] []
/src/libpcap/pcap-util.h [] []
/src/tcpreplay/src/fragroute/mod_dup.c [] []

Directories in report

Directory
/src/libpcap/build/
/src/tcpreplay/src/fragroute/
/src/tcpreplay/src/common/
/src/libpcap/
/src/tcpreplay/test/fuzz/
/src/libpcap/missing/