mirror of
https://github.com/anchore/syft.git
synced 2025-11-17 16:33:21 +01:00
* add initial secrets cataloger Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * update ETUI elements with new catalogers (file metadata, digests, and secrets) Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * update secrets cataloger to read full contents into memory for searching Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * quick prototype of parallelization secret regex search Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * quick prototype with single aggregated regex Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * quick prototype for secret search line-by-line Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * quick prototype hybrid secrets search Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * add secrets cataloger with line strategy Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * adjust verbiage towards SearchResults instead of Secrets + add tests Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * update json schema with secrets cataloger results Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * address PR comments Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * update readme with secrets config options Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * ensure file catalogers call AllLocations once Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
20 lines
1.3 KiB
Go
20 lines
1.3 KiB
Go
package config
|
|
|
|
import "github.com/spf13/viper"
|
|
|
|
type anchore struct {
|
|
// upload options
|
|
Host string `yaml:"host" json:"host" mapstructure:"host"` // -H , hostname of the engine/enterprise instance to upload to (setting this value enables upload)
|
|
Path string `yaml:"path" json:"path" mapstructure:"path"` // override the engine/enterprise API upload path
|
|
// IMPORTANT: do not show the username in any YAML/JSON output (sensitive information)
|
|
Username string `yaml:"-" json:"-" mapstructure:"username"` // -u , username to authenticate upload
|
|
// IMPORTANT: do not show the password in any YAML/JSON output (sensitive information)
|
|
Password string `yaml:"-" json:"-" mapstructure:"password"` // -p , password to authenticate upload
|
|
Dockerfile string `yaml:"dockerfile" json:"dockerfile" mapstructure:"dockerfile"` // -d , dockerfile to attach for upload
|
|
OverwriteExistingImage bool `yaml:"overwrite-existing-image" json:"overwrite-existing-image" mapstructure:"overwrite-existing-image"` // --overwrite-existing-image , if any of the SBOM components have already been uploaded this flag will ensure they are overwritten with the current upload
|
|
}
|
|
|
|
func (cfg anchore) loadDefaultValues(v *viper.Viper) {
|
|
v.SetDefault("anchore.path", "")
|
|
}
|