online

package
v0.0.0-...-787453a Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2022 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddAutoTimeBefore

func AddAutoTimeBefore(ruleList []string, afterTime string) (withTimeruleList []string)

func FofaSearch

func FofaSearch(proxy string, wg *sync.WaitGroup) (err error)

func GenerateDynamicRules

func GenerateDynamicRules(rule autocode2.Rules) (err error, dynamicRulesList []string)

动态规则与配置信息匹配,生成规则

func IsContain

func IsContain(items []string, item string) bool

func ReplaceStringWithInfos

func ReplaceStringWithInfos(list []string, string2 string, infos string) (ruleList []string)

将规则内占位符生成可用规则

func SearchRunner

func SearchRunner(interval float64, proxy string)

Types

type Fofa

type Fofa struct {
	*http.Client
	// contains filtered or unexported fields
}

func NewFofaClient

func NewFofaClient(email, key []byte) *Fofa

NewFofaClient create a fofa client

func (*Fofa) GenerateKeywords

func (*Fofa) GenerateKeywords(list []autocode2.Rules) (err error, ruleList []string)

func (*Fofa) Get

func (ff *Fofa) Get(u string) ([]byte, error)

Get overwrite http.Get

func (*Fofa) GetAPi

func (fofa *Fofa) GetAPi() (err error)

func (*Fofa) GetRules

func (fofa *Fofa) GetRules() (err error, list []autocode2.Rules)

func (*Fofa) QueryAsArray

func (ff *Fofa) QueryAsArray(page uint, args ...[]byte) (result FofaResults, err error)

QueryAsArray make a fofa query and return array data as result echo 'domain="nosec.org"' | base64 - | xargs -I{} curl "https://fofa.so/api/v1/search/all?email=${FOFA_EMAIL}&key=${FOFA_KEY}&qbase64={}"

func (*Fofa) QueryAsJSON

func (ff *Fofa) QueryAsJSON(page uint, args ...[]byte) ([]byte, error)

QueryAsJSON make a fofa query and return json data as result echo 'domain="nosec.org"' | base64 - | xargs -I{} curl "https://fofa.so/api/v1/search/all?email=${FOFA_EMAIL}&key=${FOFA_KEY}&qbase64={}" host title ip domain port country city

func (*Fofa) RunTask

func (*Fofa) RunTask()

func (*Fofa) Runner

func (*Fofa) Runner(intervalTime float64, proxy string)

func (*Fofa) SaveResult

func (*Fofa) SaveResult()

func (*Fofa) UserInfo

func (ff *Fofa) UserInfo() (user *User, err error)

UserInfo get user information

type FofaResults

type FofaResults []result

Results fofa result set

func (*FofaResults) String

func (r *FofaResults) String() string

type SearchResult

type SearchResult struct {
	Results     []string
	FofaResults []FofaResults
	// contains filtered or unexported fields
}

func (*SearchResult) Add

func (searchResult *SearchResult) Add(f interface{})

type User

type User struct {
	Email  string `json:"email,omitempty"`
	Fcoin  int    `json:"fcoin,omitempty"`
	Vip    bool   `json:"bool,omitempty"`
	Avatar string `json:"avatar,omitempty"`
	Err    string `json:"errmsg,omitempty"`
}

User struct for fofa user

func (*User) String

func (u *User) String() string

Jump to

Keyboard shortcuts

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