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

Fuzzer details

Fuzzer: fuzz-server-hello

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 184 61.1%
gold [1:9] 0 0.0%
yellow [10:29] 5 1.66%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 112 37.2%
All colors 301 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
572 1131 14 :

['ptls__key_schedule_update_hash', 'send_certificate_verify', 'derive_secret', 'ptls_iovec_init', 'push_change_cipher_spec', 'key_schedule_extract', 'free', 'ptls_buffer__do_pushv', 'commission_handshake_secret', 'ptls_buffer__adjust_quic_blocksize', 'derive_exporter_secret', 'send_certificate', 'send_finished', 'setup_traffic_protection']

572 1131 client_handle_finished call site: 00000 /src/picotls/lib/picotls.c:3428
144 144 2 :

['free', 'client_ech_select_hello']

144 1117 client_handle_hello call site: 00000 /src/picotls/lib/picotls.c:2803
144 144 1 :

['client_ech_select_hello']

144 660 client_handle_hello call site: 00000 /src/picotls/lib/picotls.c:2823
82 164 2 :

['calc_verify_data', 'derive_secret_with_empty_digest']

282 1437 send_client_hello call site: 00143 /src/picotls/lib/picotls.c:2447
73 73 1 :

['buffer_encrypt_record']

73 73 commit_record_message call site: 00000 /src/picotls/lib/picotls.c:849
47 214 2 :

['setup_traffic_protection', 'push_change_cipher_spec']

192 359 send_client_hello call site: 00168 /src/picotls/lib/picotls.c:2529
8 906 8 :

['ptls_buffer_reserve', 'ptls_iovec_init', 'encode_client_hello', 'ptls_aead_encrypt', 'malloc', 'ptls__key_schedule_update_hash', 'strlen', 'outer_ech_header_size']

200 1265 send_client_hello call site: 00158 /src/picotls/lib/picotls.c:2459
7 107 7 :

['ptls_iovec_init', 'ptls_decode_quicint', 'ptls_decode16', 'ptls_decode24', 'malloc', 'ptls__key_schedule_update_hash', 'client_do_handle_certificate']

7 107 client_handle_compressed_certificate call site: 00000 /src/picotls/lib/picotls.c:3305
5 7 2 :

['ptls_is_ech_handshake', 'ptls_is_server']

5 7 handle_certificate call site: 00000 /src/picotls/lib/picotls.c:3252
2 2 1 :

['posix_memalign']

2 5 ptls_buffer_reserve_aligned call site: 00028 /src/picotls/lib/picotls.c:580
0 87 1 :

['key_schedule_extract']

0 87 key_schedule_select_cipher call site: 00000 /src/picotls/lib/picotls.c:1346
0 82 2 :

['malloc', 'derive_secret']

0 82 client_handle_hello call site: 00000 /src/picotls/lib/picotls.c:2859

Runtime coverage analysis

Covered functions
105
Functions that are reachable but not covered
62
Reachable functions
121
Percentage of reachable functions covered
48.76%
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
fuzz/fuzz-server-hello.c 1
include/picotls.h 6
lib/picotls.c 74
lib/hpke.c 8

Fuzzer: fuzz-client-hello

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 163 54.8%
gold [1:9] 2 0.67%
yellow [10:29] 0 0.0%
greenyellow [30:49] 14 4.71%
lawngreen 50+ 118 39.7%
All colors 297 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
226 472 4 :

['ptls_buffer__adjust_quic_blocksize', 'push_signature_algorithms', 'ptls__key_schedule_update_hash', 'ptls_buffer__do_pushv']

226 857 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4781
170 170 1 :

['commission_handshake_secret']

170 380 server_finish_handshake call site: 00209 /src/picotls/lib/picotls.c:4871
165 457 5 :

['ptls_aead_decrypt', 'decode_client_hello', 'ptls_aead_free', 'check_client_hello_constraints', 'rebuild_ch_inner']

1612 6330 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4375
66 160 5 :

['ptls_buffer__adjust_quic_blocksize', 'build_certificate_verify_signdata', 'ptls_iovec_init', 'ptls_buffer__do_pushv', 'ptls__key_schedule_update_hash']

66 160 send_certificate_verify call site: 00198 /src/picotls/lib/picotls.c:3165
66 66 3 :

['buffer_push_encrypted_records', 'free', 'malloc']

66 66 buffer_encrypt_record call site: 00258 /src/picotls/lib/picotls.c:799
6 6 1 :

['key_schedule_update_ch1hash_prefix']

999 4572 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4488
2 2 1 :

['posix_memalign']

2 5 ptls_buffer_reserve_aligned call site: 00028 /src/picotls/lib/picotls.c:580
0 171 2 :

