Documentation
¶
Overview ¶
Package report renders scan results into shareable Markdown and HTML documents, surfacing the service/version/TLS/risk intel that the table and tree views keep compact. Both formats are built from the same Report struct so they stay in sync.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CanOpen ¶
func CanOpen() bool
CanOpen reports whether opening a file in the desktop default app is supported and enabled. Setting NDSCAN_NO_OPEN disables it (for headless runs, CI, and tests).
func ExportDir ¶
ExportDir returns the directory exports are written to for a given time: ~/Downloads/ndscan/<YYYY-MM-DD>. NDSCAN_EXPORT_DIR overrides the base (~/Downloads/ndscan) — used by tests and for a custom location.
func ExportPath ¶
ExportPath builds the full path for an export of the given format at time `at`, creating the dated directory if needed. It returns the path to write.
Names are second-resolution, so two exports of the same format within one second would collide; the second and later get a "-2", "-3", … suffix rather than silently overwriting the earlier file.
Types ¶
type Report ¶
type Report struct {
Targets string // e.g. "192.168.86.0/24"
Preset string // quick|default|udp|deep
Generated string // caller-supplied human-readable timestamp
Rows []ui.Row
}
Report is the input to the renderers: the scanned rows plus context.