Opened 15 years ago
Closed 15 years ago
#583 closed Enhancement (duplicate)
allow user to specify source port for outgoing connections
Reported by: | wfaulk | Owned by: | charles |
---|---|---|---|
Priority: | Normal | Milestone: | None Set |
Component: | libtransmission | Version: | 1.02+ |
Severity: | Normal | Keywords: | |
Cc: | wfaulk |
Description
Allowing the user to select a source port (or set of source ports) for outgoing connections would be helpful in matching packets for prioritizing traffic.
Change History (11)
comment:1 Changed 15 years ago by charles
comment:2 Changed 15 years ago by charles
- Resolution set to invalid
- Status changed from new to closed
comment:3 Changed 15 years ago by bgilmore
- Component changed from Transmission to libtransmission
- Resolution invalid deleted
- Status changed from closed to reopened
Speaking on behalf of the reporter:
In libtransmission/net.c:110, tr_NetOpen would need to be modified to bind(2) to a sockaddr.
From the Advanced Network Settings page on the Azureus wiki:
This sets outgoing connections to a fixed source port. This can be used with full cone NAT routers to reduce the number of NAT table entries and thus prevent crashes on some router models. When the outgoing port is bound to the same as the incoming port that might even solve NAT problems on full cone NAT routers.
note: not endorsing the enh request, just clarifying it
-bg
comment:4 Changed 15 years ago by wfaulk
Correct. Right now when Transmission opens a TCP connection to a remote peer, the source port is chosen randomly by the OS. Having Transmission specify it would allow me to match connections based on that port so that my QoS router can throttle those connections. Right now, it cannot, since those connections have a random port on my end and whatever port the remote peer has chose on the other end. And since connections are largely encrypted, they cannot be inspected to determine that they are bittorrent connections.
comment:5 Changed 15 years ago by charles
- Milestone changed from None Set to 1.10
Sounds like a good idea... anyone want to submit a patch?
comment:6 Changed 15 years ago by charles
- Owner set to charles
- Status changed from reopened to new
comment:7 Changed 15 years ago by charles
- Milestone changed from 1.10 to None Set
This is disabled by default in Azureus, and the wiki contains this note: "Binding to the same port as the incoming port works under Windows 2k and greater only. Unix users should use a different port. It's not working at all under Mac OS X. " Maybe there are portability problems with this?
comment:8 Changed 15 years ago by wfaulk
It need not be the same port. Specifying a different port (or, more likely, set of ports) is a perfectly acceptable solution. The user just needs to know in advance what outgoing bittorrent connections are going to look like.
comment:9 Changed 15 years ago by wfaulk
- Cc wfaulk added
comment:10 Changed 15 years ago by charles
Is this this same as #776?
comment:11 Changed 15 years ago by charles
- Resolution set to duplicate
- Status changed from new to closed
I'm afraid I don't understand what you mean by "source port for outgoing connections".