Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
a9ef135e
Unverified
Commit
a9ef135e
authored
Jul 15, 2022
by
Ha ĐANG
Committed by
GitHub
Jul 15, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
p2p/discover: apply netrestrict in discv5 response handler (#25304)
parent
e3df3d34
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
v5_udp.go
p2p/discover/v5_udp.go
+3
-0
No files found.
p2p/discover/v5_udp.go
View file @
a9ef135e
...
...
@@ -407,6 +407,9 @@ func (t *UDPv5) verifyResponseNode(c *callV5, r *enr.Record, distances []uint, s
if
err
:=
netutil
.
CheckRelayIP
(
c
.
node
.
IP
(),
node
.
IP
());
err
!=
nil
{
return
nil
,
err
}
if
t
.
netrestrict
!=
nil
&&
!
t
.
netrestrict
.
Contains
(
node
.
IP
())
{
return
nil
,
errors
.
New
(
"not contained in netrestrict list"
)
}
if
c
.
node
.
UDP
()
<=
1024
{
return
nil
,
errLowPort
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment