Documentation
¶
Index ¶
Constants ¶
View Source
const (
SIRIUS_VALKEY = "sirius-valkey:6379"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HostVulnerabilityStat ¶ added in v0.0.12
type HostVulnerabilityStat struct {
HostIP string `json:"host_ip"`
Hostname string `json:"hostname,omitempty"`
Total int `json:"total"`
Critical int `json:"critical"`
High int `json:"high"`
Medium int `json:"medium"`
Low int `json:"low"`
Informational int `json:"informational"`
}
HostVulnerabilityStat represents vulnerability statistics for a specific host
type KVStore ¶
type KVStore interface {
// SetValue sets the given key to the specified value.
SetValue(ctx context.Context, key, value string) error
// SetValueWithTTL sets the given key to the specified value with a TTL in seconds.
SetValueWithTTL(ctx context.Context, key, value string, ttlSeconds int) error
// GetValue retrieves the value associated with the given key.
GetValue(ctx context.Context, key string) (ValkeyResponse, error)
// GetTTL retrieves the remaining TTL in seconds for the given key.
GetTTL(ctx context.Context, key string) (int, error)
// SetExpire sets the TTL for an existing key in seconds.
SetExpire(ctx context.Context, key string, ttlSeconds int) error
// ListKeys retrieves all keys matching the given pattern.
ListKeys(ctx context.Context, pattern string) ([]string, error)
// DeleteValue removes the value associated with the given key.
DeleteValue(ctx context.Context, key string) error
// Close shuts down the underlying connection.
Close() error
}
KVStore defines the key/value operations our store supports.
func NewValkeyStore ¶
NewValkeyStore creates a new store connected to sirius-valkey:6379.
type ScanResult ¶
type ScanResult struct {
ID string `json:"id"`
Status string `json:"status"`
Targets []string `json:"targets"`
Hosts []string `json:"hosts"`
HostsCompleted int `json:"hosts_completed"`
Vulnerabilities []VulnerabilitySummary `json:"vulnerabilities"`
StartTime string `json:"start_time"`
EndTime string `json:"end_time,omitempty"`
}
type SnapshotMetadata ¶ added in v0.0.12
type SnapshotMetadata struct {
TotalHosts int `json:"total_hosts"`
HostsWithVulnerabilities int `json:"hosts_with_vulnerabilities"`
ScanCoveragePercent float64 `json:"scan_coverage_percent"`
SnapshotDurationMs int64 `json:"snapshot_duration_ms"`
}
SnapshotMetadata contains metadata about the snapshot
type ValkeyResponse ¶
type ValkeyResponse struct {
Message ValkeyValue `json:"Message"`
Type string `json:"Type"`
}
type ValkeyValue ¶
type ValkeyValue struct {
Value string `json:"Value"`
}
type VulnerabilityCounts ¶ added in v0.0.12
type VulnerabilityCounts struct {
Total int `json:"total"`
Critical int `json:"critical"`
High int `json:"high"`
Medium int `json:"medium"`
Low int `json:"low"`
Informational int `json:"informational"`
}
VulnerabilityCounts represents the total counts of vulnerabilities by severity
type VulnerabilitySnapshot ¶ added in v0.0.12
type VulnerabilitySnapshot struct {
SnapshotID string `json:"snapshot_id"` // YYYY-MM-DD format
Timestamp time.Time `json:"timestamp"`
Counts VulnerabilityCounts `json:"counts"`
ByHost []HostVulnerabilityStat `json:"by_host"`
Metadata SnapshotMetadata `json:"metadata"`
}
VulnerabilitySnapshot represents a point-in-time vulnerability state
Click to show internal directories.
Click to hide internal directories.