The report that survives being handed over
A security finding is easy to produce and hard to defend. I got tired of the moment three months later when somebody asks which version of the file was scanned, and all we have is a screenshot with a line number. So I b
A security finding is easy to produce and hard to defend. I got tired of the moment three months later when somebody asks which version of the file was scanned, and all we have is a screenshot with a line number.
So I built the opposite of a dashboard. injection-audit runs locally, reads Python and shell files, and writes one JSON file that carries its own evidence.
Here is what a real run produced on two deliberately broken files:
report : IA-20261123T000000Z-904ad9a57c9d
delivered : 2026-11-23
repo digest : 904ad9a57c9d7b5c3405da8e8c939257b63d200a44722f9ccd7e6e43a291f8d0
analysed : 2 files
findings : 2
Both findings were CWE-78: an os.system("grep -n " + sys.argv[1]) in Python and an eval "echo $name" in a shell script. Nothing clever about the bugs. The interesting part is what ships with them.
The design decision that mattered
A scanner is a commodity. Every check in mine exists in a dozen open-source tools. What nobody seems to ship is a report you can verify without trusting the person who wrote it.
So the artefact contains:
- a numbered finding (
F-0001,F-0002) bound to a rule id and a CWE class; - the quoted source line and its
file:linelocation; - a SHA-256 hash for every file analysed, plus a digest over the whole tree;
- an explicit coverage block saying what was skipped and why;
- an HMAC-SHA256 signature over the canonical JSON payload.
The signing key stays on the machine that made the report. The report records only the SHA-256 id of that key. A client can check the document was not edited after signing, and that the file hashes still match what was analysed, without installing my tool and without seeing my source.
$ python -m injection_audit verify report.json --key-file ia.key
signature valid for key sha256:da466a4a6b0fa977df6e3ed163f034167900ac97b85fe3f4d834f4531337ef1d
Exit code 0. That is the whole promise: a verifiable file, not a badge.
Reproducibility was the unglamorous win
Pin the clock with --now 2026-11-23T00:00:00+00:00 and two scans of the same tree are byte-identical. That sounds small until a client asks for a re-issued copy of a report from last quarter and you cannot recreate it. Now I can.
What it will not do
I put the limits in the report itself, because a tool that hides its blind spots is worse than no tool:
- taint tracking is intra-file and intra-function;
- an argv token is only reported as CWE-88 when the hazard is provable from literals;
- unsupported languages, parse failures and oversized files are listed as skipped, never silently dropped;
- this is not a compliance certificate, a penetration test, or a guarantee.
That last line costs me sales. I keep it anyway. I would rather lose a sale than sell a badge that falls apart when somebody reads the fine print.
Where it is now
The engine covers Python (ast-based) and POSIX shell (a quote-aware tokeniser), with 290 tests passing and no third-party dependencies. It is deliberately boring to install: Python 3.9+, no network calls, no account.
The written-up field note, with the sample report and the honest limits, is here: the report that survives being handed over. The code is at github.com/derbaroser-eng/injection-audit.
If you have ever had a finding disputed after the fact, you already know why I built it.
Originally published by Dev.to Security. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.