Files
codex/codex-rs/agent-message-board-client/tests
jif 782826663d Bound agent message board SSE frames before parsing (#48190)
## Why

Checking notification data size after SSE parsing leaves oversized fields and unterminated frames free to accumulate in the parser. Malformed UTF-8 can also be retained indefinitely by the decoder.

## What changed

Enforce `MAX_BODY` on incoming frame bytes before SSE parsing and reject malformed UTF-8 incrementally. Reset the byte count at blank lines, supporting LF, CR, and CRLF across chunks, so the limit applies per frame rather than per connection. Stop reading the source stream after an error.

## Testing

Extend the remote board contract test to cover oversized readiness fields, unterminated fields, and multiline data frames. Verify that a long sequence of heartbeat frames with all three line endings still permits notification delivery.

GitOrigin-RevId: c3a95ead88f53e7acfb28c5ba23141bc11d25532
2026-09-25 19:48:25 +00:00
..