types

package
v1.0.10 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2025 License: MIT Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Finding

type Finding struct {
	ID         string            `json:"id"`
	RuleID     string            `json:"rule_id"`
	File       string            `json:"file"`
	Line       int               `json:"line"`
	Column     int               `json:"column"`
	Message    string            `json:"message"`
	Severity   string            `json:"severity"`
	Confidence float64           `json:"confidence"`
	CryptoType string            `json:"crypto_type"`
	Algorithm  string            `json:"algorithm"`
	KeySize    int               `json:"key_size,omitempty"`
	Context    string            `json:"context"`
	Suggestion string            `json:"suggestion"`
	References []string          `json:"references,omitempty"`
	Metadata   map[string]string `json:"metadata,omitempty"`
	Timestamp  time.Time         `json:"timestamp"`
}

Finding represents a detected cryptographic usage

type Location

type Location struct {
	Path    string `json:"path"`
	Line    int    `json:"line"`
	Column  int    `json:"column"`
	Content string `json:"content"`
}

Location represents where a finding was detected

type Report

type Report struct {
	Findings []Finding `json:"findings"`
}

Report represents the output of a scan

type ScanMetadata

type ScanMetadata struct {
	Version     string                 `json:"version"`
	ScanPath    string                 `json:"scan_path"`
	StartTime   time.Time              `json:"start_time"`
	EndTime     time.Time              `json:"end_time"`
	RulesLoaded int                    `json:"rules_loaded"`
	Config      map[string]interface{} `json:"config"`
}

ScanMetadata holds scan execution metadata

type ScanResult

type ScanResult struct {
	Summary  ScanSummary  `json:"summary"`
	Findings []Finding    `json:"findings"`
	Errors   []string     `json:"errors,omitempty"`
	Metadata ScanMetadata `json:"metadata"`
}

ScanResult represents the complete scan results

type ScanSummary

type ScanSummary struct {
	TotalFiles         int            `json:"total_files"`
	ScannedFiles       int            `json:"scanned_files"`
	TotalFindings      int            `json:"total_findings"`
	FindingsBySeverity map[string]int `json:"findings_by_severity"`
	FindingsByType     map[string]int `json:"findings_by_type"`
	RiskScore          float64        `json:"risk_score"`
	DurationSeconds    float64        `json:"duration_seconds"`
}

ScanSummary provides high-level scan statistics

Jump to

Keyboard shortcuts

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