Documentation
¶
Overview ¶
Package cli is the command line shared by the engine binary and the thin per-detector binaries (emudhra-scan, php2shell-scan), which pin one detector and keep their old command names, flags and exit status rules.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetMemoryLimit ¶
func SetMemoryLimit()
SetMemoryLimit keeps the heap near what is actually live: archive members and large files are held one at a time, and without a limit the collector lets the heap grow to about twice that. GOMEMLIMIT in the environment wins.
Types ¶
type Config ¶
type Config struct {
Tool string
Version string
// Detector pins a single detector (thin binaries). Empty: --detector picks.
Detector string
// Summary is the first line of the usage text.
Summary string
// AsRootDir makes --as-root take the system root directory as its value
// (php2shell-scan) instead of being a switch (emudhra-scan).
AsRootDir bool
// ErrorsFirst makes an error exit 2 even when something is vulnerable, and
// --exit-zero override everything else (php2shell-scan). Otherwise a
// vulnerable finding exits 1 first (emudhra-scan, the engine).
ErrorsFirst bool
}
Config describes one binary.
Click to show internal directories.
Click to hide internal directories.