Documentation ¶
Index ¶
- type AllFilesCallback
- type AllFilesCallbackData
- type Analyzer
- func (a *Analyzer) AddAnalyzerPlugin(aplug AnalyzerPluginType)
- func (a *Analyzer) AddData(key string, value string)
- func (a *Analyzer) AddInformational(filepath string, reason string)
- func (a *Analyzer) AddOffender(filepath string, reason string)
- func (a *Analyzer) CheckAllFilesWithPath(cb AllFilesCallback, cbdata AllFilesCallbackData, filepath string)
- func (a *Analyzer) CleanUp() error
- func (a *Analyzer) FileGet(filepath string) (string, error)
- func (a *Analyzer) FileGetSha256(filepath string) ([]byte, error)
- func (a *Analyzer) FsTypeSupported() (bool, string)
- func (a *Analyzer) GetFileInfo(filepath string) (fsparser.FileInfo, error)
- func (a *Analyzer) HasOffenders() bool
- func (a *Analyzer) ImageInfo() AnalyzerReport
- func (a *Analyzer) JsonReport() string
- func (a *Analyzer) RemoveFile(filepath string) error
- func (a *Analyzer) RunPlugins()
- type AnalyzerPluginType
- type AnalyzerReport
- type AnalyzerType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AllFilesCallback ¶
type AllFilesCallback func(fi *fsparser.FileInfo, fullpath string, data AllFilesCallbackData)
type AllFilesCallbackData ¶
type AllFilesCallbackData interface{}
type Analyzer ¶
type Analyzer struct { PluginReports map[string]interface{} AnalyzerReport // contains filtered or unexported fields }
func NewFromConfig ¶
func (*Analyzer) AddAnalyzerPlugin ¶
func (a *Analyzer) AddAnalyzerPlugin(aplug AnalyzerPluginType)
func (*Analyzer) AddInformational ¶
func (*Analyzer) AddOffender ¶
func (*Analyzer) CheckAllFilesWithPath ¶
func (a *Analyzer) CheckAllFilesWithPath(cb AllFilesCallback, cbdata AllFilesCallbackData, filepath string)
func (*Analyzer) FsTypeSupported ¶
func (*Analyzer) GetFileInfo ¶
func (*Analyzer) HasOffenders ¶
func (*Analyzer) ImageInfo ¶
func (a *Analyzer) ImageInfo() AnalyzerReport
func (*Analyzer) JsonReport ¶
func (*Analyzer) RemoveFile ¶
func (*Analyzer) RunPlugins ¶
func (a *Analyzer) RunPlugins()
type AnalyzerPluginType ¶
type AnalyzerReport ¶
type AnalyzerReport struct { FSType string `json:"fs_type"` ImageName string `json:"image_name"` ImageDigest string `json:"image_digest,omitempty"` Data map[string]interface{} `json:"data,omitempty"` Offenders map[string][]interface{} `json:"offenders,omitempty"` Informational map[string][]interface{} `json:"informational,omitempty"` }
type AnalyzerType ¶
type AnalyzerType interface { GetFileInfo(filepath string) (fsparser.FileInfo, error) RemoveFile(filepath string) error FileGetSha256(filepath string) ([]byte, error) FileGet(filepath string) (string, error) AddOffender(filepath string, reason string) AddInformational(filepath string, reason string) CheckAllFilesWithPath(cb AllFilesCallback, cbdata AllFilesCallbackData, filepath string) AddData(key, value string) ImageInfo() AnalyzerReport }
Click to show internal directories.
Click to hide internal directories.