upnp uses wrong IP address

Bug #748623 reported by Jordan Bradley
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
DC++
Fix Released
Medium
Unassigned

Bug Description

I use LogMeIn Hamachi to connect to a friend's computer to play Minecraft. The Hamachi VPN device's IP address is 5.227.153.183, I set DC++ to bind to 192.168.1.7 which is my motherboard's LAN chip. Despite setting the bind address, DC++ still uses my VPN device's IP address in its uPnP configuration with the router instead of the physical address preventing me from connecting to others in the hub.

Revision history for this message
eMTee (realprogger) wrote :

DC++ version? What connection mode do you use, automatic or manual with UPnP selected?

Changed in dcplusplus:
status: New → Incomplete
Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

I'm using DC++ 0.782, with manual UPnP selected.

Revision history for this message
eMTee (realprogger) wrote :

In the Connection Settings pane, Is there anything set in the External / WAN IP box? What is the state of the
Don't allow hub/UPnP to override checkbox? What is the result if you type '/connection' command in a hub's mainchat?

Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

In the External / WAN IP box it has the IP assigned to my router from my ISP. The "Don't allow hub/UPnP to override" option is disabled. When I type "/connection" I get "IP: 99.246.103.??, Port: 49363/55077/49364"

Revision history for this message
eMTee (realprogger) wrote :

Your DC++ is communicating with the router and this can be possible through the bound physical interface only. If DC++ would be bound to the VPN interface, you couldn't get UPnP response, nor connect to any hubs. You also got the right external IP (99.246.103.?? this should be your external IP assigned by the ISP, right?), that's another proof, and you see, DC++ uses this IP.

"DC++ still uses my VPN device's IP address in its uPnP configuration with the router" <- where do you see this?
Does the problem go away if you disable the VPN interface?

Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

>"DC++ still uses my VPN device's IP address in its uPnP configuration with the router" <- where do you see this?
Please see attached picture. On the far right you'll see the UPnP settings given to my router by DC++, on the left side you'll see the IP of my VPN device and of my LAN chip as well as the bind address set for DC++

>Does the problem go away if you disable the VPN interface?
Yes, however this is not a practical solution because disabling the VPN interface causes hamachi to not work properly. So if I want to play Minecraft with my friends, I have to reboot.

Revision history for this message
eMTee (realprogger) wrote :

>Yes, however this is not a practical solution
I didn't offered this as a solution but for test only, to see if really the binding is your problem. But the screenshot tells that something's not ok, indeed.

My tests show that even if I set my DC++ binding to a virtual (VMWare) network interface, MiniUPnPc still finds my router so I guess its either using the inaddr_any interface or discovering UPnP in every existing interface. Both cases are bad, it should find UPnP capable devices through and map ports only to the interface DC++ is bound to.

Changed in dcplusplus:
status: Incomplete → Confirmed
importance: Undecided → Medium
Revision history for this message
poy (poy) wrote :

try rev 2481 (not tested).

Changed in dcplusplus:
status: Confirmed → Fix Committed
Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

Okay I found rev 2481, but I don't know what to do so that I can compile it for Windows.

Revision history for this message
eMTee (realprogger) wrote :

Here's a debug build of r2481 to test : http://www.sendspace.com/file/pbbne1

Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

I tried r2481, put it in the DC++ folder and started it. The same thing still occurs. I see the IP of my VPN device in my router's UPnP configuration.

Revision history for this message
poy (poy) wrote :

ok, there was a param to a MiniUPnP call which seemed like it could be useful in this case but i guess it's not. going to ask the MiniUPnP author for more information.

Changed in dcplusplus:
status: Fix Committed → New
Revision history for this message
poy (poy) wrote :
Revision history for this message
poy (poy) wrote :

should be fixed in rev 2484.

Changed in dcplusplus:
status: New → Fix Committed
Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

Could you make a binary so I could test it please?

Revision history for this message
iceman50 (bdcdevel) wrote :

I will compile you a Visual C version of DC++ but please note as of right now the TransferView and FinishedFrame are currently under 'construction' so let me know if it works and i can get them working for you

Revision history for this message
eMTee (realprogger) wrote :
Revision history for this message
Jordan Bradley (jordan-w-bradley) wrote :

I tried it now and it works fine

Revision history for this message
poy (poy) wrote :

Fixed in DC++ 0.790.

Changed in dcplusplus:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.