mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 02:36:57 -07:00
working on mdns collector
This commit is contained in:
parent
3b6ea499dd
commit
f6bfd683ee
2 changed files with 47 additions and 9 deletions
|
@ -90,6 +90,12 @@ func (s *Session) startNetMon() {
|
|||
existing := s.Lan.AddIfNew(addr, mac)
|
||||
if existing != nil {
|
||||
existing.LastSeen = time.Now()
|
||||
} else {
|
||||
existing, _ = s.Lan.Get(mac)
|
||||
}
|
||||
|
||||
if existing != nil && existing.Hostname == "" && event.Hostname != "" {
|
||||
existing.Hostname = event.Hostname
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue