Skip to content

get all torrent hashes of a peer #173

@milahu

Description

@milahu

this would be helpful to subvert private trackers (BEP 27: Private Torrents)
(for ghostleeching)

usually peers who seed a specific torrent
also have other torrents which i may find interesting

such a query would allow to discover such similar torrents

this is similar to qBittorrent embedded tracker
but it runs on the same port as the bittorrent protocol

optionally, let the peer return only seeded torrents

default implementations would follow BEP 27:
dont return hashes of private torrents
but custom implementations could ignore BEP 27

related: BEP 51: DHT Infohash Indexing

possible implementation:
send handshake with empty btih 0000000000000000000000000000000000000000
(maybe also set some reserved bit in the handshake)
use this connection to request infohashes, similar to BEP 51
use BEP 9 to fetch metadata from the peer

alternative solution: run an http server with these paths

/cas.btih.hashes.txt
/cas.files.txt
/cas/btih/{btih}.torrent
/cas/btih/{btih}/Some.Dir/Some.File.txt
/hostnames.txt
/ports.txt

example:
http://milahu.duckdns.org/cas.btih.hashes.txt
http://milahu.duckdns.org/cas.files.txt
http://milahu.duckdns.org/hostnames.txt
http://milahu.duckdns.org/ports.txt
http://milahu.duckdns.org/cas/btih/339a4817bfd7f53cdb14e411f903dcc09b905570.torrent
http://milahu.duckdns.org/cas/btih/339a4817bfd7f53cdb14e411f903dcc09b905570/opensubtitles.org.dump.10200000.to.10299999.v20241124/info/info.txt

/cas/btih/{btih}.torrent
/cas/btih/{btih}/Some.Dir/Some.File.txt

see also the cas parameter in #171

when port 80 cannot be used, use the next port after the bittorrent port
example:

6881 bittorrent
6882 http

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @milahu

        Issue actions

          get all torrent hashes of a peer · Issue #173 · bittorrent/bittorrent.org