Skip to content

feat(tcp): valid node more strictly - #149

Open
317787106 wants to merge 4 commits into
tronprotocol:release-v2.3.0from
317787106:fix/validate_port
Open

317787106 wants to merge 4 commits into
tronprotocol:release-v2.3.0from
317787106:fix/validate_port

Conversation

@317787106

@317787106 317787106 commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

  • Reuse a shared service-port check during node validation.
  • Keep IPv6 normalization independent of service-port handling.
  • Improve connection-pool handling of unusable node records and candidates while preserving DNS candidate support.

Why are these changes required?

Node endpoint validation and address handling should apply consistent rules across networking components, and unusable node records should be handled locally during candidate processing.

This PR has been tested by:

  • 47 focused tests passed, covering endpoint boundaries, IPv4/IPv6 handling, message validation, connection-pool behavior, and DNS candidates. git diff --check passed.

Follow up

None.

Extra details

IPv6 normalization is independent of service-port handling, and the connection pool continues to support DNS candidates.

@317787106 317787106 changed the title feat(net): valid node more strictly feat(tcp): valid node more strictly Sep 11, 2026
Comment thread src/test/java/org/tron/p2p/discover/NodeTest.java
@317787106
317787106 changed the base branch from main to release-v2.3.0 September 15, 2026 04:00
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