I would like to get a list of recent, live is even better, of domains that pihole handled.
The purpose is to alert myself if a recently registered domain appear to be used by my network.
The steps:
- periodically, query/get the list of recent domains from pihole
- For each of those domains, get their age
- If age less than X days, alert myself
I have some idea on how to do step 2 and 3. What are the options for step 1 ?
Context: I am running pihole inside Docker container that use Unbound in another container as DN server. I can do scripting, API call, etc ...
I saw that there is pihole tail that seems to allow to watch what pihole is doing. But that is inside the docker container right ?
Pihole have database in SQLite : should I regularly query against those ?
Telnet API can be use with some scripting ?
Packe dump: but that will require some work to parse ?