How do I get the entire list of addresses returned by the 'addr' response in bitcoin protocol?

asked 2019-10-01 01:27:50 +0000

Sajan gravatar image

After building the 'getaddr' message from a Bitcoin node, I managed getting the 'addr' response. In it, it contains a list of IP addresses of peer nodes. In some of the addr response, it is possible that one 'addr' response contains multiple IP addresses of peer nodes (I found this by checking the packet in Wireshark). Using pyshark, we can obtain the IP address of 'addr' response using the attribute bitcoin.address_address given that bitcoin.command == 'addr' However using bitcoin.address_address in pyshark only gives me a single IP address out of the entire list of IP addresses. Is there a possible way to retrieve the entire list of IP addresses?

Thank You

edit retag flag offensive close merge delete

Comments

Have you checked the output of tshark to see if it contains all the addresses, if it does then it would be a pyshark issue and you should raise it with the support channels for that project.

grahamb gravatar imagegrahamb ( 2019-10-01 07:35:48 +0000 )edit