Documentation
¶
Index ¶
- Variables
- func DefaultQuery(query string, engine string) string
- func GetHostname(u string) (string, error)
- func GetProxyFunc(proxy, auth string) (func(*http.Request) (*url.URL, error), error)
- func MatchSubdomains(domain string, html string, fuzzy bool) []string
- func NewHTTPRequest(method, url string, body io.Reader) (*retryablehttp.Request, error)
- func ParseProxyAuth(auth string) (string, string, bool)
- type Agent
- type Keys
- type Provider
- type Query
- type Result
- type Session
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // UncoverConfigDir Todo: replace from utils with ConfigDirOrDefault UncoverConfigDir = filepath.Join(folderutil.HomeDirOrDefault("."), ".config/pathScan") // DefaultProviderConfigLocation where keys and config of providers is stored DefaultProviderConfigLocation = filepath.Join(UncoverConfigDir, "provider-config.yaml") )
View Source
var DefaultRateLimits = map[string]*ratelimit.Options{ "shodan": {Key: "shodan", MaxCount: 1, Duration: time.Second}, "shodan-idb": {Key: "shodan-idb", MaxCount: 1, Duration: time.Second}, "fofa": {Key: "fofa", MaxCount: 1, Duration: time.Second}, "censys": {Key: "censys", MaxCount: 1, Duration: 3 * time.Second}, "quake": {Key: "quake", MaxCount: 1, Duration: time.Second}, "hunter": {Key: "hunter", MaxCount: 15, Duration: time.Second}, "zoomeye": {Key: "zoomeye", MaxCount: 1, Duration: time.Second}, "netlas": {Key: "netlas", MaxCount: 1, Duration: time.Second}, "criminalip": {Key: "criminalip", MaxCount: 1, Duration: time.Second}, "publicwww": {Key: "publicwww", MaxCount: 1, Duration: time.Minute}, "hunterhow": {Key: "hunterhow", MaxCount: 1, Duration: 3 * time.Second}, }
DefaultRateLimits of all/most of uncover are hardcoded by default to improve performance engine is not present in default ratelimits then user given ratelimit from cli options is used
Functions ¶
func DefaultQuery ¶
func GetHostname ¶
func GetProxyFunc ¶
GetProxyFunc 辅助函数:获取代理设置函数
func NewHTTPRequest ¶
Types ¶
type Keys ¶
type Provider ¶
type Provider struct {
Shodan []string `yaml:"shodan"`
Censys []string `yaml:"censys"`
Fofa []string `yaml:"fofa"`
Quake []string `yaml:"quake"`
Hunter []string `yaml:"hunter"`
ZoomEye []string `yaml:"zoomeye"`
Netlas []string `yaml:"netlas"`
CriminalIP []string `yaml:"criminalip"`
Publicwww []string `yaml:"publicwww"`
HunterHow []string `yaml:"hunterhow"`
Binary []string `yaml:"binary"`
}
func NewProvider ¶
func NewProvider() *Provider
NewProvider loads provider keys from default location and env variables
func (*Provider) LoadProviderConfig ¶
LoadProviderConfig LoadProvidersFrom loads provider config from given location
func (*Provider) LoadProviderKeysFromEnv ¶
func (provider *Provider) LoadProviderKeysFromEnv()
LoadProviderKeysFromEnv loads provider keys from env variables
type Result ¶
type Result struct {
Timestamp int64 `json:"timestamp" csv:"timestamp"`
Source string `json:"source" csv:"source"`
IP string `json:"ip" csv:"IP"`
Port int `json:"port" csv:"port"`
Host string `json:"host" csv:"host"`
Url string `json:"url" csv:"url"`
Raw []byte `json:"-" csv:"-"`
Error error `json:"-" csv:"-"`
}
type Session ¶
type Session struct {
Keys *Keys
Client *retryablehttp.Client
RetryMax int
RateLimits *ratelimit.MultiLimiter
}
Session handles session agent sessions
func NewSession ¶
Click to show internal directories.
Click to hide internal directories.