flood

package
v0.1.19 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2022 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Statistics added in v0.1.13

func Statistics() (errors int64, requests int64)

Statistics returns total number of requests and errors.

Types

type Target

type Target struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

The target type that manages a target. A target can be a website, a dns, or something like that. TODO: refactor this into an interface and make New create different concrete types that deal with a particular kind of target.

func New

func New(addr, proxy string) *Target

Creates a target instance with all the configurations needed for an attack.

func (*Target) Name

func (t *Target) Name() string

Name Returns a name used in CLI multi-progressbar UI or GUI.

func (*Target) Run

func (t *Target) Run(ctx context.Context, N int, progress func(requests, errors int64))

Run Executes an attack. Usually has to be called as a goroutine. N is the number of concurrent workers.

func (*Target) SetProxy added in v0.1.10

func (t *Target) SetProxy(proxy string) error

SetProxy sets proxy for http requests.

Jump to

Keyboard shortcuts

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