|
3 months ago | |
---|---|---|
vendor | 3 months ago | |
.gitignore | 3 months ago | |
00.database.go | 3 months ago | |
00.memory.go | 3 months ago | |
01.conf.go | 3 months ago | |
01.dnscheck.go | 3 months ago | |
01.killfile.go | 3 months ago | |
01.stats.go | 3 months ago | |
02.cache.go | 3 months ago | |
Dockerfile.amd64 | 3 months ago | |
Dockerfile.arm32v7 | 3 months ago | |
Dockerfile.arm64v8 | 3 months ago | |
LICENSE | 3 months ago | |
README.md | 3 months ago | |
adlist_hosts.go | 3 months ago | |
adlist_single.go | 3 months ago | |
config.json | 3 months ago | |
dns-upstream.txt | 3 months ago | |
dns_client.go | 3 months ago | |
dns_handler.go | 3 months ago | |
go.mod | 3 months ago | |
go.sum | 3 months ago | |
hostfile.go | 3 months ago | |
main.go | 3 months ago | |
urls-domains.txt | 3 months ago | |
urls-hosts.txt | 3 months ago | |
urls-local.txt | 3 months ago |
Tiny replacement for piHole DNS filter
Still Work in progress, usable.
Idea is to produce a very simple, no-web-interface , IP DNS blocker.
Zabov requires golang 1.13 or later.
git clone https://git.keinpfusch.net/Loweel/zabov.git cd zabov go get go build -mod=vendor
Then, edit config.json: please notice config.json must be in the same folder of the executable you run.
Just a few words about "singlefilters" and "doublefilters":
Data must be downloaded from URLs of blacklist mantainers.They may come in different formats.
There are two kinds of blacklists:
One is the format zabov calls "singlefilter", where we find a single column , full of domains:
domain1.com domain2.com domain3.com
The second is the format zabov calls "doublefilter" (a file in "/etc/hosts" format, to be precise), where there is an IP, usually localhost or 0.0.0.0 and then the domain:
127.0.0.1 domain1.com 127.0.0.1 domain2.com 127.0.0.1 domain3.com
This is why configuration file has two separated items.
The config file should look like:
{ "zabov": { "port":"53", "proto":"udp", "ipaddr":"127.0.0.1", "upstream":"./dns-upstream.txt", "cachettl": "4", "killfilettl": "12", "singlefilters":"./urls-hosts.txt" , "doublefilters":"./urls-domains.txt", "blackholeip":"127.0.0.1", "hostsfile":"./urls-local.txt" } }
Where:
Multistage Dockerfiles are provided for AMD64, ARMv7, ARM64V8