utils

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2021 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanupChallengeContainers

func CleanupChallengeContainers(chall *database.Challenge, config cfg.BeastChallengeConfig) error

func CleanupChallengeIfExist

func CleanupChallengeIfExist(config cfg.BeastChallengeConfig) error

func CleanupChallengeImage

func CleanupChallengeImage(chall *database.Challenge) error

func CleanupContainerByFilter

func CleanupContainerByFilter(filter, filterVal string) error

func CreateAuthor

func CreateAuthor(name, username, email, publicKeyPath, password string)

func DeleteChallengeEntryWithPorts

func DeleteChallengeEntryWithPorts(challname string) error

func EncodeID

func EncodeID(a string) string

func GetChallengeDir

func GetChallengeDir(challengeName string) string

func GetLogs

func GetLogs(challname string, live bool) (*cr.Log, error)

func GetTempContainerId

func GetTempContainerId(a string) string

func GetTempImageId

func GetTempImageId(a string) string

func GetUser

func GetUser(authHeader string) (string, error)

func IsContainerIdValid

func IsContainerIdValid(a string) bool

func IsImageIdValid

func IsImageIdValid(a string) bool

func PrintTableHeader

func PrintTableHeader(w *tabwriter.Writer)

func ShowAllChallenges

func ShowAllChallenges() []error

func ShowChallenge

func ShowChallenge(chall database.Challenge) []error

func ShowChallengeByName

func ShowChallengeByName(name string) []error

func ShowTagRelatedChallenges

func ShowTagRelatedChallenges(Tag string) []error

Types

This section is empty.

Jump to

Keyboard shortcuts

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