# NousResearch/hermes-agent · ANSI CSI sequence stripping in redaction masking

## Open now

- 1 issue, 1 PR open on GitHub.
- #81012: redact: complete CSI/SGR sequences defeat prefix masking (ESC-byte-only stripping leaves 'm'-glue)
- PR #81121: fix(redact): strip complete ANSI CSI sequences before control-split masking

These issues and pull requests address a bug where incomplete ANSI CSI/SGR escape sequence stripping allows terminal control characters to defeat prefix and token-split masking in the redact logic. Multiple fix approaches target different masking code paths affected by the same underlying problem.

## TL;DR

- 6 member(s): 1 open issue(s), 0 closed issue(s), 1 open PR(s), 0 merged PR(s), 4 PR(s) closed without merging.
- No fix has been merged to main; one or more PRs were attempted (see below).
- **Recommended:** review the prior/competing PR(s) below. A fix was attempted but not merged; your case may extend or revive that work.

## Maintainer resolution verdict

- Internal-tracker verdict over this cluster's issue members: `unresolved`. This is distinct from the fix status above. Weigh it yourself.

## How this cluster was grouped

- Link evidence (`STRUCTURAL_SPANNING`): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
- Pairwise link density `0.33`: the share of member pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36. `1.00` means every pair is linked.

## Open related issues

- #81012: redact: complete CSI/SGR sequences defeat prefix masking (ESC-byte-only stripping leaves 'm'-glue)

## Prior & competing PRs

- **#81060: fix(redact): strip complete CSI/SGR sequences in token-split shadow (#81012)**. closed without merge
  - maintainer direction: category `partial_fix`; implication `needs_llm`; refs `#81121`, `#81012`
- **#81062: fix(redact): strip complete CSI sequences before prefix masking (#81012)**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#81060`
- **#81079: fix(redact): strip complete CSI/SGR sequences from shadow copy (#81012)**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#81060`
- **#81083: fix(redact): strip complete CSI sequences before prefix-mask scan**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#81060`
- **#81121: fix(redact): strip complete ANSI CSI sequences before control-split masking**. open
  - maintainer direction: category `implemented_elsewhere`; implication `superseded`; refs `bcdd84af31cc6638c232fa96e3bb9c733e79386e`, `4621a2d699daeaa92efb93dae9db076308cbe823`, `aaaaabbbbbcccccccccc`, `#77484`, `#81012`
  - files: `agent/redact.py`, `contributors/emails/[redacted:email]`, `tests/agent/test_redact.py`

## Fix status

- No merged fix on record.
- Subsystem: `agent`
