Documentation ¶
Index ¶
- Constants
- func IPRange(c *net.IPNet) string
- func ParseIP(ip string) ([]string, error)
- func ParsePorts(options *Options) ([]int, error)
- type Options
- type Runner
- func (r *Runner) AddTarget(targets []string) error
- func (r *Runner) Close()
- func (r *Runner) ConnectVerification()
- func (r *Runner) GetIPFromUrl(target string) ([]string, error)
- func (r *Runner) ParseTarget() error
- func (r *Runner) PickIP(targets []*net.IPNet, index int64) string
- func (r *Runner) PickPort(index int) int
- func (r *Runner) PickSubnetIP(network *net.IPNet, index int64) string
- func (r *Runner) Run() error
- func (r *Runner) ShowScanResultOnExit()
Constants ¶
View Source
const ( DefaultPortTimeoutSynScan = 1500 DefaultPortTimeoutConnectScan = 5000 DefaultRateSynScan = 2000 DefaultRateConnectScan = 1500 DefaultRetriesSynScan = 3 DefaultRetriesConnectScan = 3 ExternalTargetForTune = "8.8.8.8" SynScan = "s" ConnectScan = "c" DefaultStatsInterval = 5 )
View Source
const ( Full = "1-65535" NmapTop100 = "" /* 393-byte string literal not displayed */ NmapTop1000 = "" /* 3813-byte string literal not displayed */ )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Options ¶
type Options struct { Stdin bool // Stdin specifies whether stdin input was given to the process Verify bool // Verify is used to check if the ports found were valid using CONNECT method Debug bool // Prints out debug information Retries int // Retries is the number of retries for the port Retries 是端口的重试次数 Rate int // Rate is the rate of port scan requests 扫描速率 Timeout int // Timeout is the seconds to wait for ports to respond 超时时间 Host []string // Host is the single host or comma-separated list of hosts to find ports for Ports string // Ports is the ports to use for enumeration TopPorts string // Tops ports to scan SourceIP string // SourceIP to use in TCP packets Interface string // Interface to use for TCP packets Threads int // Internal worker threads ScanAllIPS bool // Scan all the ips ScanType string // Scan Type Proxy string // Socks5 proxy }
func (*Options) ShowNetworkCapabilities ¶
ShowNetworkCapabilities 判断运行用户可能的网络功能/扫描类型
func (*Options) ValidateOptions ¶
ValidateOptions validates the configuration options passed
type Runner ¶
type Runner struct { Options *Options Scanner *scan.Scanner // contains filtered or unexported fields }
func (*Runner) ConnectVerification ¶
func (r *Runner) ConnectVerification()
func (*Runner) GetIPFromUrl ¶
GetIPFromUrl 将URL转换为IP地址
func (*Runner) ParseTarget ¶
func (*Runner) ShowScanResultOnExit ¶
func (r *Runner) ShowScanResultOnExit()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.