1
0
Fork 0
llm-ingestion-pipeline-secu.../tests
Kjell Tore Guttormsen 2466d260d3 test(redos): the dead row had the wrong payload, and the last wall clock is retired
Both rows that could not go red are decided, each by measurement.

test_lexicon.py::test_redos_pathological_subagent_input_returns_fast is REVIVED,
not retired. The row was not dead because the seed form is safe -- it was dead
because both earlier payloads made the prefix match at ONE start position, and
the cost is per-prefix-match. Repeating `spawn an agent that ` instead makes it
match K times, each driving its own O(N) lazy scan for a keyword never supplied:
K x O(N) against the seed's `(?:.*?\s+)?`, K x O(1) against the shipped
`{0,12}?` bound. Measured through scan_lexicon at 1500/3000/6000/12000 words:
seed 0.091/0.283/1.085/4.091s (exponent 1.92), shipped 0.047/0.051/0.094/0.190s
(exponent 1.01). Verified red with the seed form patched in: 4.21s against the
2.0s bound. The nesting the old comment blamed was a red herring.

test_output.py::test_pathological_input_returns_within_a_bound moves to CPU time
with a 20.0s bound, and the "or a hang" half of its claim is retired. The wall
clock was kept because a blocking hang burns no CPU -- true in general, and
inapplicable to a path with no open(), socket, subprocess, thread, lock or sleep
anywhere on it. Same payload, idle vs ~4x oversubscription: wall 3.30 -> 21.63s
(2x over the old 10.0s bound), cpu 3.30 -> 7.62s. It guarded a mode it could not
have while paying the full false-red premium. No in-repo vulnerable form can
turn this row red, so the bound was proved live against what it actually guards
-- a future pattern quadratic on long runs, `A+\s*EXFILTRATE` -- which failed it
at 64.77s CPU, 3.2x over.

redos_clock.py and the clock's pin test both documented this row as the
deliberate wall-clock holdout; both corrected.

792 passed, 6/6 documented gaps hold.
2026-08-13 21:47:43 +02:00
..
inbox_frontend.py feat(okf): scan reserved index.md/log.md in mode-b import, not path-reject (review MAJOR #2) 2026-07-15 06:43:50 +02:00
redos_clock.py test(redos): the dead row had the wrong payload, and the last wall clock is retired 2026-08-13 21:47:43 +02:00
test_active_content.py test(redos): one CPU clock for every bound, and a second row measured dead 2026-08-13 21:25:36 +02:00
test_calibration.py feat(active-content): raw HTML graded on carrier, and a tag naming no target is inert 2026-08-12 00:42:44 +02:00
test_contract.py fix(security): harden 5 adversarial-review findings (M1/M2/M3 + m4/m6) via TDD 2026-07-05 10:45:05 +02:00
test_corpus.py measure(fp): the upload door costs a human on 16-53% of benign documents 2026-08-10 21:32:56 +02:00
test_coverage_matrix.py test(coverage): runnable threat-coverage matrix (real-case validation gate) 2026-07-15 11:20:22 +02:00
test_disposition.py docs(plan): kill the pointer that sent this session to the wrong section 2026-08-10 21:01:19 +02:00
test_docs_measurement_scripts.py feat(active-content): raw HTML graded on carrier, and a tag naming no target is inert 2026-08-12 00:42:44 +02:00
test_entropy.py fix(security): harden 5 adversarial-review findings (M1/M2/M3 + m4/m6) via TDD 2026-07-05 10:45:05 +02:00
test_fence.py feat(fence): randomized unspoofable delimiter + attacker marker-strip (TDD) [skip-docs] 2026-07-04 18:23:35 +02:00
test_grounding.py feat(grounding): SourceGroundingCheck protocol + pass-through default — the semantic-poisoning seam (TDD) [skip-docs] 2026-07-04 22:44:41 +02:00
test_input_cap.py docs(readme,limitations): stop advertising a version that was not chosen 2026-08-02 21:21:21 +02:00
test_lexicon.py test(redos): the dead row had the wrong payload, and the last wall clock is retired 2026-08-13 21:47:43 +02:00
test_neutralize.py test(redos): one CPU clock for every bound, and a second row measured dead 2026-08-13 21:25:36 +02:00
test_okf.py test(redos): one CPU clock for every bound, and a second row measured dead 2026-08-13 21:25:36 +02:00
test_okf_inbox_uploads.py feat(inbox): .xlsx extraction — formula gate, hidden sheets, cell comments (stage 2h) 2026-07-07 07:41:00 +02:00
test_okf_showcase.py feat(okf): scan reserved index.md/log.md in mode-b import, not path-reject (review MAJOR #2) 2026-07-15 06:43:50 +02:00
test_output.py test(redos): the dead row had the wrong payload, and the last wall clock is retired 2026-08-13 21:47:43 +02:00
test_report.py feat: scaffold package + report and sanitize modules (TDD) 2026-07-04 09:24:20 +02:00
test_sanitize.py test(redos): one CPU clock for every bound, and a second row measured dead 2026-08-13 21:25:36 +02:00
test_showcase.py feat(guard): active-content detector wired into the output gate (review MAJOR #1) 2026-07-15 06:11:33 +02:00
test_url_shape_doc.py docs(url-shape): make the rule reconstructable, and record what three corpora measured 2026-07-27 08:56:24 +02:00
test_wiring.py feat(active-content): raw HTML graded on carrier, and a tag naming no target is inert 2026-08-12 00:42:44 +02:00