Security context

What an agent needs to avoid regressing past fixes and find the next vuln in this repo.

nginx/njs
master @ 3e02ae0
6
Fixes
0
CVEs
HIGH
Peak severity
50.0%
Coverage
Highlights
Heap Buffer Overflow: 4 prior fixes. Scrutinize any change in this area.
njs/njs_string.c: most-fixed (2 issues). Treat as high-risk during review.
5 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns

The bug types that recur here, drawn from past fixes, not open vulnerabilities.

Heap Buffer Overflow: Two separate overflows in string primitives (lastIndexOf, replace) stem from missing bounds clamping and loop-condition errors, indicating a systemic weakness in string length handling.
Heap Buffer Overflow: RegExp.prototype.source overflow arises from mismatched allocation vs. escape length when NUL bytes are present, showing a pattern of incorrect size accounting in generated strings.
Heap Buffer Overflow: Hash collision between strings and symbols leads to out-of-bounds atom_id reads; the fix partitions key_hash space, indicating a fundamental design flaw in the atom table.