Endpoint

package module
v0.0.0-...-094bedd Latest Latest
Warning

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

Go to latest
Published: May 1, 2024 License: MIT Imports: 14 Imported by: 7

Documentation

Index

Constants

View Source
const (
	// Errors
	UnexpectedTestError      int = 1
	TimeoutExceeded          int = 102
	CleanupFailed            int = 103
	OutOfMemory              int = 137
	UnexpectedExecutionError int = 256

	// Not Relevant
	NotRelevant int = 104

	// Protected
	TestCompletedNormally       int = 100
	FileQuarantinedOnExtraction int = 105
	NetworkConnectionBlocked    int = 106
	HostNotVulnerabile          int = 107
	ExecutionPrevented          int = 126
	FileQuarantinedOnExecution  int = 127

	// Unprotected
	Unprotected            int = 101
	TestIncorrectlyBlocked int = 110
)

Variables

This section is empty.

Functions

func AES256GCMDecrypt

func AES256GCMDecrypt(data, key []byte) ([]byte, error)

func AES256GCMEncrypt

func AES256GCMEncrypt(data []byte) ([]byte, []byte, error)

func ExecuteRandomCommand

func ExecuteRandomCommand(commands [][]string) (string, error)

func Exists

func Exists(path string) bool

func Find

func Find(ext string) []string

func GetOS

func GetOS() string

func IsAvailable

func IsAvailable(programs ...string) bool

func Pwd

func Pwd(filename string) string

func Quarantined

func Quarantined(filename string, contents []byte) bool

func Read

func Read(path string) []byte

func Remove

func Remove(path string) bool

func Say

func Say(print string)

func Shell

func Shell(args []string) (string, error)

func Start

func Start(test fn, clean ...fn)

func Stop

func Stop(code int)

func Unzip

func Unzip(zipData []byte) error

func Wait

func Wait(dur time.Duration)

NB: time.Duration is an int64 cast

func Write

func Write(filename string, contents []byte)

func XorDecrypt

func XorDecrypt(data []byte, key []byte) []byte

func XorEncrypt

func XorEncrypt(data []byte) ([]byte, []byte, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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