Libtorrent: question regarding proxies

Created on 25 Jul 2020  路  12Comments  路  Source: arvidn/libtorrent

Please provide the following information

libtorrent version (or branch):
RC_1_2

please describe what symptom you see, what you would expect to see instead and
how to reproduce it.

Since this PR https://github.com/arvidn/libtorrent/pull/4498 got merged, does these settings mean anything anymore?

proxy_hostnames
proxy_peer_connections
proxy_tracker_connections

If not, then they can be safely removed?

All 12 comments

As per #4904 , PR #4498 in current state may be impeding certain use-cases, which would also benefit from this (or similar) options.

It's true that the patch you link to breaks the use case of only producing trackers. The support for proxies is currently tied pretty strongly to the listen interfaces (and the udp socket specifically).

The issue I was solving with that patch was to avoid having every listen socket open a proxy connection.

Maybe a better way to solve it, and still support the use case of proxying some connections but still accept connections as normal would be to open a separate "listen socket" that represents the proxy, that any proxies connection will go through.

However, I would expect that if all connections are proxied, one would not want to accept connections over the normal IP either.

I think it might make sense to revert #4498. If I make a PR, could someone test it?

I think it might make sense to revert #4498. If I make a PR, could someone test it?

What impact will this make to the users whose issue(s) were resolved with that patch?

ref https://github.com/arvidn/libtorrent/pull/4498#issuecomment-611948864 & does reverting it have any bearing on https://github.com/qbittorrent/qBittorrent/issues/12583?

I'm thinking of not reverting, but amending it to support this use case. I don't think it's as complicated as I thought. The case is where a proxy is configured, but proxy_connections is set to false, right?

@iamtakingiteasy @an0n666 I'll compile a windows x64 build with this patch included later this evening & post it here, can you test & report back then please.

@xavier2k6
Yes, that would be nice, thank you. It would've taken a few days on my own to build all dependencies for mingw target, i'm only on harfbuzz now.

I'm eager to pull the trigger on 1.2.8, and this is the last remaining patch I would like to land. It would be especially nice to have some affirmative tests first!

I'm eager to pull the trigger on 1.2.8, and this is the last remaining patch I would like to land. It would be especially nice to have some affirmative tests first!

@arvidn @iamtakingiteasy @an0n666 apologies - ~only getting around to compiling now.~

EDIT: UPLOADED

Windows test build of 4.3.0(Alpha1) with listed libraries:

qBittorrent master   | 4.3.0 +git 3a0ec8b
libtorrent-rasterbar | 1.2.7 +git b3739c0
Qt                   | 5.14.2
OpenSSL              | 1.1.1g
zlib                 | 1.2.11
Boost                | 1.73

"Windows Test Build" download link below:
qBittorrent + libtorrent patch #4909

Can confirm it is working as expected: trackers are contacted via proxy, while peer connections, DHT and UPNP are all unaffected.

thanks for making a test build and testing!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pavel-pimenov picture pavel-pimenov  路  5Comments

techtonik picture techtonik  路  12Comments

dessalines picture dessalines  路  7Comments

jbeich picture jbeich  路  5Comments

masudr4n4 picture masudr4n4  路  6Comments