mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 10:46:57 -07:00
fix: restoring ttl counter up to max threshold when a device is refound on arp cache
This commit is contained in:
parent
6c7d580868
commit
4c4a946d44
1 changed files with 3 additions and 0 deletions
|
@ -158,6 +158,9 @@ func (tp *Targets) AddIfNotExist(ip, mac string) *net.Endpoint {
|
|||
|
||||
mac = net.NormalizeMac(mac)
|
||||
if t, found := tp.Targets[mac]; found {
|
||||
if tp.TTL[mac] < TargetsDefaultTTL {
|
||||
tp.TTL[mac]++
|
||||
}
|
||||
return t
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue