Documentation
¶
Overview ¶
eventhorizon is a DNS sinkhole: it answers 0.0.0.0 for blocked domains and forwards everything else to an upstream resolver.
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
train
command
Command train builds the detection data embedded in eventhorizon and measures how well it works.
|
Command train builds the detection data embedded in eventhorizon and measures how well it works. |
|
internal
|
|
|
api
Package api serves eventhorizon's live data to local viewers like the TUI:
|
Package api serves eventhorizon's live data to local viewers like the TUI: |
|
apiclient
Package apiclient talks to eventhorizon's local API (internal/api).
|
Package apiclient talks to eventhorizon's local API (internal/api). |
|
cache
Package cache stores upstream replies and serves them again until their TTL runs out, counting TTLs down so clients see the true remaining time.
|
Package cache stores upstream replies and serves them again until their TTL runs out, counting TTLs down so clients see the true remaining time. |
|
control
Package control owns the active policy: it combines the blocklists and allowlist file (rebuilt on reload) with the user's own rules (changed at any time), and installs the result.
|
Package control owns the active policy: it combines the blocklists and allowlist file (rebuilt on reload) with the user's own rules (changed at any time), and installs the result. |
|
dash
Package dash holds the dashboard logic that does not depend on any terminal library: number formatting, the bar chart, and the event log.
|
Package dash holds the dashboard logic that does not depend on any terminal library: number formatting, the bar chart, and the event log. |
|
detect
Package detect finds signs of malware in DNS traffic that no blocklist knows about yet.
|
Package detect finds signs of malware in DNS traffic that no blocklist knows about yet. |
|
dnsmsg
Package dnsmsg parses DNS queries and builds the few responses a sinkhole needs.
|
Package dnsmsg parses DNS queries and builds the few responses a sinkhole needs. |
|
events
Package events fans out what the server does (queries, alerts) to any number of live viewers, such as the TUI.
|
Package events fans out what the server does (queries, alerts) to any number of live viewers, such as the TUI. |
|
forward
Package forward sends queries for chosen zones, such as your home network's "lan" or "home.arpa", to a chosen server instead of the upstreams.
|
Package forward sends queries for chosen zones, such as your home network's "lan" or "home.arpa", to a chosen server instead of the upstreams. |
|
guard
Package guard decides which clients may use the server: an allow list of networks, and a per client rate limit.
|
Package guard decides which clients may use the server: an allow list of networks, and a per client rate limit. |
|
lists
Package lists builds a blocklist set from local files and URLs.
|
Package lists builds a blocklist set from local files and URLs. |
|
paths
Package paths decides where eventhorizon keeps its files by default: your own rules, and the saved copies of downloaded blocklists.
|
Package paths decides where eventhorizon keeps its files by default: your own rules, and the saved copies of downloaded blocklists. |
|
policy
Package policy decides whether a domain is blocked.
|
Package policy decides whether a domain is blocked. |
|
psl
Package psl finds the registrable part of a domain name using the Public Suffix List (https://publicsuffix.org/list/).
|
Package psl finds the registrable part of a domain name using the Public Suffix List (https://publicsuffix.org/list/). |
|
punycode
Package punycode converts Unicode domain labels to the ASCII form used on the wire, e.g.
|
Package punycode converts Unicode domain labels to the ASCII form used on the wire, e.g. |
|
rules
Package rules stores the user's own allow and block decisions, made from the TUI or the API, in a small text file that survives restarts:
|
Package rules stores the user's own allow and block decisions, made from the TUI or the API, in a small text file that survives restarts: |
|
server
Package server answers DNS over UDP and TCP: parse, decide, then either answer from the sinkhole or forward the raw query upstream.
|
Package server answers DNS over UDP and TCP: parse, decide, then either answer from the sinkhole or forward the raw query upstream. |
|
stats
Package stats keeps running totals for the dashboard: counters, a per second history for graphs, and top N lists, all in fixed memory.
|
Package stats keeps running totals for the dashboard: counters, a per second history for graphs, and top N lists, all in fixed memory. |
|
upstream
Package upstream forwards queries to a list of resolvers with failover, over plain DNS or DNS over TLS.
|
Package upstream forwards queries to a list of resolvers with failover, over plain DNS or DNS over TLS. |
|
version
Package version reports which build of eventhorizon is running.
|
Package version reports which build of eventhorizon is running. |
Click to show internal directories.
Click to hide internal directories.

