You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 20, 2024. It is now read-only.
I'm trying to cobble something together to take a torrent / magnet as input, get the HASH and Trackers, then verify that there are at lease X seeds active. I found your library on a stackoverflow there and wondering if you could suggest a method.
My attempt so far has failed with either "TypeError: Odd-length string" or bombed due to domain not existing.
I'm trying to cobble something together to take a torrent / magnet as input, get the HASH and Trackers, then verify that there are at lease X seeds active. I found your library on a stackoverflow there and wondering if you could suggest a method.
My attempt so far has failed with either "TypeError: Odd-length string" or bombed due to domain not existing.
excerpt
Open torrent file
torrent_file = open(sys.argv[1], "rb")
metainfo = bencode.bdecode(torrent_file.read())
info = metainfo['info']
print metainfo['announce']
print hashlib.sha1(bencode.bencode(info)).hexdigest()
torrent_hash = hashlib.sha1(bencode.bencode(info)).hexdigest()
tracker = metainfo['announce']
scrape(tracker,torrent_hash)
The text was updated successfully, but these errors were encountered: