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: /src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc

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 115 75.1%
gold [1:9] 9 5.88%
yellow [10:29] 5 3.26%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 24 15.6%
All colors 153 100

Fuzz blockers

The followings are the branches where fuzzer fails to bypass.

Unique non-covered Complexity Unique Reachable Complexities Unique Reachable Functions All non-covered Complexity All Reachable Complexity Function Name Function Callsite Blocked Branch
94 94 1 :

['proc_write10_host_data']

255 255 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
22 22 4 :

['tud_msc_write10_complete_cb', 'prepare_cbw', 'tud_msc_read10_complete_cb', 'tud_msc_scsi_complete_cb']

50 50 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
4 4 1 :

['invoke_class_control']

4 4 process_control_request call site: 00034 /src/tinyusb/src/device/usbd.c:774
0 0 None 314 342 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:422
0 0 None 28 28 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
0 0 None 0 80 dcd_int_handler call site: 00009 /src/tinyusb/test/fuzz/dcd_fuzz.cc:58
0 0 None 0 41 usbd_control_xfer_cb call site: 00088 /src/tinyusb/src/device/usbd_control.c:156
0 0 None 0 41 usbd_control_xfer_cb call site: 00089 /src/tinyusb/src/device/usbd_control.c:170
0 0 1 :

['std::__1::vector >::resize(unsigned long)']

0 40 dcd_int_handler call site: 00010 /src/tinyusb/test/fuzz/dcd_fuzz.cc:81
0 0 None 0 14 dcd_event_handler call site: 00011 /src/tinyusb/src/device/usbd.c:1205
0 0 None 0 14 dcd_event_handler call site: 00011 /src/tinyusb/src/device/usbd.c:1219
0 0 None 0 14 data_stage_xact call site: 00041 /src/tinyusb/src/device/usbd_control.c:94

Runtime coverage analysis

Covered functions
54
Functions that are reachable but not covered
57
Reachable functions
89
Percentage of reachable functions covered
35.96%
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
/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc 2
/src/tinyusb/test/fuzz/fuzz.cc 1
/src/tinyusb/src/device/usbd.c 24
/src/tinyusb/src/common/tusb_fifo.c 18
/src/tinyusb/test/fuzz/dcd_fuzz.cc 9
/src/tinyusb/src/device/usbd_control.c 9
/src/tinyusb/test/fuzz/usbd_fuzz.cc 4
/src/tinyusb/test/fuzz/device/cdc/src/usb_descriptors.cc 3
/src/tinyusb/src/tusb.c 3
/src/tinyusb/src/class/cdc/cdc_device.c 13

Fuzzer: /src/tinyusb/test/fuzz/device/msc/src/fuzz.cc

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 57 58.7%
gold [1:9] 10 10.3%
yellow [10:29] 5 5.15%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 25 25.7%
All colors 97 100

Fuzz blockers

The followings are the branches where fuzzer fails to bypass.

Unique non-covered Complexity Unique Reachable Complexities Unique Reachable Functions All non-covered Complexity All Reachable Complexity Function Name Function Callsite Blocked Branch
94 94 1 :

['proc_write10_host_data']

255 255 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
22 22 4 :

['tud_msc_write10_complete_cb', 'prepare_cbw', 'tud_msc_read10_complete_cb', 'tud_msc_scsi_complete_cb']

50 50 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
4 4 1 :

['invoke_class_control']

4 4 process_control_request call site: 00034 /src/tinyusb/src/device/usbd.c:774
0 0 None 314 342 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:422
0 0 None 28 28 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
0 0 None 0 80 dcd_int_handler call site: 00009 /src/tinyusb/test/fuzz/dcd_fuzz.cc:58
0 0 None 0 41 usbd_control_xfer_cb call site: 00088 /src/tinyusb/src/device/usbd_control.c:156
0 0 None 0 41 usbd_control_xfer_cb call site: 00089 /src/tinyusb/src/device/usbd_control.c:170
0 0 1 :

['std::__1::vector >::resize(unsigned long)']

0 40 dcd_int_handler call site: 00010 /src/tinyusb/test/fuzz/dcd_fuzz.cc:81
0 0 None 0 14 dcd_event_handler call site: 00011 /src/tinyusb/src/device/usbd.c:1205
0 0 None 0 14 dcd_event_handler call site: 00011 /src/tinyusb/src/device/usbd.c:1219
0 0 None 0 14 data_stage_xact call site: 00041 /src/tinyusb/src/device/usbd_control.c:94

Runtime coverage analysis

