Documentation
¶
Overview ¶
Package api serves the alert feed, asset inventory, and live dashboard.
The dashboard is embedded in the binary with go:embed rather than built by a JavaScript toolchain and served from disk. That is a deliberate constraint: the point of this project is a single static binary with no runtime dependencies, and a UI that needs `npm install` before it will start would undo that for the sake of a framework nobody looking at a network sensor cares about.
Index ¶
Constants ¶
View Source
const DefaultMaxAlerts = 5000
DefaultMaxAlerts bounds the in-memory alert ring.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server exposes the sensor's state over HTTP.
func (*Server) ListenAndServe ¶
ListenAndServe runs the server until ctx is cancelled.
Click to show internal directories.
Click to hide internal directories.