bitcoin/contrib/seeds
Ava Chow ceb1e078f8
Merge bitcoin/bitcoin#28793: contrib: Add asmap-tool
6abe772a17 contrib: Add asmap-tool (Fabian Jahr)

Pull request description:

  This adds `asmap.py` and `asmap-tool.py` from sipa's `nextgen` branch: https://github.com/sipa/asmap/tree/nextgen

  The motivation is that we should maintain the tooling for de- and encoding asmap files within the bitcoin core repository because it is not possible to use an asmap file that is not encoded.

  We already had an earlier version of `asmap.py` within the seeds contrib tools. The newer version only had a small amount of changes and is still compatible, so the old version is removed from contrib/seeds and the new version is made available to `makeseeds.py`.

ACKs for top commit:
  virtu:
    ACK [6abe772](6abe772a17)
  0xB10C:
    ACK 6abe772a17
  achow101:
    ACK 6abe772a17
  brunoerg:
    ACK 6abe772a17

Tree-SHA512: cc2a82ffa4eb46fa0ce4ca769dd82f8d0d2f37fc3652aa748eeb060e1142f9da4035008fe89433e2fd524a4dc153b7b9c085748944b49137b37009b0c0be8afb
2024-05-09 11:57:30 -04:00
..
.gitignore contrib: Use asmap for ASN lookup in makeseeds 2022-05-31 11:57:49 +02:00
README.md net: decouple state independent service flags from desirable ones 2024-01-15 10:28:20 -03:00
generate-seeds.py doc: update references to kernel/chainparams.cpp 2023-04-18 11:02:05 +01:00
makeseeds.py Merge bitcoin/bitcoin#28793: contrib: Add asmap-tool 2024-05-09 11:57:30 -04:00
nodes_main.txt seeds: Update mainnet seeds 2024-03-04 19:53:24 -05:00
nodes_main_manual.txt seeds: Update mainnet seeds 2024-03-04 19:53:24 -05:00
nodes_test.txt seeds: Update testnet seeds 2024-03-04 19:53:30 -05:00

README.md

Seeds

Utility to generate the seeds.txt list that is compiled into the client (see src/chainparamsseeds.h and other utilities in contrib/seeds).

Be sure to update PATTERN_AGENT in makeseeds.py to include the current version, and remove old versions as necessary (at a minimum when SeedsServiceFlags() changes its default return value, as those are the services which seeds are added to addrman with).

The seeds compiled into the release are created from sipa's DNS seed and AS map data. Run the following commands from the /contrib/seeds directory:

curl https://bitcoin.sipa.be/seeds.txt.gz | gzip -dc > seeds_main.txt
curl https://bitcoin.sipa.be/asmap-filled.dat > asmap-filled.dat
python3 makeseeds.py -a asmap-filled.dat -s seeds_main.txt > nodes_main.txt
cat nodes_main_manual.txt >> nodes_main.txt
python3 generate-seeds.py . > ../../src/chainparamsseeds.h