exploit

package
v0.21.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package exploit enriches a finding's severity with real-world exploitability signals: CISA KEV (Known Exploited Vulnerabilities — confirmed exploited in the wild) and FIRST EPSS (Exploit Prediction Scoring System — probability of exploitation). Data is loaded from local files (bring-your-own), so enrichment is optional and works offline.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadEPSS

func LoadEPSS(r io.Reader) (map[string]float64, error)

LoadEPSS parses a FIRST EPSS scores CSV (columns: cve,epss,percentile; leading #comment and header lines are ignored) into a CVE→score map. Source: https://www.first.org/epss/data_stats

func LoadKEV

func LoadKEV(r io.Reader) (map[string]bool, error)

LoadKEV parses the CISA Known Exploited Vulnerabilities JSON catalog into a CVE set. Source: https://www.cisa.gov/known-exploited-vulnerabilities-catalog

Types

type Source

type Source struct {
	// contains filtered or unexported fields
}

Source holds exploitability data plus the EPSS threshold for a severity bump.

func New

func New(kev map[string]bool, epss map[string]float64, threshold float64) *Source

New returns a Source. threshold is the EPSS probability (0–1) at or above which a finding's severity is bumped one band; a threshold ≤ 0 disables the EPSS bump (KEV still applies).

func (*Source) Empty

func (s *Source) Empty() bool

Empty reports whether the source carries no data (no enrichment possible).

func (*Source) Enrich

func (s *Source) Enrich(base sarif.Severity, ruleID string) sarif.Severity

Enrich raises base severity using exploitability signals for the CVE referenced by ruleID: on KEV → critical; else EPSS ≥ threshold → one band higher. Findings without a CVE ruleID (secrets, SAST, IaC) or with no matching data return base unchanged.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL