Skip to content

fix(context): strip controls from provenance pointers#350

Closed
SUaDtL wants to merge 2 commits into
mainfrom
fix/provenance-pointer-controls
Closed

fix(context): strip controls from provenance pointers#350
SUaDtL wants to merge 2 commits into
mainfrom
fix/provenance-pointer-controls

Conversation

@SUaDtL

@SUaDtL SUaDtL commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • strip control, formatting, and line-separator characters from provenance document names, claim text, and line ranges before tier-4 context assembly
  • suppress records whose document key becomes empty after sanitization
  • keep canonical core and both shipped host copies byte-identical
  • close task v2.harden.0002

Security posture

The sanitizer removes Unicode categories Cc, Cf, Zl, and Zp before pointer construction and before the 150-token budget is applied. Malformed values fail silent. Reviewers found an adjacent document-key path during the first pass; that path is covered by the same sanitizer in the final diff. Security, architecture, and coverage re-reviews report no remaining findings.

Verification

  • 15 repository script suites passed
  • 967 hook tests passed
  • 192 read-injection tests passed
  • sync-core --check passed for 42 core files across both plugin copies
  • Python syntax checks passed for all three touched runtime copies
  • plugin reference graph passed
  • staged whitespace and secret scans passed

SUaDtL added 2 commits July 20, 2026 03:54
Record the SMARTS selection and audited task start before the implementation commit. This preserves the task board's required queued-to-in-progress transition.
Sanitize document names, claim text, and line ranges before assembling freshness-gated additional context. Suppress provenance records whose document key becomes empty after sanitization.

CHANGELOG: Harden provenance context pointers against control-character restructuring.
@SUaDtL

SUaDtL commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator Author

Superseded by #313, the single hackathon review surface. This PR's recorded head and changes are represented in #313's exact 16-PR / 29-commit / 126-path source manifest. PR #313 passed final exact-head CI at commit 6173b1d and remains open and unmerged. Closing this source PR to avoid parallel review; please continue review and discussion on #313.

@SUaDtL SUaDtL closed this Jul 20, 2026
@SUaDtL
SUaDtL deleted the fix/provenance-pointer-controls branch July 24, 2026 21:08
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