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

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
750 750 6 :

['merge', 'compute_minrun', 'check_invariant', 'collapse', 'count_run', 'git__free.14332']

750 810 git__tsort_r call site: 00000 /src/libgit2/src/util/tsort.c:346
239 239 2 :

['midx_parse_object_offsets', 'midx_parse_object_large_offsets']

239 239 git_midx_parse call site: 00157 /src/libgit2/src/libgit2/midx.c:275
226 339 3 :

['git_str_grow', 'git__free.140', 'git_error_set_oom']

226 339 git_str_vprintf call site: 00021 /src/libgit2/src/util/str.c:529
126 126 1 :

['get_passwd_home']

246 365 git_sysdir_guess_xdg_dirs call site: 00000 /src/libgit2/src/libgit2/sysdir.c:401
126 126 1 :

['get_passwd_home']

246 246 git_sysdir_guess_home_dirs call site: 00000 /src/libgit2/src/libgit2/sysdir.c:356
120 120 1 :

['git_futils_mmap_free']

120 125 git_midx_close call site: 00204 /src/libgit2/src/libgit2/midx.c:484
113 113 1 :

['git_error_set_oom']

113 113 git_str_try_grow call site: 00004 /src/libgit2/src/util/str.c:75
18 131 11 :

['git_time_monotonic.5867', 'getgid', 'getsid', 'getuid', 'gettimeofday', 'getpid', 'getloadavg', 'getppid', 'getpgid', 'git_error_set', '__errno_location']

18 131 getseed call site: 00000 /src/libgit2/src/util/rand.c:89
9 9 1 :

['git_vector_dispose_deep']

9 9 git_merge_driver_global_init call site: 00000 /src/libgit2/src/libgit2/merge_driver.c:220
8 8 1 :

['git_filter_free']

8 8 git_filter_global_init call site: 00000 /src/libgit2/src/libgit2/filter.c:215
4 117 3 :

['strerror', 'git_str_puts', '__errno_location']

4 232 git_error_vset call site: 00025 /src/libgit2/src/util/errors.c:205
2 115 2 :

['git_error_set', 'git_atomic32_dec']

2 115 git_runtime_shutdown_register call site: 00000 /src/libgit2/src/util/runtime.c:51

Fuzzer calltree

