Documentation
¶
Index ¶
- func GetMacAddress(target string) (string, error)
- type HostResult
- type OSFingerprint
- type Result
- func (r *Result) AddIp(ip string)
- func (r *Result) AddPort(ip string, p *port.Port)
- func (r *Result) AddSkipped(ip string)
- func (r *Result) GetHostCountForPort(portNum int) int
- func (r *Result) GetIPs() chan string
- func (r *Result) GetIPsPorts() chan *HostResult
- func (r *Result) GetOpenPortNumbers() []int
- func (r *Result) GetPortCount(host string) int
- func (r *Result) HasIP(ip string) bool
- func (r *Result) HasIPS() bool
- func (r *Result) HasIPsPorts() bool
- func (r *Result) HasSkipped(ip string) bool
- func (r *Result) IPHasPort(ip string, p *port.Port) bool
- func (r *Result) IsEmpty() bool
- func (r *Result) Len() int
- func (r *Result) SetPorts(ip string, ports []*port.Port)
- func (r *Result) UpdateHostOS(ip string, osfp *OSFingerprint)
- type ResultFn
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetMacAddress ¶ added in v2.3.6
GetMacAddress retrieves the MAC address for a given target (IP address or hostname). It resolves hostnames to IP addresses first, then queries the ARP table. Returns an empty string if the MAC address cannot be found.
Types ¶
type HostResult ¶
type HostResult struct {
Host string
IP string
Ports []*port.Port
Confidence confidence.ConfidenceLevel
OS *OSFingerprint
MacAddress string
}
type OSFingerprint ¶ added in v2.3.6
type Result ¶
Result of the scan
func (*Result) AddSkipped ¶
AddSkipped adds an ip to the skipped list
func (*Result) GetHostCountForPort ¶ added in v2.6.0
GetHostCountForPort returns the number of unique hosts that have a specific port open. Uses a single RLock, safe during concurrent writes.
func (*Result) GetIPsPorts ¶
func (r *Result) GetIPsPorts() chan *HostResult
GetIpsPorts returns the ips and ports
func (*Result) GetOpenPortNumbers ¶ added in v2.6.0
GetOpenPortNumbers returns the deduplicated set of port numbers that have been found open across all hosts. It acquires a single RLock and releases it before returning. Safe to call while writers (ex. AddPort from TCPResultWorker) are active.
func (*Result) GetPortCount ¶
GetPortCount returns the number of ports discovered for an ip
func (*Result) HasIPsPorts ¶
func (*Result) HasSkipped ¶
HasSkipped checks if an ip has been skipped
func (*Result) UpdateHostOS ¶ added in v2.3.6
func (r *Result) UpdateHostOS(ip string, osfp *OSFingerprint)
UpdateHostOS updates the OS info for a given IP in the results
type ResultFn ¶
type ResultFn func(*HostResult)