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: gtp_message_fuzz

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 39 13.0%
gold [1:9] 105 35.1%
yellow [10:29] 8 2.67%
greenyellow [30:49] 3 1.00%
lawngreen 50+ 144 48.1%
All colors 299 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
8 11 ogs_log_vprintf call site: 00011 ogs_log_printf
8 49 ogs_log_vprintf call site: 00049 log_timestamp
4 95 ogs_core_initialize call site: 00095 ogs_hash_make
3 41 log_content call site: 00041 ogs_slprintf
3 169 ogs_tlv_parse_msg call site: 00169 ogs_log_printf
2 139 ogs_pkbuf_put call site: 00139 ogs_log_printf
2 156 ogs_pkbuf_push call site: 00156 ogs_log_printf
2 178 ogs_tlv_parse_block call site: 00178 ogs_log_printf
2 255 tlv_parse_leaf call site: 00255 ogs_log_printf
1 45 ogs_log_vprintf call site: 00045 ogs_slprintf
1 66 ogs_talloc_size call site: 00066 ogs_log_printf
1 135 ogs_pkbuf_alloc_debug call site: 00135 ogs_log_printf

Runtime coverage analysis

Covered functions
67
Functions that are reachable but not covered
23
Reachable functions
89
Percentage of reachable functions covered
74.16%
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
tests/fuzzing/gtp-message-fuzz.c 1
tests/fuzzing/fuzzing.h 1
lib/core/ogs-core.c 2
lib/core/ogs-memory.c 4
lib/core/ogs-log.c 15
lib/core/ogs-list.h 3
lib/core/ogs-abort.c 1
lib/core/ogs-time.c 3
lib/core/ogs-strings.c 3
lib/core/ogs-errno.c 1
lib/core/ogs-hash.c 2
lib/core/ogs-pkbuf.c 6
lib/core/ogs-socket.c 1
lib/core/ogs-tlv.c 7
lib/core/ogs-pkbuf.h 6
lib/gtp/v2/message.c 1
/usr/include/x86_64-linux-gnu/bits/byteswap.h 1
lib/core/ogs-tlv-msg.c 5
lib/core/ogs-rbtree.h 1
lib/core/ogs-rbtree.c 5

Fuzzer: nas_message_fuzz

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 158 13.1%
gold [1:9] 304 25.2%
yellow [10:29] 75 6.23%
greenyellow [30:49] 22 1.83%
lawngreen 50+ 643 53.4%
All colors 1202 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
19 11 ogs_log_vprintf call site: 00011 ogs_log_printf
13 35 ogs_vsnprintf call site: 00035 log_domain
8 49 ogs_log_vprintf call site: 00049 log_timestamp
8 111 ogs_log_find_domain call site: 00111 ogs_log_set_domain_level
4 95 ogs_core_initialize call site: 00095 ogs_hash_make
2 138 ogs_pkbuf_put call site: 00138 ogs_log_printf
2 150 ogs_pkbuf_push call site: 00150 ogs_log_printf
2 169 ogs_log_hexdump_func call site: 00169 ogs_log_printf
2 970 ogs_nas_eps_decode_identity_type_2 call site: 00970 ogs_log_printf
2 1061 ogs_nas_eps_decode_security_mode_reject call site: 01061 ogs_log_printf
2 1066 ogs_nas_eps_decode_emm_status call site: 01066 ogs_log_printf
1 66 ogs_talloc_size call site: 00066 ogs_log_printf

Runtime coverage analysis

Covered functions
156
Functions that are reachable but not covered
32
Reachable functions
188
Percentage of reachable functions covered
82.98%
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
tests/fuzzing/nas-message-fuzz.c 1
tests/fuzzing/fuzzing.h 1
lib/core/ogs-core.c 2
lib/core/ogs-memory.c 4
lib/core/ogs-log.c 15
lib/core/ogs-list.h 3
lib/core/ogs-abort.c 1
lib/core/ogs-time.c 3
lib/core/ogs-strings.c 3
lib/core/ogs-errno.c 1
lib/core/ogs-hash.c 2
lib/core/ogs-pkbuf.c 6
lib/core/ogs-socket.c 1
lib/core/ogs-tlv.c 1
lib/core/ogs-pkbuf.h 6
lib/nas/eps/decoder.c 28
lib/nas/eps/ies.c 88
/usr/include/x86_64-linux-gnu/bits/byteswap.h 2

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
ogs_gtp_send_error_message /src/open5gs/builddir/../lib/gtp/path.c 4 ['N/A', 'int', 'char', 'char'] 13 0 48 7 8 103 0 630 480
ogs_nas_esm_decode /src/open5gs/builddir/../lib/nas/eps/decoder.c 2 ['N/A', 'N/A'] 7 0 649 87 23 84 0 462 356
ogs_gtp_context_parse_config /src/open5gs/builddir/../lib/gtp/context.c 2 ['N/A', 'N/A'] 7 0 1929 434 105 83 0 469 330
ogs_app_initialize /src/open5gs/builddir/../lib/app/ogs-init.c 3 ['N/A', 'N/A', 'N/A'] 18 0 475 74 16 112 0 448 245
ogs_app_parse_session_conf /src/open5gs/builddir/../lib/app/ogs-config.c 2 ['N/A', 'N/A'] 16 0 1101 239 55 50 0 283 162
ogs_app_config_session_data /src/open5gs/builddir/../lib/app/ogs-config.c 5 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A'] 15 0 1043 161 21 48 0 173 71
ogs_gtp_xact_receive /src/open5gs/builddir/../lib/gtp/xact.c 3 ['N/A', 'N/A', 'N/A'] 10 0 399 61 12 83 0 388 63
eps_qos_build /src/open5gs/builddir/../lib/nas/common/types.c 6 ['N/A', 'char', 'size_t', 'size_t', 'size_t', 'size_t'] 1 0 231 27 10 1 0 63 63
ogs_app_parse_local_conf /src/open5gs/builddir/../lib/app/ogs-config.c 1 ['N/A'] 15 0 807 194 46 43 0 176 61
ogs_getopt_long /src/open5gs/builddir/../lib/core/ogs-getopt.c 3 ['N/A', 'N/A', 'N/A'] 3 0 291 40 15 13 1 89 59

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

Functions statically reachable by fuzzers
49.0%
381 / 776
Cyclomatic complexity statically reachable by fuzzers
65.0%
2741 / 4215

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/open5gs/builddir/../lib/core/ogs-rbtree.h ['gtp_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-time.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-epoll.c [] []
/src/open5gs/builddir/../lib/core/ogs-conv.h [] []
/src/open5gs/builddir/../lib/core/ogs-socknode.c [] []
/src/open5gs/builddir/../lib/gtp/v2/conv.c [] []
/src/open5gs/builddir/../lib/app/ogs-config.c [] []
/src/open5gs/builddir/../lib/nas/common/types.c [] []
/src/open5gs/builddir/../lib/core/ogs-getopt.c [] []
/src/open5gs/builddir/../lib/gtp/v1/message.c [] []
/src/open5gs/builddir/../lib/nas/eps/decoder.c ['nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-thread.h [] []
/src/open5gs/builddir/../lib/core/ogs-env.c [] []
/src/open5gs/builddir/../lib/core/ogs-pkbuf.h ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-strings.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/app/ogs-context.c [] []
/src/open5gs/builddir/../lib/gtp/v2/build.c [] []
/src/open5gs/builddir/../lib/proto/types.c [] []
/src/open5gs/builddir/../lib/core/ogs-timer.c [] []
/src/open5gs/builddir/../lib/core/ogs-errno.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-conv.c [] []
/src/open5gs/builddir/../lib/core/ogs-socket.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-tlv.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/gtp/v2/message.c ['gtp_message_fuzz'] []
/src/open5gs/builddir/../lib/app/ogs-init.c [] []
/src/open5gs/builddir/../lib/gtp/path.c [] []
/src/open5gs/builddir/../lib/nas/eps/ies.c ['nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-list.h ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../tests/fuzzing/nas-message-fuzz.c ['nas_message_fuzz'] []
/src/open5gs/builddir/../tests/fuzzing/gtp-message-fuzz.c ['gtp_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-log.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-tlv-msg.c ['gtp_message_fuzz'] []
/src/open5gs/builddir/../lib/app/ogs-yaml.c [] []
/src/open5gs/builddir/../lib/core/ogs-poll.c [] []
/src/open5gs/builddir/../lib/gtp/v2/path.c [] []
/src/open5gs/builddir/../lib/core/ogs-sockaddr.c [] []
/src/open5gs/builddir/../lib/core/ogs-pkbuf.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-hash.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/gtp/context.c [] []
/src/open5gs/builddir/../lib/core/ogs-sockopt.c [] []
/src/open5gs/builddir/../lib/core/ogs-memory.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-queue.c [] []
/src/open5gs/builddir/../lib/core/ogs-core.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-rbtree.c ['gtp_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-notify.c [] []
/src/open5gs/builddir/../lib/gtp/v1/build.c [] []
/src/open5gs/builddir/../tests/fuzzing/fuzzing.h ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-udp.c [] []
/src/open5gs/builddir/../lib/gtp/xact.c [] []
/usr/include/x86_64-linux-gnu/bits/byteswap.h ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/core/ogs-abort.c ['gtp_message_fuzz', 'nas_message_fuzz'] []
/src/open5gs/builddir/../lib/gtp/v1/path.c [] []

Directories in report

Directory
/src/open5gs/builddir/../lib/nas/common/
/src/open5gs/builddir/../lib/app/
/usr/include/x86_64-linux-gnu/bits/
/src/open5gs/builddir/../tests/fuzzing/
/src/open5gs/builddir/../lib/gtp/v1/
/src/open5gs/builddir/../lib/gtp/v2/
/src/open5gs/builddir/../lib/gtp/
/src/open5gs/builddir/../lib/nas/eps/
/src/open5gs/builddir/../lib/core/
/src/open5gs/builddir/../lib/proto/