Audit changes.
This commit is contained in:
1 parent
243e75dd09
commit
0cd5982a3f
2 files changed
+5
-3
No files matched your search
@@ -55,11 +55,13 @@ func receiver(selfVPNIP netip.Addr, limiters []*ratelimiter.Limiter, ch chan<- P
|
||||
}
|
||||
|
||||
packet := unmarshal(buf[:n])
|
||||
if err := limiters[packet.PeerIP].Limit(); err != nil {
|
||||
|
||||
if packet.PeerIP == selfIP {
|
||||
continue
|
||||
}
|
||||
|
||||
if packet.PeerIP == selfIP {
|
||||
if err := limiters[packet.PeerIP].Limit(); err != nil {
|
||||
log.Printf("Rate limited packet from peer IP %d.", packet.PeerIP)
|
||||
continue
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user