fix(security-cve-allocate): strip ID parentheticals anywhere in the title - #1126
Merged
potiuk merged 1 commit intoAug 29, 2026
Merged
Conversation
…itle
The Step 2 title-strip cascade anchored every identifier parenthetical
to end-of-string with `$`. A title carrying one mid-string kept it, and
the cascade reported no change — so the parenthetical shipped verbatim
into `containers.cna.title` on the published CVE record.
Path traversal (incomplete fix for CVE-2026-12345) in the parser
Nothing in the rationale for stripping these depends on position. A
prior-CVE reference belongs in the public summary's cross-CVE clause, a
GHSA/ZDRES/HUNTR/GHSL ID belongs in the credits or the issue body, and a
`split from #N` marker belongs in the tracker — none of them belong in
the title, wherever they sit in the string.
Splits the cascade into `patterns_anywhere` (the four identifier-bearing
parentheticals, unanchored) and `patterns_trailing` (the genuinely
position-dependent ones). The existing whitespace collapse at the end of
the cascade closes the gap a mid-string removal leaves behind.
Over-stripping risk stays low because each unanchored pattern requires a
well-formed tracker ID inside the parentheses. The reporter
`(<name> follow-up)` paren stays end-anchored on purpose: its name part
is loose enough that stripping it mid-title could eat a real clause.
Updates the `title-normalization.md` template in lock-step, which was
also missing the prior-CVE pattern entirely, and corrects the
`security-issue-sync` row that described these as trailing-only.
Generated-by: Claude Code (Claude Opus 5)
potiuk
force-pushed
the
fix/title-strip-unanchor-cve-parenthetical
branch
from
August 29, 2026 19:20
dd8e1e1 to
964514e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The Step 2 title-strip cascade anchors every identifier parenthetical to end-of-string with
$. A title carrying one mid-string keeps it — and the cascade reports no change, so the parenthetical ships verbatim intocontainers.cna.titleon the published CVE record:Splits the cascade into
patterns_anywhere(the four identifier-bearing parentheticals — GHSA, ZDRES/HUNTR/GHSL,split from #N, prior-CVE — now unanchored) andpatterns_trailing(the genuinely position-dependent ones).Motivation
Nothing in the rationale for stripping these depends on position. A prior-CVE reference belongs in the public summary's cross-CVE clause; a tracker ID belongs in the credits or issue body; a
split from #Nmarker belongs in the tracker. None belong in the title, wherever they sit.The failure mode is quiet, which is what makes it worth fixing: a
changed=nofrom the cascade currently reads as "the title is clean", and a downstream adopter hit exactly that — a mid-title prior-CVE parenthetical that only surfaced in a manual review after allocation.Design notes
(<name> follow-up)paren stays end-anchored on purpose — its name part is loose enough that stripping it mid-title could eat a substantive clause.re.sub(r"\s+", " ", t)collapse already closes the gap a mid-string removal leaves behind; no new whitespace handling needed.title-normalization.mdtemplate is updated in lock-step. It was also missing the prior-CVE pattern entirely, so that is added.Test plan
Ran the reworked cascade against 10 title shapes — 10/10 pass:
(incomplete fix for CVE-…),(GHSA-…),(ZDRES-…),(split from #N)— all now strippedRace condition (Evan Ricafort follow-up) in the scheduler— deliberately not strippedImproper validation of the (optional) callback parameter— not stripped (no over-strip)prek run --filespasses on all three files, includingmarkdownlint,check-placeholders,skill-and-tool-validate, and the in-hook lychee.🤖 Generated with Claude Code