uncover

package
v1.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 16, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetHostname added in v1.0.3

func GetHostname(u string) (string, error)

func NewHTTPRequest added in v0.0.4

func NewHTTPRequest(method, url string, body io.Reader) (*retryablehttp.Request, error)

Types

type Agent

type Agent interface {
	Query(*Session, *Query) (chan Result, error)
	Name() string
}

type Keys

type Keys struct {
	CensysToken     string
	CensysSecret    string
	Shodan          string
	FofaEmail       string
	FofaKey         string
	QuakeToken      string
	HunterToken     string
	ZoomEyeToken    string
	NetlasToken     string
	CriminalIPToken string
	PublicwwwToken  string
	HunterHowToken  string
}

func (Keys) Empty

func (keys Keys) Empty() bool

type Query

type Query struct {
	Query string
	Limit int
}

type Result

type Result struct {
	Timestamp int64  `json:"timestamp"`
	Source    string `json:"source"`
	IP        string `json:"ip"`
	Port      int    `json:"port"`
	Host      string `json:"host"`
	Url       string `json:"url"`
	Raw       []byte `json:"-"`
	Error     error  `json:"-"`
}

func (*Result) HostPort

func (result *Result) HostPort() string

func (*Result) IpPort

func (result *Result) IpPort() string

func (*Result) JSON

func (result *Result) JSON() string

func (*Result) RawData

func (result *Result) RawData() string

type Session

type Session struct {
	Keys       *Keys
	Client     *retryablehttp.Client
	RetryMax   int
	RateLimits *ratelimit.MultiLimiter
}

func NewSession

func NewSession(keys *Keys, retryMax, timeout, rateLimit int, engines []string, duration time.Duration) (*Session, error)

func (*Session) Do

func (s *Session) Do(request *retryablehttp.Request, source string) (*http.Response, error)

Directories

Path Synopsis
agent

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL