Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Get IP addresses from udp and http torrent tracker response

I am trying to get the peer-list: list of IP addresses from a torrent tracker

Similar to the question here: how to get the peer list from torrent tracker response

I wrote code which decodes the torrent files using the python bencode Bit-torrent library I wrote code following this code here to scrape torrent tracker.

At least for http request like to mininova tracker I get the following output for a specific info_hash

{'files': {'\xbf\xff&\xcdY\x05\x9b\xb2C2j\x83\xf5F_\x9bg\x9d\xe2G': {'downloaded': 25416, 'complete': 12, 'incomplete': 0}}}

I do not see any of the other keys that the BitTorrent documents here in the spec. (like tracker_id, min_interval, peers ...etc)

How can I get the peer list?

like image 778
Saher Ahwal Avatar asked Nov 13 '13 19:11

Saher Ahwal


People also ask

Does Torrenting reveal your IP?

However, with torrenting and P2P networks, you might download part of a file from one user and the rest from another. The problem is that during this process, anyone who's downloading the file from you, and anyone you're downloading the file from, can see your IP address.

What is the use of trackers in uTorrent?

A BitTorrent tracker is a special type of server that assists in the communication between peers using the BitTorrent protocol.

How do I find a tracker for a specific torrent?

Right-click on the torrent you are downloading in uTorrent. Click on 'Properties' and add trackers with an empty line between the trackers. Click on the Ok button and trackers will be added to the torrent.


1 Answers

Not all torrents send you a peer list for scrape requests, in fact what I found is that barely any of the big ones do. You need to send them a request that you started downloading the torrent (at the announce URL), only then will you get a peer list. You can look at the binary data yourself to see if peers are there or not or you could upload a sample response for me.

like image 99
fejesjoco Avatar answered Sep 21 '22 05:09

fejesjoco