Skip to content

test(hub): best-of-5 samples for the M7 postExtractHtml ReDoS budgets - #158

Merged
bartrumb merged 1 commit into
mainfrom
fix/m7-timing-best-of
Nov 29, 2026
Merged

bartrumb merged 1 commit into
mainfrom
fix/m7-timing-best-of

Conversation

@bartrumb

Copy link
Copy Markdown
Owner

The M7 Challenger Iteration 2 hub test timed each hostile postExtractHtml call once against an unscaled 5ms budget, while other test files were using the runner's CPUs. On the v2.8.33 release PR (#157), which only changes version strings and the changelog, one sample took 9.75ms.

These checks now use assertFastUnscaledSync, the shared helper behind the other unscaled budgets: the budget stays at 5ms, and the test takes the best of up to 5 samples. The WAF checks in the same test already took the best of 5. A super-linear scan still fails every sample.

Test plan

  • Hub type-check and full hub suite (409 core + 38 security-audit tests) pass locally.

🤖 Generated with Claude Code

The M7 Challenger Iteration 2 test timed each hostile postExtractHtml call
once against an unscaled 5ms budget while other test files shared the
runner's CPUs. On the v2.8.33 release PR, whose diff is only version strings
and the changelog, one sample took 9.75ms.

These checks now use assertFastUnscaledSync, the shared helper the other
unscaled budgets use: same 5ms budget, best of up to 5 samples. The WAF
checks in the same test already took the best of 5. A super-linear scan
still fails every sample.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Brett Bartrum <17114576+bartrumb@users.noreply.github.com>
@bartrumb
bartrumb merged commit 92f4519 into main Nov 29, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant