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: parse_cert_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 120 67.7%
gold [1:9] 2 1.12%
yellow [10:29] 0 0.0%
greenyellow [30:49] 19 10.7%
lawngreen 50+ 36 20.3%
All colors 177 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
28 59 phosphor::certs::parseCert(std::__1::basic_string , std::__1::allocator > const&) call site: 00059 _ZN3lg27detailsL11log_convertITpTkNS0_9log_flagsEJETkNS0_29unsigned_integral_except_boolEmEEDaPKcNS0_8log_flagIJDpT_EEET0_
23 139 phosphor::certs::validateCertificateAgainstStore(x509_store_st&, x509_st&) call site: 00139 _ZN3lg27detailsL11log_convertITpTkNS0_9log_flagsEJETkNS0_16string_like_typeEPKcEEDaS3_NS0_8log_flagIJDpT_EEERKT0_
18 90 phosphor::certs::parseCert(std::__1::basic_string , std::__1::allocator > const&) call site: 00090 _ZN3lg27detailsL11log_convertITpTkNS0_9log_flagsEJETkNS0_16string_like_typeENSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEEEDaPKcNS0_8log_flagIJDpT_EEERKT0_
15 43 sdbusplus::server::transaction::details::Transaction::Transaction() call site: 00043 sd_journal_send_with_location
10 163 phosphor::certs::validateCertificateAgainstStore(x509_store_st&, x509_st&) call site: 00163 X509_verify_cert_error_string
7 15 lg2::details::value_to_string(unsigned long, unsigned long) call site: 00015 _ZN3lg27detailsorITpTkNS0_9log_flagsEJNS0_11flag_field8EETpTkNS0_9log_flagsEJNS0_12flag_field16EEEEDaNS0_8log_flagIJDpT_EEENS4_IJDpT0_EEE
6 1 LLVMFuzzerTestOneInput call site: 00001
6 35 lg2::details::extra_output_method() call site: 00035
2 128 phosphor::certs::validateCertificateAgainstStore(x509_store_st&, x509_st&) call site: 00128
2 131 phosphor::certs::validateCertificateAgainstStore(x509_store_st&, x509_st&) call site: 00131
1 12 lg2::details::value_to_string(unsigned long, long) call site: 00012
1 23 lg2::details::do_log(lg2::level, std::__1::source_location const&, char const*, ...) call site: 00023

Runtime coverage analysis

Covered functions
28
Functions that are reachable but not covered
155
Reachable functions
188
Percentage of reachable functions covered
17.55%
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/phosphor-certificate-manager/builddir/../fuzzing/parse_cert_fuzzer.cpp 1
/src/phosphor-certificate-manager/builddir/../x509_utils.cpp 5
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2.hpp 15
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/conversion.hpp 18
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/lg2_logger.cpp 6
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/flags.hpp 26
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-logging/lib/include/phosphor-logging/elog-errors.hpp 1
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/log.hpp 9
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/elog.hpp 3
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/server/transaction.cpp 1
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/server/transaction.hpp 1
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-dbus-interfaces/gen/xyz/openbmc_project/Certs/error.hpp 2
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/exception.hpp 4
/usr/local/bin/../include/c++/v1/__exception/exception.h 1
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/header.hpp 1
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-dbus-interfaces/gen/xyz/openbmc_project/Common/error.hpp 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
sdbusplus::error::xyz::openbmc_project::sdbusplus::Error::UnpackPropertyError::set_error(sd_bus_error*)const /src/phosphor-certificate-manager/builddir/subprojects/sdbusplus/include/gen/xyz/openbmc_project/sdbusplus/Error/event.cpp 2 ['N/A', 'N/A'] 19 0 56 9 10 1140 0 4148 4138
sdbusplus::sdbuspp::register_event_helper ::throw_event(nlohmann::json_abi_v3_12_0::basic_json ,std::__1::allocator >,bool,long,unsignedlong,double,std::__1::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::__1::vector >,void>const&,std::__1::source_locationconst&) /src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/sdbuspp_support/event.hpp 2 ['N/A', 'N/A'] 20 0 40 6 6 211 0 536 369
sdbusplus::exception::throw_dbus_error(charconst*,sd_bus_error*,std::__1::source_locationconst&) /src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/exception.cpp 3 ['N/A', 'N/A', 'N/A'] 18 0 203 36 25 304 0 728 191
lg2::details::cerr_extra_output(lg2::level,std::__1::source_locationconst&,std::__1::basic_string ,std::__1::allocator >const&) /src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/lg2_logger.cpp 3 ['int', 'N/A', 'N/A'] 2 0 327 64 58 15 0 93 81
sdbusplus::error::xyz::openbmc_project::sdbusplus::Error::InvalidEnumString::set_error(sd_bus_error*)const /src/phosphor-certificate-manager/builddir/subprojects/sdbusplus/include/gen/xyz/openbmc_project/sdbusplus/Error/event.cpp 2 ['N/A', 'N/A'] 22 0 56 9 10 1140 0 4144 74
sdbusplus::bus_t::new_system() /src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/bus.cpp 1 ['N/A'] 5 0 76 13 13 36 0 76 54
phosphor::certs::loadCert(std::__1::basic_string ,std::__1::allocator >const&) /src/phosphor-certificate-manager/builddir/../x509_utils.cpp 2 ['N/A', 'N/A'] 8 0 161 25 18 87 0 137 40

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

