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/net_ncm/fuzz.c

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 1 50.0%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 1 50.0%
All colors 2 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
1 0 EP call site: 00000 recv_validate_datagram

Runtime coverage analysis

Covered functions
152
Functions that are reachable but not covered
0
Reachable functions
2
Percentage of reachable functions covered
100.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.
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
/src/tinyusb/test/fuzz/device/net_ncm/fuzz.c 1
/src/tinyusb/src/class/net/ncm_device.c 1

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 45 31.2%
gold [1:9] 4 2.77%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 95 65.9%
All colors 144 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
6 87 tud_task_ext call site: 00087 usbd_control_xfer_cb
5 72 process_get_status call site: 00072 process_get_status
4 45 tud_control_xfer call site: 00045 configuration_reset
3 115 stream_xfer call site: 00115 stream_release
2 11 dcd_int_handler call site: 00011 tu_fifo_write_n_access_mode
2 15 tu_fifo_write_n_access_mode call site: 00015 tud_event_hook_cb
2 19 dcd_int_handler call site: 00019 tud_task_ext
2 51 process_set_config call site: 00051 tu_bind_driver_to_ep_itf
2 83 usbd_edpt_stall call site: 00083 invoke_class_control
2 95 tud_task_ext call site: 00095 cdc_task
1 8 tud_rhport_init call site: 00008 dcd_int_handler
1 22 tud_task_ext call site: 00022 tu_fifo_read_n_access_mode

Runtime coverage analysis

Covered functions
152
Functions that are reachable but not covered
9
Reachable functions
90
Percentage of reachable functions covered
90.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.
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
/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc 2
/src/tinyusb/test/fuzz/fuzz.cc 1
/src/tinyusb/src/tusb.c 12
/src/tinyusb/src/device/usbd.c 35
/src/tinyusb/src/common/tusb_fifo.c 10
/src/tinyusb/test/fuzz/dcd_fuzz.cc 9
/src/tinyusb/test/fuzz/usbd_fuzz.cc 4
/src/tinyusb/test/fuzz/device/cdc/src/usb_descriptors.cc 3
/src/tinyusb/src/class/cdc/cdc_device.c 12

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 34 35.0%
gold [1:9] 4 4.12%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 59 60.8%
All colors 97 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
6 87 tud_task_ext call site: 00087 usbd_control_xfer_cb
5 72 process_get_status call site: 00072 process_get_status
4 45 tud_control_xfer call site: 00045 configuration_reset
2 11 dcd_int_handler call site: 00011 tu_fifo_write_n_access_mode
2 15 tu_fifo_write_n_access_mode call site: 00015 tud_event_hook_cb
2 51 process_set_config call site: 00051 tu_bind_driver_to_ep_itf
2 83 usbd_edpt_stall call site: 00083 invoke_class_control
1 19 dcd_int_handler call site: 00019 dcd_event_handler
1 22 tud_task_ext call site: 00022 tu_fifo_read_n_access_mode
1 24 tu_fifo_read_n_access_mode call site: 00024 correct_read_index
1 28 tud_task_ext call site: 00028 usbd_reset
1 36 process_setup_received call site: 00036 invoke_class_control

Runtime coverage analysis

Covered functions
152
Functions that are reachable but not covered
5
Reachable functions
60
Percentage of reachable functions covered
91.67%
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
/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc 1
/src/tinyusb/test/fuzz/fuzz.cc 1
/src/tinyusb/src/tusb.c 2
/src/tinyusb/src/device/usbd.c 30
/src/tinyusb/src/common/tusb_fifo.c 8
/src/tinyusb/test/fuzz/dcd_fuzz.cc 9
/src/tinyusb/test/fuzz/usbd_fuzz.cc 4
/src/tinyusb/test/fuzz/device/msc/src/usb_descriptors.cc 3

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 42 39.2%
gold [1:9] 4 3.73%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 61 57.0%
All colors 107 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
6 87 tud_task_ext call site: 00087 usbd_control_xfer_cb
5 72 process_get_status call site: 00072 process_get_status
4 45 tud_control_xfer call site: 00045 configuration_reset
4 102 net_task call site: 00102 do_in_xfer
2 11 dcd_int_handler call site: 00011 tu_fifo_write_n_access_mode
2 15 tu_fifo_write_n_access_mode call site: 00015 tud_event_hook_cb
2 19 dcd_int_handler call site: 00019 tud_task_ext
2 51 process_set_config call site: 00051 tu_bind_driver_to_ep_itf
2 83 usbd_edpt_stall call site: 00083 invoke_class_control
2 95 tud_task_ext call site: 00095 net_task
1 0 EP call site: 00000 fuzz_init
1 8 tud_rhport_init call site: 00008 dcd_int_handler

Runtime coverage analysis

Covered functions
152
Functions that are reachable but not covered
7
Reachable functions
66
Percentage of reachable functions covered
89.39%
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
/src/tinyusb/test/fuzz/device/net/src/fuzz.cc 2
/src/tinyusb/test/fuzz/fuzz.cc 1
/src/tinyusb/src/tusb.c 2
/src/tinyusb/src/device/usbd.c 30
/src/tinyusb/src/common/tusb_fifo.c 8
/src/tinyusb/test/fuzz/dcd_fuzz.cc 9
/src/tinyusb/test/fuzz/usbd_fuzz.cc 4
/src/tinyusb/test/fuzz/device/net/src/usb_descriptors.cc 3
/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
mscd_xfer_cb /src/tinyusb/src/class/msc/msc_device.c 4 ['char', 'char', 'int', 'int'] 6 0 735 140 34 36 0 260 189
netd_xfer_cb /src/tinyusb/src/class/net/ncm_device.c 4 ['char', 'char', 'int', 'int'] 4 0 91 18 7 18 0 95 69
rndis_class_set_handler /src/tinyusb/lib/networking/rndis_reports.c 2 ['N/A', 'int'] 6 0 121 10 11 15 0 86 65
cdcd_xfer_cb /src/tinyusb/src/class/cdc/cdc_device.c 4 ['char', 'char', 'int', 'int'] 4 0 449 72 23 26 0 137 49

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

Functions statically reachable by fuzzers
63.0%
153 / 244
Cyclomatic complexity statically reachable by fuzzers
71.0%
853 / 1202

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/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/fuzz.cc', '/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc', '/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/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/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/cdc/src/usb_descriptors.cc ['/src/tinyusb/test/fuzz/device/cdc/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/cdc/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/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/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/src/class/net/ecm_rndis_device.c ['/src/tinyusb/test/fuzz/device/net/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/cdc/src/fuzz.cc']
/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']
/usr/local/bin/../include/c++/v1/optional [] []
/src/tinyusb/lib/networking/rndis_reports.c [] []
/src/tinyusb/src/class/msc/msc_device.c [] []
/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']
/src/tinyusb/src/class/net/ncm_device.c ['/src/tinyusb/test/fuzz/device/net_ncm/fuzz.c'] ['/src/tinyusb/test/fuzz/device/net_ncm/fuzz.c']
/src/tinyusb/test/fuzz/device/net_ncm/fuzz.c ['/src/tinyusb/test/fuzz/device/net_ncm/fuzz.c'] ['/src/tinyusb/test/fuzz/device/net_ncm/fuzz.c']
/src/tinyusb/test/fuzz/device/net/src/usb_descriptors.cc ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc']
/usr/local/bin/../include/c++/v1/stdexcept [] []
/src/tinyusb/test/fuzz/net_fuzz.cc ['/src/tinyusb/test/fuzz/device/net/src/fuzz.cc'] []
/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/test/fuzz/device/msc/src/usb_descriptors.cc ['/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc'] ['/src/tinyusb/test/fuzz/device/msc/src/fuzz.cc']

Directories in report

Directory
/src/tinyusb/src/
/src/tinyusb/test/fuzz/
/src/tinyusb/src/class/net/
/src/tinyusb/test/fuzz/device/msc/src/
/src/tinyusb/src/class/msc/
/src/tinyusb/test/fuzz/device/net/src/
/src/tinyusb/src/class/cdc/
/src/tinyusb/lib/networking/
/src/tinyusb/test/fuzz/device/net_ncm/
/src/tinyusb/src/common/
/src/tinyusb/src/device/
/src/tinyusb/test/fuzz/device/cdc/src/
/usr/local/bin/../include/c++/v1/