bincapz

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Behavior

type Behavior struct {
	Description string `json:",omitempty" yaml:",omitempty"`
	// MatchStrings are all strings found relating to this behavior
	MatchStrings []string `json:",omitempty" yaml:",omitempty"`
	RiskScore    int
	RiskLevel    string `json:",omitempty" yaml:",omitempty"`

	RuleURL      string `json:",omitempty" yaml:",omitempty"`
	ReferenceURL string `json:",omitempty" yaml:",omitempty"`

	RuleAuthor    string `json:",omitempty" yaml:",omitempty"`
	RuleAuthorURL string `json:",omitempty" yaml:",omitempty"`

	RuleLicense    string `json:",omitempty" yaml:",omitempty"`
	RuleLicenseURL string `json:",omitempty" yaml:",omitempty"`

	DiffAdded   bool `json:",omitempty" yaml:",omitempty"`
	DiffRemoved bool `json:",omitempty" yaml:",omitempty"`
}

type DiffReport added in v0.5.0

type DiffReport struct {
	Added    map[string]FileReport `json:",omitempty" yaml:",omitempty"`
	Removed  map[string]FileReport `json:",omitempty" yaml:",omitempty"`
	Modified map[string]FileReport `json:",omitempty" yaml:",omitempty"`
}

type FileReport

type FileReport struct {
	Path   string
	SHA256 string
	// compiler -> x
	Error             string              `json:",omitempty" yaml:",omitempty"`
	Skipped           string              `json:",omitempty" yaml:",omitempty"`
	Meta              map[string]string   `json:",omitempty" yaml:",omitempty"`
	Syscalls          []string            `json:",omitempty" yaml:",omitempty"`
	Pledge            []string            `json:",omitempty" yaml:",omitempty"`
	Capabilities      []string            `json:",omitempty" yaml:",omitempty"`
	Behaviors         map[string]Behavior `json:",omitempty" yaml:",omitempty"`
	FilteredBehaviors int                 `json:",omitempty" yaml:",omitempty"`

	// The relative path we think this moved from.
	PreviousRelPath string `json:",omitempty" yaml:",omitempty"`
	// The levenshtein distance between the previous path and the current path
	PreviousRelPathScore float64 `json:",omitempty" yaml:",omitempty"`
	PreviousRiskScore    int     `json:",omitempty" yaml:",omitempty"`
	PreviousRiskLevel    string  `json:",omitempty" yaml:",omitempty"`

	RiskScore   int
	RiskLevel   string   `json:",omitempty" yaml:",omitempty"`
	PackageRisk []string `json:",omitempty" yaml:",omitempty"`

	IsBincapz bool `json:",omitempty" yaml:",omitempty"`
}

type IntMetric added in v0.10.0

type IntMetric struct {
	Count int
	Key   int
	Total int
	Value float64
}

type Report

type Report struct {
	Files  map[string]FileReport `json:",omitempty" yaml:",omitempty"`
	Diff   DiffReport            `json:",omitempty" yaml:",omitempty"`
	Filter string                `json:",omitempty" yaml:",omitempty"`
}

type StrMetric added in v0.10.0

type StrMetric struct {
	Count int
	Key   string
	Total int
	Value float64
}

Jump to

Keyboard shortcuts

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