remover

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2023 License: Apache-2.0 Imports: 21 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const VERSION = "0.2.2"

Variables

This section is empty.

Functions

func AppendIfMissing

func AppendIfMissing(slice []string, key string) []string

func CheckIfFileExists

func CheckIfFileExists(path string, stopRunning bool) bool

func ConvertJSONLtoJSON

func ConvertJSONLtoJSON(input string) string

func ConvertStringArrayToString

func ConvertStringArrayToString(stringArray []string, separator string) string

func ExistsInArray

func ExistsInArray(slice []string, key string) bool

func ExtractDomainAndTldFromString

func ExtractDomainAndTldFromString(str string) string

func GetAllRecordsForKey

func GetAllRecordsForKey(document *jsonquery.Node, key string) []*jsonquery.Node

func GetDocumentFromFile

func GetDocumentFromFile(filename string) *jsonquery.Node

func GetHostCounts

func GetHostCounts(document *jsonquery.Node) map[string]int

func GetHostURL

func GetHostURL(str string) string

func IsUrl

func IsUrl(str string) bool

func NewLogger

func NewLogger() *logger

func RandStringRunes

func RandStringRunes(n int) string

func ReadTxtFileLines

func ReadTxtFileLines(path string) []string

func WriteToTextFileInProject

func WriteToTextFileInProject(filename string, data string)

Types

type Config

type Config struct {
	S2SPath          string `yaml:"s2s_path,omitempty"`
	HttpxDomainsFile string `yaml:"httpx_domains,omitempty"`
	DpuxFile         string `yaml:"dpux,omitempty"`
	DpuxIPFile       string `yaml:"dpux_ip,omitempty"`
}

type Duplicate

type Duplicate struct {
	Status        int
	ContentLength int
	Lines         int
	Words         int
}

type Options

type Options struct {
	SettingsFile string
	Project      string
	BaseFolder   string
	Domains      bool
	Email        bool
	Ports        bool
	Silent       bool
	Version      bool
	NoColor      bool
	Verbose      bool
}

func ParseOptions

func ParseOptions() *Options

ParseOptions parses the command line flags provided by a user

type Remover

type Remover struct {
	// contains filtered or unexported fields
}

func NewRemover

func NewRemover(options *Options) (*Remover, error)

func (*Remover) CleanDomains

func (p *Remover) CleanDomains()

func (*Remover) Remove

func (p *Remover) Remove() error

type SimpleDNSXEntry

type SimpleDNSXEntry struct {
	Host          string   `yaml:"host"`
	IPv4Addresses []string `yaml:"ipv4"`
	IPv6Addresses []string `yaml:"ipv6,omitempty"`
	WhoisInfo     string   `yaml:"whois,omitempty"`
}

func CreateSimpleDNSEntryFromDPUX

func CreateSimpleDNSEntryFromDPUX(record *jsonquery.Node) SimpleDNSXEntry

func GetSimpleDNSEntryForHost

func GetSimpleDNSEntryForHost(document *jsonquery.Node, host string) SimpleDNSXEntry

type SimpleHTTPXEntry

type SimpleHTTPXEntry struct {
	Host           string
	BodyHash       string
	Status         int
	ContentLength  int
	Lines          int
	Words          int
	Input          string
	URL            string
	Title          string
	UseIfDuplicate bool `default:false`
}

func CreateSimpleHostEntryFromHTTPX

func CreateSimpleHostEntryFromHTTPX(entryValues map[string]interface{}) SimpleHTTPXEntry

func GetSimpleHostEntryForHost

func GetSimpleHostEntryForHost(document *jsonquery.Node, host string) []SimpleHTTPXEntry

Jump to

Keyboard shortcuts

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