Documentation
¶
Index ¶
- Constants
- Variables
- type ARPScanResult
- type ARPScanResults
- type ARPScanner
- func (a *ARPScanner) Close()
- func (a *ARPScanner) GenerateTarget(timeoutCh chan struct{})
- func (a *ARPScanner) Recv()
- func (a *ARPScanner) RecvARP(packet gopacket.Packet) interface{}
- func (a *ARPScanner) Scan()
- func (a *ARPScanner) ScanLocalNet() chan struct{}
- func (a *ARPScanner) ScanMany(ips []netip.Addr) chan struct{}
- func (a *ARPScanner) ScanPrefix(prefix netip.Prefix) chan struct{}
- func (a *ARPScanner) SendARPReq(target *Target)
- type Target
Constants ¶
View Source
const (
REGISTER_NAME = "ARP"
)
Variables ¶
View Source
var ARP_BROADCAST = net.HardwareAddr{0x00, 0x00, 0x00, 0x00, 0x00, 0x00}
View Source
var ETH_BROADCAST = net.HardwareAddr{0xff, 0xff, 0xff, 0xff, 0xff, 0xff}
Functions ¶
This section is empty.
Types ¶
type ARPScanResult ¶
type ARPScanResult struct { IP netip.Addr `json:"ip"` // 结果IP Mac net.HardwareAddr `json:"mac"` // 结果物理地址 Vendor string `json:"vendor"` // 结果物理地址厂商 }
type ARPScanResults ¶
type ARPScanResults struct {
Results []*ARPScanResult
}
type ARPScanner ¶
type ARPScanner struct { // Deprecated: No longer available. Stop chan struct{} // ARP 扫描器状态 Opts gopacket.SerializeOptions // 包序列化选项 Timeout time.Duration // 抓包超时时间 // Deprecated: Use Ifas instead. Ifaces *[]common.GSInterface // 可用接口列表 Ifas *[]common.GSIface // 可用接口列表 AHMap cmap.ConcurrentMap[netip.Addr, net.HardwareAddr] // 获取到的IP <-> Mac 映射表 OMap *sync.Map // Mac前缀 <-> 厂商 映射表 Lock sync.Mutex TargetCh chan *Target ResultCh chan *ARPScanResult }
func GetARPScanner ¶
func GetARPScanner() *ARPScanner
func (*ARPScanner) Close ¶
func (a *ARPScanner) Close()
func (*ARPScanner) GenerateTarget ¶
func (a *ARPScanner) GenerateTarget(timeoutCh chan struct{})
目标生产协程
func (*ARPScanner) ScanMany ¶
func (a *ARPScanner) ScanMany(ips []netip.Addr) chan struct{}
func (*ARPScanner) ScanPrefix ¶
func (a *ARPScanner) ScanPrefix(prefix netip.Prefix) chan struct{}
Click to show internal directories.
Click to hide internal directories.