package scraper
import "github.com/Kajmany/rapidrule/scraper"
Abstraction over Operating System to 'scrape' current state of ports/processes/nftable rules as useful These are and should probably only be run once at init (much more model logic is required to 'refresh')
Index
- func CheckIfRoot() tea.Cmd
- func CheckTables() tea.Cmd
- func GetPorts() tea.Cmd
- type AlertError
- type AlertMsg
- type PortScrapeError
- type PortsMsg
Functions
func CheckIfRoot
func CheckIfRoot() tea.Cmd
func CheckTables
func CheckTables() tea.Cmd
Yes this is nft stuff not inside pkg nft but it makes sense here
func GetPorts
func GetPorts() tea.Cmd
Types
type AlertError
type AlertError struct { Err error }
Sent when we error'd attempting to check if we should alert
type AlertMsg
type AlertMsg struct { HasAlert bool Alert structs.Alert }
Sent when we have completed an alert check successfully Can be nil if we checked and there's no alert
type PortScrapeError
type PortScrapeError struct { Err error }
PortScrapeError is sent when port scraping fails
func (PortScrapeError) Error
func (e PortScrapeError) Error() string
type PortsMsg
type PortsMsg struct { Ports []structs.Port }
PortsMsg is sent when port scraping completes successfully