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

Fuzzer details

Fuzzer: fuzz_jwt

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 27 17.3%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 129 82.6%
All colors 156 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
15 85 flask.sansio.scaffold.Scaffold._get_exc_class_and_code call site: 00085 flask.sansio.scaffold.Scaffold.errorhandler.decorator
3 9 ...fuzz_jwt.test_get call site: 00009 flask.sansio.scaffold.Scaffold.route.decorator
2 130 flask.testing.EnvironBuilder.__init__ call site: 00130 app_root.lstrip
1 3 ...fuzz_jwt.TestOneInput call site: 00003 flask.sansio.scaffold.Scaffold.route.decorator
1 15 flask.app.Flask.__init__ call site: 00015 .bool
1 31 flask_jwt_extended.jwt_manager.JWTManager.init_app call site: 00031 flask.sansio.scaffold.Scaffold.context_processor
1 34 flask_jwt_extended.jwt_manager.JWTManager._set_default_configuration_options call site: 00034 datetime.timedelta
1 78 flask_jwt_extended.jwt_manager.JWTManager.init_app call site: 00078 flask.sansio.scaffold.Scaffold.errorhandler.decorator
1 123 flask.testing.FlaskClient.__init__ call site: 00123 flask.testing._get_werkzeug_version
1 127 flask.app.Flask.test_request_context call site: 00127 .bool

Runtime coverage analysis

Covered functions
251
Functions that are reachable but not covered
38
Reachable functions
62
Percentage of reachable functions covered
38.71%
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
/ 1
...fuzz_jwt 18
flask.sansio.scaffold 6
flask_jwt_extended.view_decorators 1
flask.app 10
flask.sansio.app 8
flask_jwt_extended.jwt_manager 9
flask.testing 9
flask.ctx 2
flask_jwt_extended.utils 3

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
flask.app.Flask.wsgi_app flask.app 3 ['N/A', 'N/A', 'N/A'] 6 0 5 2 4 60 1 206 179
flask.sansio.app.App.__init__ flask.sansio.app 11 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A'] 5 0 2 2 4 31 0 101 95
jwt.jwks_client.PyJWKClient.get_signing_key jwt.jwks_client 2 ['N/A', 'N/A'] 5 0 0 2 4 24 1 84 78
flask.sansio.blueprints.Blueprint.register flask.sansio.blueprints 3 ['N/A', 'N/A', 'N/A'] 3 0 8 14 9 24 0 84 75
jwt.api_jwt.PyJWT.decode_complete jwt.api_jwt 11 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A'] 3 0 9 4 5 22 2 80 65
flask.cli.ScriptInfo.load_app flask.cli 1 ['N/A'] 4 0 1 6 5 29 0 99 63
flask_jwt_extended.view_decorators.verify_jwt_in_request flask_jwt_extended.view_decorators 6 ['N/A', 'N/A', 'N/A', 'N/A', 'N/A', 'N/A'] 3 0 1 2 4 22 2 77 59
flask.cli.routes_command flask.cli 2 ['N/A', 'N/A'] 1 0 13 3 4 19 1 61 52
jwt.algorithms.RSAAlgorithm.from_jwk jwt.algorithms 1 ['N/A'] 4 0 0 8 6 20 0 67 49
flask.sessions.SecureCookieSessionInterface.save_session flask.sessions 4 ['N/A', 'N/A', 'N/A', 'N/A'] 2 0 5 4 5 16 0 53 47

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

Functions statically reachable by fuzzers
20.0%
113 / 568
Cyclomatic complexity statically reachable by fuzzers
22.0%
424 / 1911

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
[] []
click [] []
jwt.utils [] []
operator [] []
flask.testing ['fuzz_jwt'] []
typing [] []
code [] []
warnings [] []
flask.sansio.blueprints [] []
base64 [] []
flask_jwt_extended.config [] []
flask [] []
inspect [] []
calendar [] []
copy [] []
contextvars [] []
urllib [] []
flask.json.tag [] []
flask.config [] []
flask.sessions [] []
jwt.warnings [] []
jwt.exceptions [] []
flask.json.provider [] []
jwt.types [] []
flask.sansio.scaffold ['fuzz_jwt'] []
flask_jwt_extended.tokens [] []
datetime [] []
flask.views [] []
cryptography [] []
...fuzz_jwt ['fuzz_jwt'] []
flask_jwt_extended.view_decorators ['fuzz_jwt'] []
platform [] []
importlib_metadata [] []
ast [] []
flask_jwt_extended [] []
os [] []
flask.cli [] []
flask.blueprints [] []
contextlib [] []
markupsafe [] []
itsdangerous [] []
flask.wrappers [] []
asgiref [] []
atheris [] []
flask_jwt_extended.typing [] []
uuid [] []
jwt.help [] []
blinker [] []
sys [] []
dotenv [] []
importlib [] []
jwt.api_jws [] []
flask.signals [] []
jwt.jwks_client [] []
re [] []
flask.__main__ [] []
rlcompleter [] []
flask.logging [] []
weakref [] []
jwt.jwk_set_cache [] []
json [] []
flask_jwt_extended.jwt_manager ['fuzz_jwt'] []
jinja2 [] []
binascii [] []
functools [] []
hmac [] []
flask.templating [] []
jwt.api_jwt [] []
flask_jwt_extended.exceptions [] []
dataclasses [] []
types [] []
flask.app ['fuzz_jwt'] []
flask.helpers [] []
flask_jwt_extended.utils ['fuzz_jwt'] []
jwt.algorithms [] []
collections [] []
jwt [] []
flask.globals [] []
flask.ctx ['fuzz_jwt'] []
flask.debughelpers [] []
werkzeug [] []
logging [] []
[] []
flask.json [] []
flask_jwt_extended.internal_utils [] []
flask_jwt_extended.default_callbacks [] []
traceback [] []
flask.sansio.app ['fuzz_jwt'] []
time [] []
jwt.api_jwk [] []
pathlib [] []
itertools [] []
flask.typing [] []
readline [] []

Directories in report

Directory