Documentation
¶
Overview ¶
Package semgrep provides data model, decoder, and validator for Semgrep reports
Index ¶
Constants ¶
View Source
const ConfigFieldName = "semgrep"
ConfigFieldName the field name in the config map
View Source
const ConfigType = "Semgrep Config"
ConfigType in plaintext
View Source
const ReportType = "Semgrep Scan Report"
ReportType in plaintext
Variables ¶
This section is empty.
Functions ¶
func NewReportDecoder ¶
func NewReportDecoder() *gce.JSONWriterDecoder[ScanReport]
NewReportDecoder implementation of generic JSON decoder with check function for simple field validation
func NewValidator ¶
NewValidator implementation generic validatork
Types ¶
type Config ¶
type Config struct {
Error int `json:"error" toml:"error" yaml:"error"`
Warning int `json:"warning" toml:"warning" yaml:"warning"`
Info int `json:"info" toml:"info" yaml:"info"`
}
Config data model
type ScanReport ¶
type ScanReport semgrep.SemgrepOutputV1Jsonschema
ScanReport is a data model for a Semgrep Output scan produced by `semgrep scan --json`
func (ScanReport) String ¶
func (r ScanReport) String() string
String pretty formatted table with all findings
Click to show internal directories.
Click to hide internal directories.