summaryrefslogtreecommitdiff
path: root/test/benc.c
diff options
context:
space:
mode:
authorJesper Jensen <jesper@jnsn.dev>2025-04-16 23:34:03 +0200
committerJesper Jensen <jesper@jnsn.dev>2025-04-16 23:34:03 +0200
commit188666dc51233051985715b01631e069a7939442 (patch)
tree83f9e51f431e11993eeabb763856298c0e042395 /test/benc.c
parent78a6d2ec1fb9c61cda1a8bcdc3843b159cdd850c (diff)
Add a first approximation of a lookup algorithm
This isn't really "correct" but it's probably going to work. It's a rough implementation of the Kademlia lookup algorithm, with the modification that we don't keep track of anything behind the frontier. We are therefore counting on peers being ok with us potentially sending them the "same" request multiple times. If they respond in a reasonable time, the double request rate _should_ be minimal, but that of course carries the risk that an already overloaded peer would get even more queries. I don't know. It's a first try at something. I need to see it work before I write it off completely.
Diffstat (limited to 'test/benc.c')
0 files changed, 0 insertions, 0 deletions