package
Version:
v0.1.19
Opens a new window with list of versions in this module.
Published: Feb 27, 2026
License: Apache-2.0
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Emit sends a security event to the configured sink.
Emission is best-effort and never panics.
SetSink installs a sink for security events.
Passing nil restores the no-op sink.
type Event struct {
At time.Time `json:"at"`
Type EventType `json:"type"`
Component string `json:"component,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
Attrs map[string]string `json:"attrs,omitempty"`
}
Event is a structured security audit event.
EventType identifies a security-relevant event category.
const (
EventUnpinnedExecution EventType = "unpinned_execution"
EventInsecureBypass EventType = "insecure_bypass"
EventVerificationFail EventType = "verification_failure"
EventSSRFBlockedURL EventType = "ssrf_blocked_url"
EventResultBackfilled EventType = "result_backfilled"
)
type Sink interface {
HandleSecurityEvent(Event)
}
Sink receives emitted audit events.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.