Skip to content

Limit WebSocket and gRPC request bodies#711

Merged
ryanfowler merged 1 commit into
mainfrom
unbounded-req-body
Jun 4, 2026
Merged

Limit WebSocket and gRPC request bodies#711
ryanfowler merged 1 commit into
mainfrom
unbounded-req-body

Conversation

@ryanfowler

Copy link
Copy Markdown
Owner

Summary

  • Add a bounded request-body materializer and use it for WebSocket initial messages and unary/raw gRPC request bodies.
  • Prevent oversized -d @file or stdin inputs from being fully loaded into memory before existing protocol limits are enforced.
  • Add regression tests for oversized file inputs on both paths.

Testing

  • cargo fmt
  • cargo clippy --locked --all-targets --all-features -- -D warnings
  • cargo test --all-features rejects_oversized_file_before_reading
  • cargo test --all-features --lib

@ryanfowler ryanfowler enabled auto-merge June 4, 2026 13:07
@ryanfowler ryanfowler merged commit 228ebec into main Jun 4, 2026
4 checks passed
@ryanfowler ryanfowler deleted the unbounded-req-body branch June 4, 2026 13:11
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.

1 participant