Skip to content

security(codecs): cap buffered GELF payload - #26302

Merged
pront merged 7 commits into
masterfrom
pront-gelf-buffered-payload-limit
Sep 9, 2026
Merged

security(codecs): cap buffered GELF payload#26302
pront merged 7 commits into
masterfrom
pront-gelf-buffered-payload-limit

Conversation

@pront

@pront pront commented Sep 3, 2026

Copy link
Copy Markdown
Member

Summary

Motivation

Bounding the number of incomplete messages does not bound their combined payload. Many messages can otherwise retain large chunks until completion or timeout.

Changes

  • Add a hard 128 MiB ceiling for payload buffered across incomplete messages.
  • Let max_length select a lower per-message ceiling without raising the aggregate limit.
  • Account for stored bytes exactly across completion, rejection, errors, and timeout.
  • Release only the blocked message's state when saturation prevents it from advancing.
  • Update generated component documentation and add a security changelog fragment.

References

Related: #26137

Stack: #26299 -> #26300 -> #26301 -> #26302

Vector configuration

Not applicable; accounting is exercised directly at the decoder boundary.

How did you test this PR?

Focused tests exercise accounting across completion, timeout, rejection, and saturation.

Does this PR include user facing changes?

  • Yes. Please add a changelog fragment based on our guidelines.
  • No. A maintainer will apply the no-changelog label to this PR.

Contributor Guidelines

  • Please read our Vector contributor resources.
  • Do not hesitate to use @vectordotdev/vector to reach out to us regarding this PR.
  • Before pushing, follow our pre-push guidance.
  • After a review is requested, please avoid force pushes to help us review incrementally.
    • Feel free to push as many commits as you want. They will be squashed into one before merging.

@pront
pront requested review from a team as code owners September 3, 2026 17:26
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 3, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-09T13:50:36.286413Z 58fe63f New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions github-actions Bot added domain: external docs Anything related to Vector's external, public documentation docs review on hold The documentation team reviews PRs only after a PR is approved by the COSE team. labels Sep 3, 2026
@pront
pront force-pushed the pront-gelf-buffered-payload-limit branch from ca21296 to 2a5af7b Compare September 8, 2026 19:10
@pront
pront force-pushed the pront-gelf-buffered-payload-limit branch from 2a5af7b to deb7098 Compare September 8, 2026 19:13
Base automatically changed from pront-gelf-pending-message-limit to master September 8, 2026 20:34

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 496b7dc11e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread changelog.d/chunked_gelf_buffered_payload_bounded.security.md
@github-actions github-actions Bot removed the docs review on hold The documentation team reviews PRs only after a PR is approved by the COSE team. label Sep 9, 2026
@pront
pront added this pull request to the merge queue Sep 9, 2026

@estherk15 estherk15 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left one optional suggestion, approved for docs!

@@ -0,0 +1,5 @@
The `chunked_gelf` framing decoder now limits the payload buffered across incomplete messages to 128 MiB. An unauthenticated sender could previously exhaust memory by sending chunks for messages it never completed, most easily on the `socket` source in UDP mode.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The `chunked_gelf` framing decoder now limits the payload buffered across incomplete messages to 128 MiB. An unauthenticated sender could previously exhaust memory by sending chunks for messages it never completed, most easily on the `socket` source in UDP mode.
The `chunked_gelf` framing decoder now limits the payload buffered across incomplete messages to 128 MiB. Previously, an unauthenticated sender could exhaust memory by sending chunks for messages it never completed, most easily on the `socket` source in UDP mode.

Merged via the queue into master with commit 72053cc Sep 9, 2026
83 checks passed
@pront
pront deleted the pront-gelf-buffered-payload-limit branch September 9, 2026 14:39
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 9, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

domain: external docs Anything related to Vector's external, public documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants