bt_bencode icon indicating copy to clipboard operation
bt_bencode copied to clipboard

Add ByteIpAddr type serialize to byte representation

Open canoriz opened this issue 5 months ago • 0 comments

In BitTorrent BEP10, extend handshake sends IPv6/IPv4 address in a "compact form", which is the big-endian byte representation, represented by byte string length of 4(ipv4)/16(ipv6). This commit adds a ByteIpAddr type to serialize and deserialize between core::IpAddr and byte string representation.

canoriz avatar Jul 13 '25 10:07 canoriz