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

Fuzzer details

Fuzzer: uri_dissect_query_malloc_fuzzer

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 3.44%
gold [1:9] 0 0.0%
yellow [10:29] 1 3.44%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 27 93.1%
All colors 29 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
0 0 None 0 56 uriUnescapeInPlaceExA call site: 00008 /src/uriparser/src/UriEscape.c:423
0 0 None 0 40 uriEscapeExA call site: 00018 /src/uriparser/src/UriEscape.c:105
0 0 None 0 0 uriAppendQueryItemA call site: 00005 /src/uriparser/src/UriQuery.c:313
0 0 None 0 0 uriAppendQueryItemA call site: 00006 /src/uriparser/src/UriQuery.c:333

Runtime coverage analysis

Covered functions
19
Functions that are reachable but not covered
2
Reachable functions
19
Percentage of reachable functions covered
89.47%
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/uri_dissect_query_malloc_fuzzer.cc 1
/src/uriparser/src/UriQuery.c 11
/src/uriparser/src/UriMemory.c 1
/src/uriparser/src/UriEscape.c 2
/src/uriparser/src/UriCommon.c 3

Fuzzer: uri_free_fuzzer

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 30 13.9%
gold [1:9] 47 21.8%
yellow [10:29] 14 6.51%
greenyellow [30:49] 11 5.11%
lawngreen 50+ 113 52.5%
All colors 215 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
38 38 1 :

['uriStopMallocA']

38 38 uriParseSegmentNzNcOrScheme2A call site: 00052 /src/uriparser/src/UriParse.c:1899
38 38 1 :

['uriStopMallocA']

38 38 uriParseSegmentNzNcOrScheme2A call site: 00203 /src/uriparser/src/UriParse.c:1923
38 38 1 :

['uriStopMallocA']

38 38 uriParsePathRootlessA call site: 00061 /src/uriparser/src/UriParse.c:1509
38 38 1 :

['uriStopMallocA']

38 38 uriParseMustBeSegmentNzNcA call site: 00023 /src/uriparser/src/UriParse.c:895
38 38 1 :

['uriStopMallocA']

38 38 uriParseMustBeSegmentNzNcA call site: 00033 /src/uriparser/src/UriParse.c:947
38 38 1 :

['uriStopMallocA']

38 38 uriParseMustBeSegmentNzNcA call site: 00045 /src/uriparser/src/UriParse.c:960
38 38 1 :

['uriStopMallocA']

38 38 uriParseIpLit2A call site: 00082 /src/uriparser/src/UriParse.c:568
38 38 1 :

['uriStopMallocA']

38 38 uriParseOwnHost2A call site: 00177 /src/uriparser/src/UriParse.c:1067
38 38 1 :

['uriStopMallocA']

38 38 uriParsePathAbsNoLeadSlashA call site: 00199 /src/uriparser/src/UriParse.c:1484
0 0 None 38 38 uriParseSegmentNzNcOrScheme2A call site: 00050 /src/uriparser/src/UriParse.c:1894
0 0 None 38 38 uriParseMustBeSegmentNzNcA call site: 00026 /src/uriparser/src/UriParse.c:938
0 0 None 0 1225 uriParseIPv6address2A call site: 00084 /src/uriparser/src/UriParse.c:600

Runtime coverage analysis

Covered functions
63
Functions that are reachable but not covered
2
Reachable functions
62
Percentage of reachable functions covered
96.77%
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/uri_free_fuzzer.cc 1
/src/uriparser/src/UriParse.c 46
/src/uriparser/src/UriMemory.c 1
/src/uriparser/src/UriCommon.c 3
/src/uriparser/src/UriParseBase.c 2
/src/uriparser/src/UriIp4.c 6
/src/uriparser/src/UriIp4Base.c 2

Fuzzer: uri_parse_fuzzer

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 60 15.6%
gold [1:9] 36 9.39%
yellow [10:29] 27 7.04%
greenyellow [30:49] 2 0.52%
lawngreen 50+ 258 67.3%
All colors 383 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
38 38 1 :

['uriStopMallocA']

38 38 uriParseSegmentNzNcOrScheme2A call site: 00114 /src/uriparser/src/UriParse.c:1899
38 38 1 :

['uriStopMallocA']

38 38 uriParseSegmentNzNcOrScheme2A call site: 00241 /src/uriparser/src/UriParse.c:1923
38 38 1 :

['uriStopMallocA']

38 38 uriParsePathRootlessA call site: 00123 /src/uriparser/src/UriParse.c:1509
38 38 1 :

['uriStopMallocA']

38 38 uriParseMustBeSegmentNzNcA call site: 00085 /src/uriparser/src/UriParse.c:895
38 38 1 :

['uriStopMallocA']

38 38 uriParseMustBeSegmentNzNcA call site: 00095 /src/uriparser/src/UriParse.c:947
38 38 1 :

['uriStopMallocA']

38 38 uriParseMustBeSegmentNzNcA call site: 00107 /src/uriparser/src/UriParse.c:960
38 38 1 :

['uriStopMallocA']

38 38 uriParseIpLit2A call site: 00144 /src/uriparser/src/UriParse.c:568
38 38 1 :

['uriStopMallocA']

38 38 uriParseOwnHost2A call site: 00215 /src/uriparser/src/UriParse.c:1067
38 38 1 :

['uriStopMallocA']

38 38 uriParsePathAbsNoLeadSlashA call site: 00237 /src/uriparser/src/UriParse.c:1484
17 17 1 :

['uriPreventLeakageA']

17 17 uriNormalizeSyntaxEngineA call site: 00324 /src/uriparser/src/UriNormalize.c:766
0 0 None 585 1142 uriNormalizeSyntaxEngineA call site: 00280 /src/uriparser/src/UriNormalize.c:558
0 0 None 585 1124 uriNormalizeSyntaxEngineA call site: 00283 /src/uriparser/src/UriNormalize.c:588

Runtime coverage analysis

Covered functions
113
Functions that are reachable but not covered
10
Reachable functions
126
Percentage of reachable functions covered
92.06%
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/uri_parse_fuzzer.cc 7
/src/uriparser/src/UriEscape.c 4
/src/uriparser/src/UriCommon.c 12
/src/uriparser/src/UriFile.c 6
/src/uriparser/src/UriIp4.c 6
/src/uriparser/src/UriIp4Base.c 2
/src/uriparser/src/UriParse.c 46
/src/uriparser/src/UriMemory.c 1
/src/uriparser/src/UriParseBase.c 2
/src/uriparser/src/UriRecompose.c 2
/src/uriparser/src/UriCompare.c 1
/src/uriparser/src/UriNormalize.c 14
/src/uriparser/src/UriNormalizeBase.c 1
/src/uriparser/src/UriResolve.c 6
/src/uriparser/src/UriShorten.c 5

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
uriParseSingleUriW /src/uriparser/src/UriParse.c 3 ['struct.UriUriStructW *', 'int *', 'int **'] 5 0 15 3 2 60 0 354 321
uriNormalizeSyntaxW /src/uriparser/src/UriNormalize.c 1 ['struct.UriUriStructW *'] 6 0 13 3 2 21 0 286 266
uriToStringW /src/uriparser/src/UriRecompose.c 4 ['int *', 'struct.UriUriStructW *', 'int ', 'int *'] 1 0 16 3 2 3 0 147 124
uriAddBaseUriW /src/uriparser/src/UriResolve.c 3 ['struct.UriUriStructW *', 'struct.UriUriStructW *', 'struct.UriUriStructW *'] 3 0 16 3 2 17 0 193 93
uriComposeQueryMallocW /src/uriparser/src/UriQuery.c 2 ['int **', 'struct.UriQueryListStructW *'] 4 0 16 3 2 10 0 85 57
uriRemoveBaseUriW /src/uriparser/src/UriShorten.c 4 ['struct.UriUriStructW *', 'struct.UriUriStructW *', 'struct.UriUriStructW *', 'int '] 4 0 16 3 2 13 0 131 56
uriDissectQueryMallocW /src/uriparser/src/UriQuery.c 4 ['struct.UriQueryListStructW **', 'int *', 'int *', 'int *'] 3 0 18 3 2 7 0 60 52
uriTestMemoryManager /src/uriparser/src/UriMemory.c 1 ['struct.UriMemoryManagerStruct *'] 0 0 701 101 49 1 0 55 49
uriCompleteMemoryManager /src/uriparser/src/UriMemory.c 2 ['struct.UriMemoryManagerStruct *', 'struct.UriMemoryManagerStruct *'] 1 0 52 10 5 6 0 36 36
uriWindowsFilenameToUriStringW /src/uriparser/src/UriFile.c 2 ['int *', 'int *'] 3 0 14 3 2 5 0 70 35

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

Functions statically reachable by fuzzers
86.0%
238 / 277
Cyclomatic complexity statically reachable by fuzzers
94.0%
2222 / 2373

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 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/uri_parse_fuzzer.cc ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriFile.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriShorten.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriIp4.c ['uri_free_fuzzer', 'uri_parse_fuzzer'] ['uri_free_fuzzer', 'uri_parse_fuzzer']
/src/uriparser/src/UriCompare.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriCommon.c ['uri_dissect_query_malloc_fuzzer', 'uri_free_fuzzer', 'uri_parse_fuzzer'] ['uri_dissect_query_malloc_fuzzer', 'uri_free_fuzzer', 'uri_parse_fuzzer']
/usr/local/bin/../include/c++/v1/stdexcept [] []
/src/uriparser/src/UriParseBase.c ['uri_free_fuzzer', 'uri_parse_fuzzer'] ['uri_free_fuzzer', 'uri_parse_fuzzer']
/src/uriparser/src/UriNormalizeBase.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriIp4Base.c ['uri_free_fuzzer', 'uri_parse_fuzzer'] ['uri_free_fuzzer', 'uri_parse_fuzzer']
/src/uriparser/src/UriMemory.c ['uri_dissect_query_malloc_fuzzer', 'uri_free_fuzzer', 'uri_parse_fuzzer'] ['uri_dissect_query_malloc_fuzzer', 'uri_free_fuzzer', 'uri_parse_fuzzer']
/src/uriparser/src/UriEscape.c ['uri_dissect_query_malloc_fuzzer', 'uri_parse_fuzzer'] ['uri_dissect_query_malloc_fuzzer', 'uri_parse_fuzzer']
/src/uriparser/src/UriNormalize.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriRecompose.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uriparser/src/UriResolve.c ['uri_parse_fuzzer'] ['uri_parse_fuzzer']
/src/uri_dissect_query_malloc_fuzzer.cc ['uri_dissect_query_malloc_fuzzer'] ['uri_dissect_query_malloc_fuzzer']
/src/uriparser/src/UriParse.c ['uri_free_fuzzer', 'uri_parse_fuzzer'] ['uri_free_fuzzer', 'uri_parse_fuzzer']
/src/uriparser/src/UriQuery.c ['uri_dissect_query_malloc_fuzzer'] ['uri_dissect_query_malloc_fuzzer']
/src/uri_free_fuzzer.cc ['uri_free_fuzzer'] ['uri_free_fuzzer']

Directories in report

Directory
/src/uriparser/src/
/usr/local/bin/../include/c++/v1/
/src/