listeners

package
v0.0.0-...-9d62925 Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2023 License: MIT Imports: 32 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var JobCount int

JobCount is a global variable containing the number of jobs This is duplicative off of the actual agents, when it gets refactored then we can just import it from the agent section itself

Functions

func Dropper

func Dropper(data string, lName string) []byte

Dropper returns the binary asked for by the dropper

func ModHandler

func ModHandler(data string)

ModHandler verifes the module data and passes it forward to the backend for the agent

func StartDNSHTTPSServer

func StartDNSHTTPSServer(newListener ListOptions, aesKey []byte) (bool, *dns.Server)

StartDNSHTTPSServer is used to start the DNS over https server List options is pretty different for this one so that needs to be evaluated

func StartHTTPSServer

func StartHTTPSServer(newListener ListOptions, pr []byte, pu []byte) (*http.Server, bool)

StartHTTPSServer is used to start the https server

func StartQUICServer

func StartQUICServer(newListener ListOptions, pr []byte, pu []byte) (*http3.Server, bool)

StartQUICServer will start up a Quic Listener

func StartTCPServer

func StartTCPServer(newListener ListOptions, pr []byte) (net.Listener, bool)

StartTCPServer will start the new tcp server

Types

type AdvancedHTTPSOptions

type AdvancedHTTPSOptions struct {
	ExistingCert bool //Does the user have a cert?
	CertData     HTTPSListenerCertData
	RegisterPath string //HTTP path for registering the agent
	CheckinPath  string //HTTP path for checking in
	ModulePath   string //HTTP path for module communication
	PivotPath    string //HTTP path for pivoting
}

AdvancedHTTPSOptions holds all the fields needed for the listeners advanced options

type AgentOptions

type AgentOptions struct {
	Delay     string //Agent Delay
	Jitter    string //Agent Jitter value
	Eol       string //When the Agent should die
	LiveHours string //When the agent can operate
}

AgentOptions holds all of the options for agents

type DNSBuffer

type DNSBuffer struct {
	Identifier string
	Data       []byte
	Seq        int
	Started    bool
	Finished   bool
	Protocol   int
}

DNSBuffer represents a pending DNS conversation

type HTTPSListenerCertData

type HTTPSListenerCertData struct {
	Cert string //Base64 encoded data of the cert
	Key  string //Base64 encoded data of the key
}

HTTPSListenerCertData holds data on imported HTTPS listener structs

type ListOptions

type ListOptions struct {
	LType        string      //Type of listener
	Name         string      //Listener name
	Host         string      //IP or DQDN listener will bind too
	Port         string      //Port to listen on
	Key          string      //Listener UUID4 name
	Advanced     interface{} //Advanced listener options held as JSON here
	AgentOptions AgentOptions
}

ListOptions holds all possible options required for listeners

Jump to

Keyboard shortcuts

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