Covered functions
54
Functions that are reachable but not covered
27
Reachable functions
59
Percentage of reachable functions covered
54.24%
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
/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc 1
/src/tinyusb/test/fuzz/fuzz.cc 1
/src/tinyusb/src/device/usbd.c 20
/src/tinyusb/src/common/tusb_fifo.c 8
/src/tinyusb/test/fuzz/dcd_fuzz.cc 9
/src/tinyusb/src/device/usbd_control.c 9
/src/tinyusb/test/fuzz/usbd_fuzz.cc 4
/src/tinyusb/test/fuzz/device/msc/src/usb_descriptors.cc 3
/src/tinyusb/src/tusb.c 1

Fuzzer: /src/tinyusb/test/fuzz/device/net/src/fuzz.cc

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 70 65.4%
gold [1:9] 8 7.47%
yellow [10:29] 5 4.67%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 24 22.4%
All colors 107 100

Fuzz blockers

The followings are the branches where fuzzer fails to bypass.

Unique non-covered Complexity Unique Reachable Complexities Unique Reachable Functions All non-covered Complexity All Reachable Complexity Function Name Function Callsite Blocked Branch
94 94 1 :

['proc_write10_host_data']

255 255 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
22 22 4 :

['tud_msc_write10_complete_cb', 'prepare_cbw', 'tud_msc_read10_complete_cb', 'tud_msc_scsi_complete_cb']

50 50 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
4 4 1 :

['invoke_class_control']

4 4 process_control_request call site: 00034 /src/tinyusb/src/device/usbd.c:774
0 0 None 314 342 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:422
0 0 None 28 28 mscd_xfer_cb call site: 00000 /src/tinyusb/src/class/msc/msc_device.c:418
0 0 None 0 80 dcd_int_handler call site: 00009 /src/tinyusb/test/fuzz/dcd_fuzz.cc:58
0 0 None 0 41 usbd_control_xfer_cb call site: 00088 /src/tinyusb/src/device/usbd_control.c:156
0 0 None 0 41 usbd_control_xfer_cb call site: 00089 /src/tinyusb/src/device/usbd_control.c:170
0 0 1 :

['std::__1::vector >::resize(unsigned long)']

0 40 dcd_int_handler call site: 00010 /src/tinyusb/test/fuzz/dcd_fuzz.cc:81
0 0 None 0 14 dcd_event_handler call site: 00011 /src/tinyusb/src/device/usbd.c:1205
0 0 None 0 14 dcd_event_handler call site: 00011 /src/tinyusb/src/device/usbd.c:1219
0 0 None 0 14 data_stage_xact call site: 00041 /src/tinyusb/src/device/usbd_control.c:94

Runtime coverage analysis

Covered functions
54
Functions that are reachable but not covered
33
Reachable functions
65
Percentage of reachable functions covered
49.23%
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
/src/tinyusb/test/fuzz/device/net/src/fuzz.cc 2
/src/tinyusb/test/fuzz/fuzz.cc 1
/src/tinyusb/src/device/usbd.c 20
/src/tinyusb/src/common/tusb_fifo.c 8
/src/tinyusb/test/fuzz/dcd_fuzz.cc 9
/src/tinyusb/src/device/usbd_control.c 9
/src/tinyusb/test/fuzz/usbd_fuzz.cc 4
/src/tinyusb/test/fuzz/device/net/src/usb_descriptors.cc 3
/src/tinyusb/src/tusb.c 1
/src/tinyusb/src/class/net/ecm_rndis_device.c 4
/src/tinyusb/test/fuzz/net_fuzz.cc 1

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
netif_input /src/tinyusb/lib/lwip/src/core/netif.c 2 ['N/A', 'N/A'] 11 0 30 6 3 133 0 1139 1139
httpd_init_pcb /src/tinyusb/lib/lwip/src/apps/http/httpd.c 1 ['N/A'] 22 0 29 6 3 125 1 781 258
mscd_xfer_cb /src/tinyusb/src/class/msc/msc_device.c 4 ['char', 'char', 'int', 'int'] 6 0 425 98 37 41 0 245 181
netd_control_xfer_cb /src/tinyusb/src/class/net/ecm_rndis_device.c 3 ['char', 'char', 'N/A'] 7 0 278 63 24 21 0 161 119
dhserv_init /src/tinyusb/lib/networking/dhserver.c 1 ['N/A'] 9 0 42 8 4 49 0 272 95
netif_add_noaddr /src/tinyusb/lib/lwip/src/core/netif.c 4 ['N/A', 'N/A', 'N/A', 'N/A'] 18 0 16 3 2 68 0 363 60
etharp_output /src/tinyusb/lib/lwip/src/core/ipv4/etharp.c 3 ['N/A', 'N/A', 'N/A'] 9 0 169 29 12 32 0 209 42
cdcd_xfer_cb /src/tinyusb/src/class/cdc/cdc_device.c 4 ['char', 'char', 'int', 'int'] 5 0 235 58 25 25 0 120 35

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

