Documentation ¶
Index ¶
- func CheckDirExists(dirName string) bool
- func CheckElfExists(fileName string) bool
- func CheckFileExists(fileName string) bool
- func CheckIfElf(fileName string) bool
- func FilePrinter(outputFormat string, data interface{}, colors interface{})
- func FortifyPrinter(outputFormat string, data interface{}, colors interface{})
- func GetAllFilesFromDir(dirName string, recursive bool) []string
- func GetBinary(fileName string) *elf.File
- func KernelPrinter(outputFormat string, kernel any, kernelColors any)
- func ParseKernel(filename string) (any, any)
- func PrintLogo()
- func RunFileChecks(filename string) ([]interface{}, []interface{})
- type FortifyCheck
- type FortifyCheckColor
- type KernelCheck
- type KernelCheckColor
- type SecurityCheck
- type SecurityCheckColor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckDirExists ¶
CheckDirExists - Check if the directory exists
func CheckElfExists ¶
CheckElfExists - Check if file exists and is an Elf file
func CheckFileExists ¶
CheckFileExists - check if the file exists
func CheckIfElf ¶
CheckIfElf - Check if the file is an Elf file
func FilePrinter ¶
func FilePrinter(outputFormat string, data interface{}, colors interface{})
func FortifyPrinter ¶
func FortifyPrinter(outputFormat string, data interface{}, colors interface{})
FortifyPrinter - Print the output from FortifyFile function
func GetAllFilesFromDir ¶
GetAllFilesFromDir - get the list of all elf files from a directory (or recursively)
func KernelPrinter ¶
func ParseKernel ¶
ParseKernel - Parses the kernel config and runs the checks
func RunFileChecks ¶
func RunFileChecks(filename string) ([]interface{}, []interface{})
RunFileChecks - Run the file checks
Types ¶
type FortifyCheck ¶
type FortifyCheck struct { Name string `json:"name"` Checks struct { Fortified string `json:"fortified"` FortifyAble string `json:"fortifyable"` FortifySource string `json:"fortify_source"` NoFortify string `json:"noFortify"` LibcSupport string `json:"libcSupport"` NumLibcFunc string `json:"numLibcFunc"` NumFileFunc string `json:"numFileFunc"` } `json:"checks"` }
FortifyCheck struct for non-colored data, keeping a dedicated struct allows conversion without removing the colors
type FortifyCheckColor ¶
type FortifyCheckColor struct { Name string `json:"name"` Checks struct { Fortified string `json:"fortified"` FortifyAble string `json:"fortifyable"` FortifySource string `json:"fortify_source"` FortifySourceColor string `json:"fortify_sourceColor"` NoFortify string `json:"noFortify"` LibcSupport string `json:"libcSupport"` LibcSupportColor string `json:"libcSupportColor"` NumLibcFunc string `json:"numLibcFunc"` NumFileFunc string `json:"numFileFunc"` } `json:"checks"` }
FortifyCheckColor struct for colored data
type KernelCheck ¶
type KernelCheckColor ¶
type SecurityCheck ¶
type SecurityCheck struct { Name string `json:"name"` Checks struct { Canary string `json:"canary"` Fortified string `json:"fortified"` FortifyAble string `json:"fortifyable"` FortifySource string `json:"fortify_source"` NX string `json:"nx"` PIE string `json:"pie"` Relro string `json:"relro"` RPath string `json:"rpath"` RunPath string `json:"runpath"` Symbols string `json:"symbols"` } `json:"checks"` }
type SecurityCheckColor ¶
type SecurityCheckColor struct { Name string `json:"name"` Checks struct { Canary string `json:"canary"` CanaryColor string `json:"canaryColor"` Fortified string `json:"fortified"` FortifyAble string `json:"fortifyable"` FortifySource string `json:"fortify_source"` FortifySourceColor string `json:"fortify_sourceColor"` NX string `json:"nx"` NXColor string `json:"nxColor"` PIE string `json:"pie"` PIEColor string `json:"pieColor"` Relro string `json:"relro"` RelroColor string `json:"relroColor"` RPath string `json:"rpath"` RPathColor string `json:"rpathColor"` RunPath string `json:"runpath"` RunPathColor string `json:"runpathColor"` Symbols string `json:"symbols"` SymbolsColor string `json:"symbolsColor"` } `json:"checks"` }
Click to show internal directories.
Click to hide internal directories.