-
Notifications
You must be signed in to change notification settings - Fork 10
fix: increase max HTTP header size to 32kb bytes across all environments #719
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR increases the maximum HTTP header size supported by bright-cli from the default 16 KB to 32 KB to align with the Bright repeater infrastructure. This prevents HPE_HEADER_OVERFLOW errors when the target responds with HTTP headers between 16-32 KB.
Changes:
- Added NODE_OPTIONS environment variable configuration across all execution environments
- Updated test scripts to support larger HTTP headers during testing
- Modified build configuration to embed the setting in packaged executables
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| package.json | Updated npm scripts (test:e2e, test:smoke, start) to set NODE_OPTIONS=--max-http-header-size=32768 and modified build:pkg to pass the same option to pkg |
| Dockerfile | Added NODE_OPTIONS environment variable to set max-http-header-size=32768 for containerized deployments |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
While there is no e2e test for this case, I've tested locally: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
At the moment, bright-cli fails when the target responds with an HTTP header block larger than 16 KB, which is the default limit enforced by Node.js.
The Bright repeater infrastructure is already capable of handling HTTP response headers up to 32 KB, which creates a mismatch between the repeater and bright-cli behavior. To keep both components aligned and allow bright-cli to process responses normally, the maximum supported HTTP header size should be increased to 32 KB.
If response headers exceed this increased limit, bright-cli will continue to throw HPE_HEADER_OVERFLOW, which matches the current and expected behavior.