Skip to content

Reporting

simondotsh edited this page Oct 27, 2021 · 1 revision

Where Are My Results?

The results directory at the root of the project contains the results separated in directories matching the timestamp at which the tool has run. These will contain HTML and JSON files.

HTML Files

The reports follow the $module_name.html pattern (e.g. users.html), and present results of all targets for that module.

JSON Files

The json directory contains a file per module executed. These will contain all the results and are used to generate the reports.

Help! The HTML Report Does Not Load or Is Too Slow!

Unfortunately, you have encountered the limitation of static files. This tool preaches simplicity and lightweightness, and solving this problem goes against both principles. Indeed, a web server and a SQL-like engine to query the results may be the only reasonable solution, but is currently not supported.

Consider running the tool against a smaller scope to reduce the files' size.

Fixing Broken Reports

If the execution is stopped mid-module, the JSON array is most-likely not be closed properly, but is easily fixable by adding ] at the end of the file.

In order to proceed with the HTML generation, one would have to slightly modify the code to ingest the fixed file.

Design

The chosen design is to write results immediately to a JSON file when a target has been completed. This avoids the potential issues of having too many results in memory, and results not being written if an unhandled exception occurs.

Are You Using JSON as a Database?

Well, yes; however this can be justified and is certainly not to please the avid Excel-as-a-database offenders.

JSON offers the flexibility to power users to easily grep or jq data when looking to answer specific questions, while remaining simple. A SQL Engine à la SQLite usually requires a strong understanding of the schema to achieve similar results, but would be better at resolving complex interrogations.

A further version may consider the use of SQLite but is currently not planned, and does not single-handedly solve the issue of large static files.