Documentation ¶
Overview ¶
Package hunter contains secret hunting and file scanning tools.
Index ¶
- type Config
- type ConfigOption
- func WithFormat(reporter format.Reporter) ConfigOption
- func WithGitleaksConfig(g config.Config) ConfigOption
- func WithLogLevel(level string) ConfigOption
- func WithRedact(redact bool) ConfigOption
- func WithScanPath(path string) ConfigOption
- func WithTemplate(template string) ConfigOption
- func WithVerbose(verbose bool) ConfigOption
- func WithWorkers(count int) ConfigOption
- type Hunter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Reporter format.Reporter Gitleaks config.Config ScanPath string Verbose bool Redact bool Debug bool Workers int Template string }
Config takes all of the configurable parameters for a Hunter.
func NewConfig ¶ added in v0.5.9
func NewConfig(opts ...ConfigOption) *Config
NewConfig creates a Config instance.
type ConfigOption ¶ added in v0.7.0
type ConfigOption func(*Config)
ConfigOption is a convenient type alias for func(*Config).
func WithFormat ¶ added in v0.7.0
func WithFormat(reporter format.Reporter) ConfigOption
func WithGitleaksConfig ¶ added in v0.7.0
func WithGitleaksConfig(g config.Config) ConfigOption
func WithLogLevel ¶ added in v0.7.0
func WithLogLevel(level string) ConfigOption
func WithRedact ¶ added in v0.7.0
func WithRedact(redact bool) ConfigOption
func WithScanPath ¶ added in v0.7.0
func WithScanPath(path string) ConfigOption
func WithTemplate ¶ added in v0.7.0
func WithTemplate(template string) ConfigOption
func WithVerbose ¶ added in v0.7.0
func WithVerbose(verbose bool) ConfigOption
func WithWorkers ¶ added in v0.7.0
func WithWorkers(count int) ConfigOption
type Hunter ¶
type Hunter struct {
*Config
}
Hunter is the secret scanner.
func New ¶ added in v0.6.0
func New(opts ...ConfigOption) (*Hunter, error)
New creates an instance of the Hunter.
Click to show internal directories.
Click to hide internal directories.