Functions statically reachable by fuzzers
80.0%
872 / 1089
Cyclomatic complexity statically reachable by fuzzers
90.0%
5262 / 5879

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/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/bus.hpp [] []
/src/phosphor-certificate-manager/builddir/../fuzzing/parse_cert_fuzzer.cpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/conversion.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/exception.cpp [] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/server/transaction.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/sdbus.hpp [] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/message.hpp [] []
/src/phosphor-certificate-manager/builddir/../subprojects/nlohmann_json/single_include/nlohmann/json.hpp [] []
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-dbus-interfaces/gen/xyz/openbmc_project/Common/error.hpp ['parse_cert_fuzzer'] []
/usr/local/bin/../include/c++/v1/string [] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/header.hpp ['parse_cert_fuzzer'] []
/usr/local/bin/../include/c++/v1/sstream [] []
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-logging/lib/lg2_eventfilter.cpp [] []
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-dbus-interfaces/gen/xyz/openbmc_project/Certs/error.hpp ['parse_cert_fuzzer'] []
/usr/local/bin/../include/c++/v1/__exception/exception.h ['parse_cert_fuzzer'] []
/usr/local/bin/../include/c++/v1/__iterator/move_iterator.h [] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/exception.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/sdbuspp_support/event.hpp [] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/server/transaction.cpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/subprojects/sdbusplus/include/gen/xyz/openbmc_project/sdbusplus/Error/event.hpp [] []
/usr/local/bin/../include/c++/v1/stdexcept [] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/log.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/subprojects/sdbusplus/include/gen/xyz/openbmc_project/sdbusplus/Error/event.cpp [] []
/usr/local/lib/clang/22/include/cpuid.h [] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/lg2_logger.cpp ['parse_cert_fuzzer'] []
/usr/local/bin/../include/c++/v1/__exception/exception_ptr.h [] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/flags.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/bus.cpp [] []
/src/phosphor-certificate-manager/builddir/../x509_utils.cpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-logging/lib/include/phosphor-logging/elog-errors.hpp ['parse_cert_fuzzer'] []
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/elog.hpp ['parse_cert_fuzzer'] []

Directories in report

Directory
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-logging/lib/include/phosphor-logging/
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-logging/lib/
/usr/local/bin/../include/c++/v1/
/src/phosphor-certificate-manager/builddir/../fuzzing/
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/sdbuspp_support/
/src/phosphor-certificate-manager/builddir/../
/usr/local/bin/../include/c++/v1/__iterator/
/usr/local/lib/clang/22/include/
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/lg2/
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/
/src/phosphor-certificate-manager/builddir/subprojects/sdbusplus/include/gen/xyz/openbmc_project/sdbusplus/Error/
/usr/local/bin/../include/c++/v1/__exception/
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/server/
/src/phosphor-certificate-manager/builddir/../subprojects/nlohmann_json/single_include/nlohmann/
/src/phosphor-certificate-manager/builddir/../subprojects/phosphor-logging/lib/include/phosphor-logging/
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/server/
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/src/
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-dbus-interfaces/gen/xyz/openbmc_project/Common/
/src/phosphor-certificate-manager/builddir/../subprojects/sdbusplus/include/sdbusplus/
/src/phosphor-certificate-manager/builddir/subprojects/phosphor-dbus-interfaces/gen/xyz/openbmc_project/Certs/