0 LLVMFuzzerTestOneInput [function] [call site] 00000
1 git_str_init [function] [call site] 00001
2 git_str_grow [function] [call site] 00002
3 git_str_try_grow [function] [call site] 00003
4 git_error_set [function] [call site] 00004
5 git_error_vset [function] [call site] 00005
6 threadstate_get [function] [call site] 00006
7 git_tlsdata_get [function] [call site] 00007
8 pthread_getspecific [call site] 00008
7 git_str_init [function] [call site] 00009
7 git_tlsdata_set [function] [call site] 00010
8 pthread_setspecific [call site] 00011
6 __errno_location [call site] 00012
6 git_str_clear [function] [call site] 00013
6 git_str_vprintf [function] [call site] 00014
7 strlen [call site] 00015
7 git_error_set_oom [function] [call site] 00016
8 threadstate_get [function] [call site] 00017
7 git_error_set_oom [function] [call site] 00018
7 git_str_grow [function] [call site] 00019
7 vsnprintf [call site] 00020
7 git__free [function] [call site] 00021
7 git_error_set_oom [function] [call site] 00022
7 git_error_set_oom [function] [call site] 00023
7 git_str_grow [function] [call site] 00024
6 git_str_put [function] [call site] 00025
7 git_error_set [function] [call site] 00026
7 git_error_set_oom [function] [call site] 00027
7 git_error_set_oom [function] [call site] 00028
7 git_str_grow [function] [call site] 00029
6 strerror [call site] 00030
6 git_str_puts [function] [call site] 00031
7 git_error_set [function] [call site] 00032
7 strlen [call site] 00033
7 git_str_put [function] [call site] 00034
6 __errno_location [call site] 00035
6 git_str_oom [function] [call site] 00036
6 set_error_from_buffer [function] [call site] 00037
7 threadstate_get [function] [call site] 00038
4 git__free [function] [call site] 00039
4 git_error_set_oom [function] [call site] 00040
4 git__realloc [function] [call site] 00041
5 git_error_set_oom [function] [call site] 00042
4 git__free [function] [call site] 00043
1 git_hash_buf [function] [call site] 00044
2 git_hash_ctx_init [function] [call site] 00045
3 git_hash_sha1_ctx_init [function] [call site] 00046
4 git_hash_sha1_init [function] [call site] 00047
5 git_error_set [function] [call site] 00048
5 SHA1DCInit [function] [call site] 00049
3 git_hash_sha256_ctx_init [function] [call site] 00050
4 git_hash_sha256_init [function] [call site] 00051
5 SHA256Reset [function] [call site] 00052
6 SHA224_256Reset [function] [call site] 00053
5 git_error_set [function] [call site] 00054
3 git_error_set [function] [call site] 00055
2 git_hash_update [function] [call site] 00056
3 git_hash_sha1_update [function] [call site] 00057
4 git_error_set [function] [call site] 00058
4 SHA1DCUpdate [function] [call site] 00059
5 sha1_process [function] [call site] 00060
6 sha1_compression_states [function] [call site] 00061
6 ubc_check [function] [call site] 00062
6 sha1_recompression_step [function] [call site] 00063
7 sha1recompress_fast_58 [function] [call site] 00064
7 sha1recompress_fast_65 [function] [call site] 00065
7 abort [call site] 00066
6 sha1_compression_W [function] [call site] 00067
6 sha1_compression_W [function] [call site] 00068
5 sha1_process [function] [call site] 00069
3 git_hash_sha256_update [function] [call site] 00070
4 git_error_set [function] [call site] 00071
4 SHA256Input [function] [call site] 00072
5 SHA224_256ProcessMessageBlock [function] [call site] 00073
4 git_error_set [function] [call site] 00074
3 git_error_set [function] [call site] 00075
2 git_hash_final [function] [call site] 00076
3 git_hash_sha1_final [function] [call site] 00077
4 git_error_set [function] [call site] 00078
4 SHA1DCFinal [function] [call site] 00079
5 SHA1DCUpdate [function] [call site] 00080
5 sha1_process [function] [call site] 00081
4 git_error_set [function] [call site] 00082
3 git_hash_sha256_final [function] [call site] 00083
4 git_error_set [function] [call site] 00084
4 SHA256Result [function] [call site] 00085
5 SHA224_256ResultN [function] [call site] 00086
6 SHA224_256Finalize [function] [call site] 00087
7 SHA224_256PadMessage [function] [call site] 00088
8 SHA224_256ProcessMessageBlock [function] [call site] 00089
8 SHA224_256ProcessMessageBlock [function] [call site] 00090
4 git_error_set [function] [call site] 00091
3 git_error_set [function] [call site] 00092
2 git_hash_ctx_cleanup [function] [call site] 00093
3 git_hash_sha1_ctx_cleanup [function] [call site] 00094
3 git_hash_sha256_ctx_cleanup [function] [call site] 00095
1 fprintf [call site] 00096
1 abort [call site] 00097
1 git_str_attach_notowned [function] [call site] 00098
2 git_str_is_allocated [function] [call site] 00099
2 git_str_dispose [function] [call site] 00100
3 git__free [function] [call site] 00101
3 git_str_init [function] [call site] 00102
2 git_str_init [function] [call site] 00103
1 git_str_cstr [function] [call site] 00104
1 git_str_len [function] [call site] 00105
1 git_midx_parse [function] [call site] 00106
2 git_error_set [function] [call site] 00107
2 git_oid_size [function] [call site] 00108
2 midx_error [function] [call site] 00109
3 git_error_set [function] [call site] 00110
2 htonl [call site] 00111
2 midx_error [function] [call site] 00112
2 midx_error [function] [call site] 00113
2 midx_error [function] [call site] 00114
2 ntohl [call site] 00115
2 ntohl [call site] 00116
2 ntohl [call site] 00117
2 midx_error [function] [call site] 00118
2 midx_error [function] [call site] 00119
2 midx_error [function] [call site] 00120
2 ntohl [call site] 00121
2 midx_parse_packfile_names [function] [call site] 00122
3 midx_error [function] [call site] 00123
3 midx_error [function] [call site] 00124
3 git_vector_init [function] [call site] 00125
4 git_error_set [function] [call site] 00126
4 resize_vector [function] [call site] 00127
5 git__reallocarray [function] [call site] 00128
6 git_error_set_oom [function] [call site] 00129
6 git__realloc [function] [call site] 00130
3 git__strcmp_cb [function] [call site] 00131
4 strcmp [call site] 00132
3 strnlen [call site] 00133
3 midx_error [function] [call site] 00134
3 midx_error [function] [call site] 00135
3 git_vector_insert [function] [call site] 00136
4 git_error_set [function] [call site] 00137
4 compute_new_size [function] [call site] 00138
4 resize_vector [function] [call site] 00139
3 git_vector_get [function] [call site] 00140
3 strcmp [call site] 00141
3 midx_error [function] [call site] 00142
3 strlen [call site] 00143
3 git__suffixcmp [function] [call site] 00144
4 strlen [call site] 00145
4 strlen [call site] 00146
4 strcmp [call site] 00147
3 midx_error [function] [call site] 00148
3 strchr [call site] 00149
3 midx_error [function] [call site] 00150
2 midx_parse_oid_fanout [function] [call site] 00151
3 midx_error [function] [call site] 00152
3 midx_error [function] [call site] 00153
3 midx_error [function] [call site] 00154
3 ntohl [call site] 00155
3 midx_error [function] [call site] 00156
2 midx_parse_oid_lookup [function] [call site] 00157
3 git_oid_size [function] [call site] 00158
3 midx_error [function] [call site] 00159
3 midx_error [function] [call site] 00160
3 midx_error [function] [call site] 00161
2 midx_parse_object_offsets [function] [call site] 00162
3 midx_error [function] [call site] 00163
3 midx_error [function] [call site] 00164
3 midx_error [function] [call site] 00165
2 midx_parse_object_large_offsets [function] [call site] 00166
3 midx_error [function] [call site] 00167
1 git_midx_entry_find [function] [call site] 00168
2 git_error_set [function] [call site] 00169
2 git_oid_size [function] [call site] 00170
2 git_oid_hexsize [function] [call site] 00171
2 ntohl [call site] 00172
2 ntohl [call site] 00173
2 git_pack__lookup_id [function] [call site] 00174
3 git_oid_size [function] [call site] 00175
3 git_oid_raw_cmp [function] [call site] 00176
4 memcmp [call site] 00177
2 git_oid_raw_ncmp [function] [call site] 00178
2 git_oid_raw_ncmp [function] [call site] 00179
2 git_odb__error_notfound [function] [call site] 00180
3 git_oid_tostr [function] [call site] 00181
4 git_oid_type [function] [call site] 00182
4 git_oid_hexsize [function] [call site] 00183
4 git_oid_nfmt [function] [call site] 00184
5 git_oid_type [function] [call site] 00185
5 git_oid_hexsize [function] [call site] 00186
5 oid_error_invalid [function] [call site] 00187
5 git_oid_fmt_substr [function] [call site] 00188
3 git_error_set [function] [call site] 00189
3 git_error_set [function] [call site] 00190
2 git_odb__error_ambiguous [function] [call site] 00191
3 git_error_set [function] [call site] 00192
2 ntohl [call site] 00193
2 git_odb__error_notfound [function] [call site] 00194
2 ntohl [call site] 00195
2 ntohl [call site] 00196
2 ntohl [call site] 00197
2 git_vector_length [function] [call site] 00198
2 midx_error [function] [call site] 00199
2 git_oid_from_raw [function] [call site] 00200
3 git_oid_size [function] [call site] 00201
3 oid_error_invalid [function] [call site] 00202
1 git_midx_close [function] [call site] 00203
2 git_error_set [function] [call site] 00204
2 git_futils_mmap_free [function] [call site] 00205
3 p_munmap [function] [call site] 00206
4 git_error_set [function] [call site] 00207
4 munmap [call site] 00208
2 git_vector_dispose [function] [call site] 00209
3 git__free [function] [call site] 00210
1 git_str_dispose [function] [call site] 00211