rakshasa / rtorrent

rTorrent BitTorrent client
https://github.com/rakshasa/rtorrent/wiki
GNU General Public License v2.0
4.15k stars 412 forks source link

allow set multiple `network.local_address` #1230

Closed trim21 closed 5 months ago

trim21 commented 1 year ago

I'm trying to report ipv4 and ipv6 address to tracker, is it possible to set multiple IP address as network.local_address?

method.insert = get_public_ip_address, simple|private, "execute.capture=bash,-c,\"eval echo -n \$(dig -4 TXT +short o-o.myaddr.l.google.com @ns1.google.com)\""
# The IP address reported to the tracker. (ip) This handles dynamic IP's as well.
schedule2 = ip_tick, 0, 1800, "network.local_address.set=(get_public_ip_address)"

maybe use a ; seprated string? 1.1.1.1;[1::1]

# Get public IP address without the need of having dynamic DNS service, also works from behind NAT, through tunnel
method.insert = get_public_ipv4_address, simple|private, "execute.capture=bash,-c,\"eval echo -n \$(dig -4 TXT +short o-o.myaddr.l.google.com @ns1.google.com)\""
method.insert = get_public_ipv6_address, simple|private, "execute.capture=bash,-c,\"eval echo -n \$(dig -6 TXT +short o-o.myaddr.l.google.com @ns1.google.com)\""
# The IP address reported to the tracker. (ip) This handles dynamic IP's as well.
schedule2 = ip_tick, 0, 1800, "network.local_address.set=(get_public_ipv4_address);(get_public_ipv6_address)"
kannibalox commented 1 year ago

Not currently. Even if rtorrent supported it, trackers would have to support parsing it as well, and from a quick search I couldn't find any trackers that do.

trim21 commented 1 year ago

Not currently. Even if rtorrent supported it, trackers would have to support parsing it as well, and from a quick search I couldn't find any trackers that do.

make multiple announce requests for multiple addresses