Skip to content

Fix 502 crash when sent malformed X-Forwarded-For header#315

Merged
jezen merged 2 commits intosnoyberg:masterfrom
jezen:fix-312
Aug 12, 2025
Merged

Fix 502 crash when sent malformed X-Forwarded-For header#315
jezen merged 2 commits intosnoyberg:masterfrom
jezen:fix-312

Conversation

@jezen
Copy link
Copy Markdown
Collaborator

@jezen jezen commented Aug 12, 2025

The commits in this PR will first accurately reproduce, and then resolve, the issue described in #312.


This PR also cleans up the pre-commit hooks configuration since they were [disappointingly] removed.

@jezen jezen marked this pull request as draft August 12, 2025 09:15
This test reproduces snoyberg#312.
@jezen
Copy link
Copy Markdown
Collaborator Author

jezen commented Aug 12, 2025

The output of this test run contains this line, as expected.

vm-test-run-vm-test-ip-from-header> (finished: waiting for success: curl -fsS http://localhost/ | grep 'Hello, world!', in 2.36 seconds)
vm-test-run-vm-test-ip-from-header> server: must succeed: /etc/send-request.sh
vm-test-run-vm-test-ip-from-header> server # curl: (22) The requested URL returned error: 502

@jezen jezen marked this pull request as ready for review August 12, 2025 10:19
@jezen
Copy link
Copy Markdown
Collaborator Author

jezen commented Aug 12, 2025

@ulidtko FYI.

@jezen
Copy link
Copy Markdown
Collaborator Author

jezen commented Aug 12, 2025

This is now building successfully. The macOS-latest builds remained queued, but I think this is an internal GitHub Actions problem, and I think this package actually builds just fine on MacOS. So, I think it's fine to merge this.

@jezen jezen merged commit 5bb2c10 into snoyberg:master Aug 12, 2025
9 checks passed
@jezen jezen deleted the fix-312 branch August 12, 2025 10:36
@jappeace
Copy link
Copy Markdown
Collaborator

please update changelog too

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