Skip to content
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

Disallow indefinite http client timeout #210

Merged
merged 1 commit into from
Jul 15, 2022
Merged

Conversation

avalonche
Copy link
Collaborator

@avalonche avalonche commented Jul 15, 2022

📝 Summary

Ensure that timeout for relay requests to be greater than 0.

⛱ Motivation and Context

0 and negative timeout values result in no timeout, which a malicious relay can potentially block execution, especially in the handleGetHeader function.

📚 References


✅ I have run these commands

  • make lint
  • make test
  • make run-mergemock-integration
  • go mod tidy

@codecov-commenter
Copy link

Codecov Report

Merging #210 (5a2ad4f) into main (df5e354) will decrease coverage by 0.22%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main     #210      +/-   ##
==========================================
- Coverage   72.16%   71.94%   -0.23%     
==========================================
  Files           6        6              
  Lines         636      638       +2     
==========================================
  Hits          459      459              
- Misses        151      153       +2     
  Partials       26       26              
Flag Coverage Δ
unittests 71.94% <0.00%> (-0.23%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
cmd/mev-boost/main.go 4.54% <0.00%> (-0.11%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update df5e354...5a2ad4f. Read the comment docs.

@metachris metachris changed the title Enforce minimum client timeout Disallow indefinite http client timeout Jul 15, 2022
@metachris metachris merged commit ffb245d into main Jul 15, 2022
@metachris metachris deleted the minimum-client-timeout branch July 15, 2022 07:55
screwyprof pushed a commit to screwyprof/mev-boost that referenced this pull request Feb 3, 2023
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.

3 participants