Repository navigation
Egress: a name's single words count only capitalised, in capitals or spread out - #149
Conversation
…spread out A name token read alone at egress matched any lowercase occurrence of the word, so a visitor named Test User turned 'this is a test' in their own message into a refusal, and a one-word name was a separator-blind needle that found 'grant' in 'fragrant'. Name-token forms now count only when the occurrence is spread out or starts with a capital, and a one-word name is no longer a folded needle. Found by the first real Unscathed Desk inquiry in report-only.
sprayberry-redline
left a comment
There was a problem hiding this comment.
Verdict: request changes. The egress matcher separates case-sensitive name-token handling as intended, but the release note was added inside the changelog's existing HTML comment and will not appear in the published changelog.
1. Blocking: CHANGELOG.md:12
- Egress: a declared name's single words are no longer found in ordinary lowercase text. A word read alone counts only when it is capitalised, in capitals or spread out ("Test", "TEST", "t e s t"), so a visitor named Test User or Grant does not turn "this is a test" or "grant access" into a refusal. A one-word name is no longer a separator-blind needle either ("fragrant" held "grant"). Full names, email addresses, phone numbers and the other forms are read as before.
This entry is between the opening <!-- and closing --> of the release-convention comment. Consequently it is hidden from rendered changelog readers and release notes produced from this file do not document the behavior change.
Suggested fix:
Move the Fixed section and this entry below `## [Unreleased]`, outside the HTML comment.
rule:none
…convention comment
sprayberry-redline
left a comment
There was a problem hiding this comment.
Verdict: approve. The egress matcher now separates standalone name tokens from folded needles and accepts those tokens only when capitalized or separated, while retaining the existing full-name and identifier checks. The regression coverage exercises lowercase ordinary text, capitalized and separated tokens, one-token names, and the reported redaction path.
Found by the first real report-only traffic: the Unscathed Desk's turns for a test inquiry were marked would-refuse. A replay with the site's real inquiry layout reproduces it for a visitor named "Test User". The visitor's own message, "this is a test of the contact form", tripped the egress check on the lowercase word "test".
Cause
A declared name's single words are read alone at egress, word-bounded with any separators, to catch a spread-out name ("Z o r a"). That reading matched every lowercase occurrence of the word too. Detection only replaces the capitalised word, so an ordinary lowercase "test", "user" or "grant" stayed in the body and egress called it the name. A one-word name was also a separator-blind folded needle, so "grant" was found inside "fragrant".
Change
spreadRes.pattern.Tests
New regressions:
Five earlier tests relied on a lowercase word counting as the name. Each now uses a declared literal or the capitalised word, so it still tests what it meant to: that the field is read.