new: main packet queue is now used to gather network stats, update endpoint, etc

This commit is contained in:
evilsocket 2018-01-13 18:40:43 +01:00
commit 913c581f9f
4 changed files with 127 additions and 15 deletions

View file

@ -4,6 +4,7 @@ import (
"fmt"
"sort"
"sync"
"time"
"github.com/evilsocket/bettercap-ng/core"
"github.com/evilsocket/bettercap-ng/net"
@ -63,6 +64,7 @@ func (tp *Targets) AddIfNotExist(ip, mac string) *net.Endpoint {
}
if t, found := tp.Targets[mac]; found {
t.LastSeen = time.Now()
return t
}