['setup_traffic_protection', 'ptls__key_schedule_update_hash']

0 171 server_handle_finished call site: 00000 /src/picotls/lib/picotls.c:4920
0 145 2 :

['malloc', 'derive_exporter_secret']

796 3577 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4663
0 82 1 :

['derive_secret']

498 2039 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4731
0 47 1 :

['push_change_cipher_spec']

0 47 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4596
0 4 1 :

['ptls_iovec_init']

0 7 ptls_free call site: 00294 /src/picotls/lib/picotls.c:5415

Runtime coverage analysis

Covered functions
121
Functions that are reachable but not covered
52
Reachable functions
121
Percentage of reachable functions covered
57.02%
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
fuzz/fuzz-client-hello.c 1
include/picotls.h 6
lib/picotls.c 74
lib/hpke.c 8

Fuzzer: fuzz/fuzz-asn1.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 71 84.5%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 13 15.4%
All colors 84 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
200 1131 14 :

['ptls__key_schedule_update_hash', 'send_certificate_verify', 'derive_secret', 'ptls_iovec_init', 'push_change_cipher_spec', 'key_schedule_extract', 'free', 'ptls_buffer__do_pushv', 'commission_handshake_secret', 'ptls_buffer__adjust_quic_blocksize', 'derive_exporter_secret', 'send_certificate', 'send_finished', 'setup_traffic_protection']

200 1131 client_handle_finished call site: 00000 /src/picotls/lib/picotls.c:3428
180 472 4 :

['ptls_buffer__adjust_quic_blocksize', 'push_signature_algorithms', 'ptls__key_schedule_update_hash', 'ptls_buffer__do_pushv']

180 857 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4781
170 170 1 :

['commission_handshake_secret']

170 380 server_finish_handshake call site: 00000 /src/picotls/lib/picotls.c:4871
165 457 5 :

['ptls_aead_decrypt', 'decode_client_hello', 'ptls_aead_free', 'check_client_hello_constraints', 'rebuild_ch_inner']

1566 6330 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4375
144 144 2 :

['free', 'client_ech_select_hello']

144 1117 client_handle_hello call site: 00000 /src/picotls/lib/picotls.c:2803
144 144 1 :

['client_ech_select_hello']

144 660 client_handle_hello call site: 00000 /src/picotls/lib/picotls.c:2823
66 66 3 :

['buffer_push_encrypted_records', 'free', 'malloc']

66 66 buffer_encrypt_record call site: 00000 /src/picotls/lib/picotls.c:799
60 160 5 :

['ptls_buffer__adjust_quic_blocksize', 'build_certificate_verify_signdata', 'ptls_iovec_init', 'ptls_buffer__do_pushv', 'ptls__key_schedule_update_hash']

60 160 send_certificate_verify call site: 00000 /src/picotls/lib/picotls.c:3165
8 906 8 :

['ptls_buffer_reserve', 'ptls_iovec_init', 'encode_client_hello', 'ptls_aead_encrypt', 'malloc', 'ptls__key_schedule_update_hash', 'strlen', 'outer_ech_header_size']

8 1265 send_client_hello call site: 00000 /src/picotls/lib/picotls.c:2459
7 107 7 :

['ptls_iovec_init', 'ptls_decode_quicint', 'ptls_decode16', 'ptls_decode24', 'malloc', 'ptls__key_schedule_update_hash', 'client_do_handle_certificate']

7 107 client_handle_compressed_certificate call site: 00000 /src/picotls/lib/picotls.c:3305
6 6 1 :

['key_schedule_update_ch1hash_prefix']

953 4572 server_handle_hello call site: 00000 /src/picotls/lib/picotls.c:4488
2 2 1 :

['posix_memalign']

2 5 ptls_buffer_reserve_aligned call site: 00048 /src/picotls/lib/picotls.c:580

Runtime coverage analysis

Covered functions
151
Functions that are reachable but not covered
34
Reachable functions
42
Percentage of reachable functions covered
19.05%
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
fuzz/fuzz-asn1.c 3
lib/asn1.c 9
lib/pembase64.c 6
include/picotls.h 3
lib/picotls.c 4
lib/minicrypto-pem.c 4
lib/uecc.c 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
ptls_handle_message /src/picotls/lib/picotls.c 7 ['N/A', 'N/A', 'N/A', 'size_t', 'N/A', 'size_t', 'N/A'] 15 0 65 6 3 162 0 2718 1530
secp256r1sha256_sign /src/picotls/lib/uecc.c 8 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'size_t'] 6 0 237 37 11 55 0 217 195
ptls_export /src/picotls/lib/picotls.c 2 ['N/A', 'N/A'] 4 0 1105 196 53 12 0 146 108
aesgcm_decrypt /src/picotls/lib/cifra/aes-common.h 7 ['N/A', 'N/A', 'N/A', 'size_t', 'size_t', 'N/A', 'size_t'] 8 0 90 8 4 33 0 99 75
ptls_import /src/picotls/lib/picotls.c 4 ['N/A', 'N/A', 'N/A', 'size_t'] 11 0 919 159 50 58 0 339 69
evp_keyex_exchange /src/picotls/lib/openssl.c 5 ['N/A', 'N/A', 'N/A', 'N/A', 'size_t'] 3 0 141 18 6 20 0 73 69
default_emit_certificate_cb /src/picotls/lib/picotls.c 9 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'size_t', 'int', 'N/A', 'size_t'] 5 0 297 46 14 11 0 106 66
sign_certificate /src/picotls/lib/openssl.c 8 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'size_t'] 6 0 143 20 7 23 0 88 64
verify_cert /src/picotls/lib/openssl.c 7 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'size_t'] 3 0 217 31 12 26 0 72 62
secp_key_exchange /src/picotls/lib/openssl.c 5 ['N/A', 'N/A', 'N/A', 'N/A', 'size_t'] 3 0 98 14 6 19 0 60 60

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

Functions statically reachable by fuzzers
52.0%
303 / 584
Cyclomatic complexity statically reachable by fuzzers
80.0%
3751 / 4697

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
[] []
/usr/include/openssl/x509.h [] []
/src/picotls/deps/cifra/src/ext/handy.h [] []
/src/picotls/lib/hpke.c ['fuzz-server-hello', 'fuzz-client-hello'] []
/src/picotls/deps/cifra/src/chacha20.c [] []
/src/picotls/deps/micro-ecc/platform-specific.inc [] []
/src/picotls/lib/openssl.c [] []
/src/picotls/lib/asn1.c ['fuzz/fuzz-asn1.c'] []
/src/picotls/deps/cifra/src/aes.c [] []
/src/picotls/deps/cifra/src/drbg.c [] []
/src/picotls/fuzz/fuzz-client-hello.c ['fuzz-client-hello'] ['fuzz-client-hello']
/src/picotls/deps/cifra/src/gcm.c [] []
/src/picotls/lib/uecc.c ['fuzz/fuzz-asn1.c'] []
/src/picotls/deps/cifra/src/sha256.c [] []
/src/picotls/fuzz/fuzz-asn1.c ['fuzz/fuzz-asn1.c'] ['fuzz/fuzz-asn1.c']
/src/picotls/deps/micro-ecc/curve-specific.inc [] []
/src/picotls/lib/minicrypto-pem.c ['fuzz/fuzz-asn1.c'] []
/src/picotls/lib/cifra/aes128.c [] []
/src/picotls/deps/cifra/src/hmac.c [] []
/src/picotls/deps/micro-ecc/uECC.c [] []
/src/picotls/fuzz/fuzz-server-hello.c ['fuzz-server-hello'] ['fuzz-server-hello']
/src/picotls/deps/cifra/src/blockwise.c [] []
/src/picotls/deps/cifra/src/gf128.c [] []
/src/picotls/lib/pembase64.c ['fuzz/fuzz-asn1.c'] []
/src/picotls/lib/cifra/../chacha20poly1305.h [] []
/src/picotls/lib/cifra/random.c [] []
/src/picotls/deps/cifra/src/sha512.c [] []
/src/picotls/deps/cifra/src/poly1305.c [] []
/src/picotls/lib/picotls.c ['fuzz-server-hello', 'fuzz-client-hello', 'fuzz/fuzz-asn1.c'] ['fuzz-server-hello', 'fuzz-client-hello', 'fuzz/fuzz-asn1.c']
/src/picotls/include/picotls.h ['fuzz-server-hello', 'fuzz-client-hello', 'fuzz/fuzz-asn1.c'] ['fuzz-server-hello', 'fuzz-client-hello', 'fuzz/fuzz-asn1.c']
/src/picotls/lib/cifra/chacha20.c [] []
/src/picotls/lib/cifra/aes-common.h [] []
/src/picotls/lib/cifra/aes256.c [] []
/src/picotls/deps/cifra/src/bitops.h [] []
/src/picotls/deps/cifra/src/chash.c [] []
/src/picotls/deps/cifra/src/modes.c [] []

Directories in report

Directory
/src/picotls/deps/cifra/src/
/src/picotls/lib/cifra/../
/src/picotls/deps/micro-ecc/
/src/picotls/lib/
/usr/include/openssl/
/src/picotls/include/
/src/picotls/lib/cifra/
/src/picotls/fuzz/
/src/picotls/deps/cifra/src/ext/