ants watch is a DHT client monitoring tool. It is able to log the activity of all nodes in a DHT network by carefully
placing ants in the DHT keyspace. For nodes to utilize the DHT they need to perform routing table maintenance tasks.
These tasks consist of sending requests to several other nodes close to oneself in the DHT keyspace. ants watch
ensures that at least one of these requests will always hit one of the deployed ants. When a request hits an ant, we
record information about the requesting peer like agent version, supported protocols, IP addresses, and more.
{{< button href="https://github.com/probe-lab/ants-watch" >}}GitHub{{< /button >}}
ant is a lightweight libp2p DHT node, participating in the DHT
network, and logging incoming requests.ants participate in the DHT network as DHT server nodes. ants need to be dialable by other nodes in the network.
Hence, ants-watch must run on a public IP address either with port forwarding properly configured (including local
and gateway firewalls) or UPnP enabled.ants (i.e., spawns new ant nodes) at targeted locations in the keyspace in order to occupy and
watch the full keyspace.k closest nodes in the keyspace
and routing table updates by DHT client (and server) nodes need to find the k closest DHT server peers to
themselves. Therefore, placing approximately 1 ant node every k DHT server nodes can capture all DHT client nodes
over time.ants will record the existence of DHT client nodes approximately every 10 mins (or
whatever the routing table update interval is).ants as well as their location in the keyspace is adjusted
automatically.ants run from within the same process, sharing the same DHT records.ant queen is responsible for spawning, adjusting the number and monitoring the ants as well as gathering their
logs and persisting them to a central database.ants-watch does not operate like a crawler, where after one run the number of DHT client nodes is captured.ants-watch logs all received DHT requests and therefore, it must run continuously to provide the number of DHT
client nodes over time.ants-watch gather?ants watch can collect information about the requesting peer. Information gathered includes:
For detailed information on how to setup and deploy ants, please refer to the tool's Github
repository: https://github.com/probe-lab/ants-watch/blob/dev/README.md#setup.
Feel free to head over to the GitHub repository and dive in! Open an issue or submit PRs.
{{< button href="https://github.com/probe-lab/ants-watch" >}}GitHub{{< /button >}}