Repository navigation
Description
Problem
normalize() in lib/publish-gate.mjs (lines 60-66) folds a few obfuscations and misses others. A credential survives the gate, and fix-ci's leak-scan, which reads the same patterns, when it is written with:
- Unicode compatibility forms, or zero-width characters and soft hyphens inside it (no NFKC, no stripping)
- JSON
\uXXXXescapes (not decoded) - nested tags or entities (folding runs once)
- single backslashes (only doubled ones are folded)
- a line break, or a split across two sources (see fix(publish-gate): match a credential split across a line break #8806)
(Lines moved: normalize is now at :66-73. The leak-scan loads lib/publish-gate.mjs from the default branch, .github/workflows/pr-run-activity-read.yml:1865, so a lib/ change covers it with no .github change.)
Proposal
Extend normalize(): NFKC, strip zero-width characters and soft hyphens, decode \uXXXX, fold tags and entities until the text stops changing, and fold single backslashes. Measure false positives against the tracked tree and the test fixtures before adopting each step.
Out of scope for any pattern scanner: base64, hex and reversed encodings.
Context
Gaps shared by the gate and the fix-ci leak-scan; none blocks fix-ci's move to the launcher. To be weighed in the #8282 review, beside #8806.
Done when
-
normalize()applies NFKC, strips zero-width characters and soft hyphens, decodes\uXXXX, folds tags and entities to a fixpoint, and folds single backslashes. Check: the PR's CI runslib/publish-gate.test.shand it passes. -
lib/publish-gate.test.mjshas one case per new fold that detects an obfuscated credential, each failing before the change. Check: as above. - False positives are measured before each step is adopted, as a committed test: every file in
git ls-filesoutside the test-fixture paths thatfindSecretandfindMachinepass today still passes after the change. A step that adds a hit there is dropped, with the reason in the PR body. Check: as above. -
scripts/sync-shared-copies.shregeneratesplugins/review/lib/publish-gate.mjsandplugins/visualization/lib/publish-gate.mjs(scripts/shared-copies.txt:455-456), with fragments fromscripts/new-changelog-fragment.sh --carriers-of lib/publish-gate.mjs patch. Check: the PR's CI runs the shared-copy sync check andscripts/check-changelog-fragments.sh --check, and both pass. - The line-break fold is fix(publish-gate): match a credential split across a line break #8806, which lands after this or in the same PR. A split across two sources stays open: neither this issue nor fix(publish-gate): match a credential split across a line break #8806 covers it.
- base64, hex and reversed encodings stay out of scope.
Activity
github-actions commentedon Oct 21, 2026
Proposed work class: work-class: scoped
Basis: automated intake triage; the lanes App applied this class.
Size: Medium
Complexity: Medium
Uncertainty: Known
Flags: none
Blocked by: none
#8811 (comment)
This decision settles the open questions. I understood the request as extending
normalize()with NFKC, zero-width and soft-hyphen stripping,\uXXXXdecoding, a fixpoint fold of tags and entities, and single-backslash folding. It also covers the tests, the false-positive measurement and the shared-copy sync. #8806 is related but not a duplicate. I changed the priority from low to medium because this closes a leak gap in the publish gate.Automated triage, applied by the lanes App.
kyle-sexton commentedon Oct 31, 2026
Decision recorded.
The gaps are still on origin/main:
normalize()(lib/publish-gate.mjs:67-73) removes tags once, decodes entities and folds only doubled backslashes. That gate decides what a view may publish (lib/publish-gate.mjs:2-6), so this is a secret-leak gap, not hardening deferred under §10. base64, hex and reversed encodings stay out of scope, and the line-break fold stays with #8806. Agents decided this on evidence under standing direction §1.Done when
normalize()applies NFKC, strips zero-width characters and soft hyphens, decodes\uXXXX, folds tags and entities to a fixpoint, and folds single backslashes. Check: the PR's CI runslib/publish-gate.test.shand it passes.lib/publish-gate.test.mjshas one case per new fold that detects an obfuscated credential, each failing before the change. Check: as above.git ls-filesoutside the test-fixture paths thatfindSecretandfindMachinepass today still passes after the change. A step that adds a hit there is dropped, with the reason in the PR body. Check: as above.scripts/sync-shared-copies.shregeneratesplugins/review/lib/publish-gate.mjsandplugins/visualization/lib/publish-gate.mjs, with fragments fromscripts/new-changelog-fragment.sh --carriers-of lib/publish-gate.mjs patch. Check: the PR's CI runs the shared-copy sync check andscripts/check-changelog-fragments.sh --check, and both pass.github-actions commentedon Oct 31, 2026
github-actions commentedon Oct 31, 2026
melodic-automation-lanes commentedon Oct 31, 2026
The work-resolve-issue lane stopped on this issue (
patch-apply-failed): apply-issue-patch failed before it committed or refused the patch, a job fault.It keeps
agent-ready, and work-unblock starts it again (retry 1 of 2).In the run's words:
Run: https://github.com/melodic-software/claude-code-plugins/actions/runs/41186170380
github-actions commentedon Oct 31, 2026
github-actions commentedon Oct 31, 2026