Skip to content

Validate the channel before assembling content frames - #128

Merged
flamble merged 1 commit into
bloomberg:mainfrom
flamble:validate-channel
Dec 3, 2026
Merged

flamble merged 1 commit into
bloomberg:mainfrom
flamble:validate-channel

Conversation

@flamble

@flamble flamble commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

Problem statement

Connection::processNextFrame handed every frame to the Framer before looking at the channel.

Proposed changes

Check the channel first and reject frames for an id with no open channel.

Channel 0 only carries connection methods and heartbeats, so reject any other frame type there rather than exempting the whole channel.

Once a Connection.Close is in flight the broker keeps sending, so discard any further rejected frames rather than closing a second time.

`Connection::processNextFrame` handed every frame to the `Framer`
before looking at the channel.

Check the channel first and reject frames for an id with no open
channel.

Channel 0 only carries connection methods and heartbeats, so reject
any other frame type there rather than exempting the whole channel.

Once a `Connection.Close` is in flight the broker keeps sending, so
discard any further rejected frames rather than closing a second time.
@flamble
flamble marked this pull request as draft December 2, 2026 19:31
@flamble
flamble marked this pull request as ready for review December 2, 2026 19:31
@flamble
flamble marked this pull request as draft December 3, 2026 05:33
@flamble
flamble marked this pull request as ready for review December 3, 2026 05:33
@flamble flamble closed this Dec 3, 2026
@flamble flamble reopened this Dec 3, 2026
@flamble
flamble merged commit a445058 into bloomberg:main Dec 3, 2026
6 checks passed
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.

2 participants