sarif

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const InformationURI = "https://github.com/Risk-Guard/risk-guard"
View Source
const RepoRootURI = "."

RepoRootURI is the artifact URI used to anchor results that have no file-specific location (repo-wide source findings, aggregate package checks, synthetic audit-error results). GitHub Code Scanning rejects any result whose location lacks a physicalLocation, so every result must resolve to at least this.

Variables

This section is empty.

Functions

func EnsurePhysicalLocations added in v0.0.5

func EnsurePhysicalLocations(report *sarif.Report)

EnsurePhysicalLocations guarantees every result in every run has a physicalLocation, as required by GitHub Code Scanning. Results that already carry one (on any of their locations) are left untouched; bare results are anchored at the repository root (RepoRootURI) with no region. This is the single invariant enforcer for the whole report, so it also covers synthetic runs (e.g. audit-error failure runs) and any future result emitter.

func FromEvaluationResult

func FromEvaluationResult(result *policy.EvaluationResult, checks []dag_builder.CheckInfo) (*sarif.Report, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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