Functions statically reachable by fuzzers
65.0%
333 / 511
Cyclomatic complexity statically reachable by fuzzers
75.0%
2355 / 3142

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/tinyusb/lib/lwip/src/core/netif.c [] []
/src/tinyusb/lib/networking/dhserver.c [] []
/src/tinyusb/test/fuzz/net_fuzz.cc ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] []
/src/tinyusb/lib/lwip/src/core/udp.c [] []
/src/tinyusb/test/fuzz/fuzz.cc ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/lib/lwip/src/netif/ethernet.c [] []
/src/tinyusb/lib/lwip/src/core/def.c [] []
/src/tinyusb/lib/lwip/src/core/ipv4/ip4_addr.c [] []
/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc ['/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc']
/src/tinyusb/lib/lwip/src/core/ipv4/ip4_frag.c [] []
/src/tinyusb/lib/networking/dnserver.c [] []
/src/tinyusb/lib/lwip/src/apps/http/fs.c [] []
/src/tinyusb/lib/lwip/src/core/memp.c [] []
/src/tinyusb/lib/lwip/src/netif/slipif.c [] []
/src/tinyusb/lib/lwip/src/core/init.c [] []
/src/tinyusb/src/class/net/ecm_rndis_device.c ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] []
/usr/include/stdlib.h [] []
/src/tinyusb/lib/lwip/src/core/inet_chksum.c [] []
/src/tinyusb/src/device/usbd.c ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/src/class/cdc/cdc_device.c ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc'] []
/src/tinyusb/test/fuzz/device/net/src/usb_descriptors.cc ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] []
/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc']
/usr/local/bin/../include/c++/v1/optional [] []
/src/tinyusb/lib/lwip/src/core/ipv4/icmp.c [] []
/src/tinyusb/lib/lwip/src/core/tcp_out.c [] []
/src/tinyusb/src/device/usbd_control.c ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/lib/lwip/src/core/ipv4/etharp.c [] []
/src/tinyusb/src/tusb.c ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] []
/src/tinyusb/test/fuzz/device/cdc/src/usb_descriptors.cc ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc'] []
/src/tinyusb/test/fuzz/msc_fuzz.cc [] []
/src/tinyusb/test/fuzz/usbd_fuzz.cc ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/lib/lwip/src/core/mem.c [] []
/src/tinyusb/lib/lwip/src/core/timeouts.c [] []
/src/tinyusb/lib/networking/rndis_reports.c [] []
/src/tinyusb/lib/lwip/src/core/ipv4/ip4.c [] []
/src/tinyusb/lib/lwip/src/apps/http/httpd.c [] []
/src/tinyusb/lib/lwip/src/core/tcp.c [] []
/src/tinyusb/src/common/tusb_fifo.c ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/src/class/msc/msc_device.c [] []
/src/tinyusb/lib/lwip/src/core/pbuf.c [] []
/src/tinyusb/lib/lwip/src/core/stats.c [] []
/src/tinyusb/test/fuzz/device/msc/src/usb_descriptors.cc ['/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc'] []
/src/tinyusb/test/fuzz/dcd_fuzz.cc ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/test/fuzz/device/net/src/fuzz.cc ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/src/tinyusb/lib/lwip/src/core/tcp_in.c [] []
/usr/local/bin/../include/c++/v1/stdexcept [] []

Directories in report

Directory
/src/tinyusb/lib/lwip/src/apps/http/
/src/tinyusb/src/device/
/src/tinyusb/src/
/src/tinyusb/src/class/msc/
/src/tinyusb/lib/lwip/src/core/ipv4/
/src/tinyusb/lib/lwip/src/netif/
/src/tinyusb/test/fuzz/device/net/src/
/src/tinyusb/test/fuzz/
/src/tinyusb/test/fuzz/device/cdc/src/
/src/tinyusb/src/common/
/usr/local/bin/../include/c++/v1/
/src/tinyusb/lib/lwip/src/core/
/src/tinyusb/lib/networking/
/src/tinyusb/test/fuzz/device/msc/src/
/src/tinyusb/src/class/net/
/usr/include/
/src/tinyusb/src/class/cdc/