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

net: Decrease nMaxIPs when learning from DNS seeds #29850

Merged
merged 1 commit into from Apr 22, 2024

Conversation

laanwj
Copy link
Member

@laanwj laanwj commented Apr 11, 2024

Limit number of IPs learned from a single DNS seed to 32, to prevent the results from one DNS seed from dominating AddrMan. Note that the number of results from a UDP DNS query is bounded to 33 already, but it is possible for it to use TCP where a larger number of results can be returned.

Closes #16070.

Limit number of IPs learned from a single DNS seed to 32, to prevent the results from
one DNS seed from dominating AddrMan. Note that the number of results from a UDP DNS query is
bounded to 33 already, but it is possible for it to use TCP where a potentially enormous
number of results can be returned.

Closes bitcoin#16070.
@laanwj laanwj added the P2P label Apr 11, 2024
@DrahtBot
Copy link
Contributor

DrahtBot commented Apr 11, 2024

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Code Coverage

For detailed information about the code coverage, see the test coverage report.

Reviews

See the guideline for information on the review process.

Type Reviewers
ACK 1440000bytes, Sjors, mzumsande, achow101
Concept ACK luke-jr

If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

Conflicts

Reviewers, this pull request conflicts with the following ones:

  • #29605 (net: Favor peers from addrman over fetching seednodes by sr-gi)
  • #28016 (p2p: gives seednode priority over dnsseed if both are provided by sr-gi)

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

Copy link

@1440000bytes 1440000bytes left a comment

Choose a reason for hiding this comment

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

utACK f2e3662

@Sjors
Copy link
Member

Sjors commented Apr 18, 2024

utACK f2e3662

@fanquake fanquake requested a review from mzumsande April 18, 2024 09:12
Copy link
Member

@luke-jr luke-jr left a comment

Choose a reason for hiding this comment

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

utACK

Copy link
Contributor

@mzumsande mzumsande left a comment

Choose a reason for hiding this comment

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

utACK f2e3662

@DrahtBot DrahtBot requested a review from luke-jr April 21, 2024 23:00
@achow101
Copy link
Member

ACK f2e3662

@achow101 achow101 merged commit 3310a96 into bitcoin:master Apr 22, 2024
16 checks passed
luke-jr pushed a commit to bitcoinknots/bitcoin that referenced this pull request Apr 24, 2024
Limit number of IPs learned from a single DNS seed to 32, to prevent the results from
one DNS seed from dominating AddrMan. Note that the number of results from a UDP DNS query is
bounded to 33 already, but it is possible for it to use TCP where a potentially enormous
number of results can be returned.

Closes bitcoin#16070.

Github-Pull: bitcoin#29850
Rebased-From: f2e3662
@sr-gi
Copy link
Member

sr-gi commented Apr 25, 2024

Post-merge ACK f2e3662

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Decreasing nMaxIPs when learning from DNS seeds
8 participants