Integrate ASN bucketing in Addrman and add tests
Summary:
Instead of using /16 netgroups to bucket nodes in Addrman for connection diversification, ASN, which better represents an actor in terms of network-layer infrastructure, is used. For testing, asmap.raw is used. It represents a minimal asmap needed for testing purposes.
Partial backport 2/4 of core PR16702:
https://github.com/bitcoin/bitcoin/pull/16702/commits/ec45646de9e62b3d42c85716bfeb06d8f2b507dc
Depends on D8194.
Test Plan:
ninja check
Reviewers: #bitcoin_abc, jasonbcox
Reviewed By: #bitcoin_abc, jasonbcox
Subscribers: jasonbcox
Differential Revision: https://reviews.bitcoinabc.org/D8195