agent/php/tests/Feature/Brain
Snider 385b89b3eb fix(agent/brain): cap remember()/recall()/forget() input field sizes
Bound input field sizes against memory/DB/Qdrant bloat (DoS-by-self):
- content: 65536 bytes via mb_strlen
- tags: max 100 entries; each tag max 128 chars
- agent_id, type: 64 chars each
- project, org: 128 chars each
- supersedes_id: ULID-shape only

validateRememberInput() throws InvalidArgumentException at every entry
point (remember, recall, forget) before any DB or upstream call. Field-
specific error messages so callers know which field violated.

Pest covers good-path, content-too-long, tags-array-too-large, tag-
length, exact-boundary cases.

Co-authored-by: Codex <noreply@openai.com>
Closes tasks.lthn.sh/view.php?id=1001
2026-04-25 18:58:41 +01:00
..
CircuitBreakerTest.php fix(agent/brain): retryableHttp narrows retryable set + 6-attempt budget 2026-04-25 18:14:40 +01:00
OrgScopingTest.php fix(agent/brain): authorise org against MCP context at every entry point 2026-04-25 18:32:19 +01:00
ReindexFlagsTest.php fix(brain): close openbrain audit gaps — org scoping + index cleanup + reindex flags + MCP schemas + circuit layer 2026-04-24 08:14:06 +01:00
RememberValidationTest.php fix(agent/brain): cap remember()/recall()/forget() input field sizes 2026-04-25 18:58:41 +01:00
SupersedeForgetIndexCleanupTest.php fix(agent/brain): walk supersede chain to current head + cycle guard 2026-04-25 18:42:52 +01:00