config

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Set

func Set(c *Config)

Types

type Analyze

type Analyze struct {
	RequireOpenPorts bool `yaml:"require-open-ports" mapstructure:"require-open-ports"`
}

type Blacklist

type Blacklist struct {
	RootDomains []string `yaml:"root-domains" mapstructure:"root-domains"`
	Domains     []string `yaml:"domains" mapstructure:"domains"`
	IPs         []string `yaml:"ips" mapstructure:"ips"`
}

type Config

type Config struct {
	Scripts   Scripts   `yaml:"scripts" mapstructure:"scripts"`
	Wordlists Wordlists `yaml:"wordlists" mapstructure:"wordlists"`
	Blacklist Blacklist `yaml:"blacklist" mapstructure:"blacklist"`
	Discover  Discover  `yaml:"discover" mapstructure:"discover"`
	Analyze   Analyze   `yaml:"analyze" mapstructure:"analyze"`
	Hosts     Hosts     `yaml:"hosts" mapstructure:"hosts"`
}

func Default

func Default(home string) Config

func Get

func Get() *Config

func (*Config) GetScripts

func (c *Config) GetScripts(phase string) []Script

func (*Config) IterateScripts

func (c *Config) IterateScripts(phase string, done chan int) chan Script

type Discover

type Discover struct {
	TopTCP        int    `yaml:"top-tcp-count" mapstructure:"top-tcp-count"`
	TopUDP        int    `yaml:"top-udp-count" mapstructure:"top-udp-count"`
	TimingProfile int    `yaml:"timing-profile" mapstructure:"timing-profile"`
	ResolveConf   string `yaml:"resolvconf" mapstructure:"resolvconf"`
}

type Hosts

type Hosts struct {
	NmapXMLGlob    string          `yaml:"nmap-xml-glob" mapstructure:"nmap-xml-glob"`
	IgnoreServices []IgnoreService `yaml:"ignore-services" mapstructure:"ignore-services"`
}

type IgnoreService

type IgnoreService struct {
	Name  string `yaml:"name" mapstructure:"name"`
	Ports string `yaml:"ports" mapstructure:"ports"`
	Flag  string `yaml:"flag" mapstructure:"flag"` // This is so we can add a flag saying that this was ignored to make people aware that ports were ignored
}

Don't know what this should be called, if anyone has any better names, go for it

func (IgnoreService) ShouldIgnore

func (s IgnoreService) ShouldIgnore(service string, port int) bool

type Phase

type Phase struct {
	Args    string            `yaml:"args" mapstructure:"args"`
	Scripts map[string]Script `yaml:"scripts" mapstructure:"scripts"`
}

type Script

type Script struct {
	Args    string `yaml:"args" mapstructure:"args"`
	Script  string `yaml:"script" mapstructure:"script"`
	Order   int    `yaml:"order" mapstructure:"order"`
	Count   int    `yaml:"count" mapstructure:"count"`
	Enabled bool   `yaml:"enabled" mapstructure:"enabled"`

	TotalRuns int `yaml:"-" mapstructure:"-"`
}

func NewScript

func NewScript(script string, order int, count int, enabled bool) Script

type Scripts

type Scripts struct {
	Directory string           `yaml:"directory" mapstructure:"directory"`
	Phases    map[string]Phase `yaml:"phases" mapstructure:"phases"`
}

type Wordlists

type Wordlists struct {
	Paths []string            `yaml:"paths" mapstructure:"paths"`
	Types map[string][]string `yaml:"types" mapstructure:"types"`
}

Jump to

Keyboard shortcuts

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