finger

package
v1.0.26 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2023 License: MIT Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InsertInto added in v1.0.17

func InsertInto(s string, interval int, sep rune) string

func ResponseDecoding

func ResponseDecoding(body []byte, charset string) string

Types

type AppFinger

type AppFinger struct {
	Rules []*Rule

	Proxy string
	// contains filtered or unexported fields
}

func New

func New(options *Options) *AppFinger

func (*AppFinger) AddFinger

func (f *AppFinger) AddFinger(content string) error

func (*AppFinger) LoadAppFinger

func (f *AppFinger) LoadAppFinger(directory string)

func (*AppFinger) Match

func (f *AppFinger) Match(banner *Banner) map[string]map[string]string

func (*AppFinger) MatchURI

func (f *AppFinger) MatchURI(uri string) (*Banner, map[string]map[string]string)
type Banner struct {
	Body        string
	Header      string
	Headers     map[string]string
	Title       string
	StatusCode  int
	Response    string
	SSL         bool
	Certificate string
	IconHash    int32
}

func Request

func Request(uri string, timeout time.Duration, proxyURL string, disableIcon bool) ([]*Banner, error)

type Options

type Options struct {
	Timeout           time.Duration
	Home              string
	Proxy             string
	DisableJavaScript bool
	DisableIcon       bool
}

type Rule

type Rule struct {
	Name              string              `json:"name,omitempty"`
	MatchersCondition string              `yaml:"matchers-condition" json:"matchers_condition,omitempty"`
	Matchers          []*matchers.Matcher `json:"matchers,omitempty"`
}

func (*Rule) Match

func (r *Rule) Match(banner *Banner) (bool, map[string]string)

Jump to

Keyboard shortcuts

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