misc: small fix or general refactoring i did not bother commenting

This commit is contained in:
evilsocket 2018-02-16 21:17:53 +01:00
commit afb66a7c4d
4 changed files with 50 additions and 46 deletions

27
modules/wifi_station.go Normal file
View file

@ -0,0 +1,27 @@
package modules
import (
"github.com/evilsocket/bettercap-ng/network"
)
type WiFiStation struct {
*network.Endpoint
IsAP bool
Channel int
}
func NewWiFiStation(essid, bssid string, isAp bool, channel int) *WiFiStation {
return &WiFiStation{
Endpoint: network.NewEndpointNoResolve(network.MonitorModeAddress, bssid, essid, 0),
IsAP: isAp,
Channel: channel,
}
}
func (s WiFiStation) BSSID() string {
return s.HwAddress
}
func (s *WiFiStation) ESSID() string {
return s.Hostname
}