core

package
v1.15.0 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2024 License: GPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Core

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

Core implements the Runner interface for performing network scanning

func New

func New() *Core

New returns a new instance of Core

func (*Core) Initialize

func (c *Core) Initialize(
	coreScanner scanner.Scanner,
	targetLen int,
	portLen int,
	noProgress bool,
	arpOnly bool,
	printJSON bool,
	outFile string,
)

Initialize initializes the Core before performing network scanning

func (*Core) Run

func (c *Core) Run() error

Run executes a network scan

type DeviceResult

type DeviceResult struct {
	IP        net.IP           `json:"ip"`
	MAC       net.HardwareAddr `json:"mac"`
	Hostname  string           `json:"hostname"`
	Vendor    string           `json:"vendor"`
	Status    scanner.Status   `json:"status"`
	OpenPorts []scanner.Port   `json:"openPorts"`
}

DeviceResult represents a discovered network device

func (*DeviceResult) Serializable

func (r *DeviceResult) Serializable() interface{}

Serializable returns a serializable version of DeviceResult

type Results

type Results struct {
	Devices []*DeviceResult `json:"devices"`
}

Results data structure for holding discovered network devices

func (*Results) MarshalJSON

func (r *Results) MarshalJSON() ([]byte, error)

MarshalJSON returns marshaled JSON of Results

type Runner

type Runner interface {
	Initialize(
		coreScanner scanner.Scanner,
		targetLen int,
		portLen int,
		noProgress bool,
		arpOnly bool,
		printJSON bool,
		outFile string,
	)
	Run() error
}

Runner interface for performing network scanning

Jump to

Keyboard shortcuts

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