#496654 amule: UPnP failing to open ports on router from a multi-homed machine

Package:
amule
Source:
amule
Description:
client for the eD2k and Kad networks, like eMule
Submitter:
Osiris X
Date:
2026-10-03 20:15:16 UTC
Severity:
important
#496654#5
Date:
2008-08-26 13:54:22 UTC
From:
To:
I have a multi-homed machine with 2 interfaces - eth0 (192.168.0.1) & eth1 (192.168.1.x). My router is
connected to eth1 and has ip address 192.168.1.254. When I run aMule on this machine it starts up and
appears to bind the UPnP port TCP/50000 to eth0 instead of eth1, regardless of whether I set a bind
address in the aMule preferences or not. (NB. according to 'netstat -ap' aMule binds the UPnP port
TCP/50000 to all interfaces). It then fails to detect any WAN service - see aMule log below:

2008-08-26 14:06:44: UPnPBase.cpp(868): Universal Plug and Play: bound to 192.168.0.1:50000.
2008-08-26 14:06:44: UPnPBase.cpp(939): Universal Plug and Play: UPnP Error:
CUPnPControlPoint::AddPortMapping: WAN Service not detected.

However a short time later, after 'Low-ID' connection to the ED2K network and 'firewalled' connection
to the KAD network, aMule finally notices that there is a UPnP capable router accessible through eth1
and the aMule log shows:

2008-08-26 14:22:11: UPnPBase.cpp(562): Universal Plug and Play: Uninteresting service detected:
'urn:schemas-upnp-org:service:WANDSLLinkConfig:1'. Ignoring.
2008-08-26 14:22:11: UPnPBase.cpp(545): Universal Plug and Play: WAN Service Detected:
'urn:schemas-upnp-org:service:WANIPConnection:1'.
2008-08-26 14:22:11: UPnPBase.cpp(1529): Universal Plug and Play: Successfully retrieved SCPD Document
for service urn:schemas-upnp-org:service:WANIPConnection:1, absEventSubURL:
http://192.168.1.254:80/upnp/event/igd/wanipcRoutedEthoA.
2008-08-26 14:22:11: UPnPBase.cpp(1543): Universal Plug and Play: Successfully subscribed to service
urn:schemas-upnp-org:service:WANIPConnection:1, absEventSubURL:
http://192.168.1.254:80/upnp/event/igd/wanipcRoutedEthoA.
2008-08-26 14:22:11: UPnPBase.cpp(562): Universal Plug and Play: Uninteresting service detected:
'urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1'. Ignoring.
2008-08-26 14:22:11: UPnPBase.cpp(562): Universal Plug and Play: Uninteresting service detected:
'urn:schemas-upnp-org:service:Layer3Forwarding:1'. Ignoring.

However it still does not open any ports on my router (192.168.1.254).

Afterwards I periodically get the following message in the aMule log:

2008-08-26 14:52:02: UPnPBase.cpp(1338): Universal Plug and Play: UPNP_EVENT_AUTORENEWAL_FAILED:
Re-subscribed to EventURL 'http://192.168.1.254:80/upnp/event/igd/wanipcRoutedEthoA' with SID ==
'uuid:28e0dce2-1dd2-11b2-91d7-f7e3500ea8f3'.

Any ideas on how I can fix this? Is this something that tweaking a parameter in the source and
re-compiling could fix?

Thanks in advance.

Os

#496654#10
Date:
2008-09-06 19:29:53 UTC
From:
To:
On reflection, it is entirely possible that this problem is router
specific.

My router is a Thomson Speedtouch 585 provided by the ISP Be (UK). This
router is highly configurable from a CLI, so maybe there are options I
could alter to make it work with aMule.

However it should be noted that the Deluge Bittorrent Client v0.5.9.3
and Skype v2.0.0.72 both successfully use UPnP to open ports on the
router when run from my debian linux system.

I am running an iptables firewall on this debian machine

iptables -A INPUT -i <router if> -s <router IP> -d 224.0.0.0/4 -j ACCEPT

iptables -A INPUT -i <router if> -p udp -s <router IP> --sport 1900
--dport $UNPRIVPORTS -j ACCEPT

iptables -A INPUT -i <router if> -p udp -s <router IP> --dport 1900
--sport $UNPRIVPORTS -j ACCEPT

iptables -A OUTPUT -o $ext_iface -p tcp --sport $UNPRIVPORTS -j ACCEPT
iptables -A OUTPUT -o $ext_iface -p udp --sport $UNPRIVPORTS -j ACCEPT





Any help, pointers or solutions you could provide would be most welcome.

Regards

Os

#496654#15
Date:
2008-09-06 19:51:37 UTC
From:
To:
[please remove / ignore the previous message]

On reflection, it is entirely possible that this problem is router
specific.

My router is a Thomson Speedtouch 585 provided by the ISP Be (UK). This
router is highly configurable from a CLI, so maybe there are options I
could alter to make it work with aMule.

However it should be noted that the Deluge Bittorrent Client v0.5.9.3
and Skype v2.0.0.72 both successfully use UPnP to open ports on the
router when run from my debian linux system.

I am running an iptables firewall on this debian machine. Below are the rules
I have used allow UPnP SSDP packets (both to and from port 1900 and
multicast)

iptables -A INPUT -i  -s  -d 224.0.0.0/4 -j ACCEPT

iptables -A INPUT -i  -p udp -s  --sport 1900
--dport $UNPRIVPORTS -j ACCEPT

iptables -A INPUT -i  -p udp -s  --dport 1900
--sport $UNPRIVPORTS -j ACCEPT

iptables -A OUTPUT -o  -d 224.0.0.0/4 -j ACCEPT
iptables -A OUTPUT -o  -p tcp --sport  -j ACCEPT
iptables -A OUTPUT -o  -p udp --sport  -j ACCEPT

In addition I have added the following aMule specific rules relating to my
specific aMule config:

iptables -A INPUT -i  -p tcp --dport  --sport
 -j ACCEPT(syn-flood checked)
iptables -A INPUT -i  -p udp --dport  --sport
 -j ACCEPT
iptables -A INPUT -i  -p udp --dport
--sport  -j ACCEPT
iptables -A INPUT -i  -p tcp --dport
--sport  -j ACCEPT(syn-flood checked)

I believe these rules should be sufficient.

Any help, pointers or solutions on how to aMule UPnP to successfully open
ports on my router would be most welcome.

Regards

Os

#496654#20
Date:
2008-09-06 20:03:27 UTC
From:
To:
[please remove / ignore the previous 2 messages]

On reflection, it is entirely possible that this problem is router
specific.

My router is a Thomson Speedtouch 585 provided by the ISP Be (UK). This
router is highly configurable from a CLI, so maybe there are options I
could alter to make it work with aMule.

However it should be noted that the Deluge Bittorrent Client v0.5.9.3
and Skype v2.0.0.72 both successfully use UPnP to open ports on the
router when run from my debian linux system.

I am running an iptables firewall on this debian machine. Below are the rules
I have used allow UPnP SSDP packets (both to and from port 1900 and
multicast)

iptables -A INPUT -i [router if] -s [router ip] -d 224.0.0.0/4 -j ACCEPT

iptables -A INPUT -i [router if] -p udp -s [router ip] --sport 1900
--dport [ports 1025+] -j ACCEPT

iptables -A INPUT -i [router if] -p udp -s [router ip] --dport 1900
--sport [ports 1025+] -j ACCEPT

iptables -A OUTPUT -o [router if] -d 224.0.0.0/4 -j ACCEPT
iptables -A OUTPUT -o [router if] -p tcp --sport [ports 1025+] -j ACCEPT
iptables -A OUTPUT -o [router if] -p udp --sport [ports 1025+] -j ACCEPT

In addition I have added the following aMule specific rules relating to my
specific aMule config:

iptables -A INPUT -i [router if] -p tcp --dport [aMule TCP port] --sport
[ports 1025+] -j ACCEPT(syn-flood checked)
iptables -A INPUT -i [router if] -p udp --dport [aMule UDP port] --sport
[ports 1025+] -j ACCEPT
iptables -A INPUT -i [router if] -p udp --dport [aMule Extended UDP port]
--sport [ports 1025+] -j ACCEPT
iptables -A INPUT -i [router if] -p tcp --dport [aMule UPnP port]
--sport [ports 1025+] -j ACCEPT(syn-flood checked)

I believe these rules should be sufficient.

Any help, pointers or solutions on how to aMule UPnP to successfully open
ports on my router would be most welcome.

Regards

Os

#496654#25
Date:
2009-09-08 22:04:16 UTC
From:
To:
I have the same problem with a Sitecom wireless router, but I have tried
with a SpeedTouch router too, and it works fine.

#496654#30
Date:
2009-12-29 13:37:59 UTC
From:
To:
Hi,

Is this port the same one, your router waits for UPnP requests?

#496654#35
Date:
2010-05-01 02:03:21 UTC
From:
To:
I have a very similar issue. My machine is getting an IP from both dhcp and
avahi-autoipd. Amule is connecting OK but firewalled through the dhcp assigned
IP address, and trying to do UPnP via the avahi-autoipd assigned address.

In the aMule log:
2010-05-01 02:18:36: Universal Plug and Play: bound to 169.254.6.101:50000.
2010-05-01 02:18:36: Universal Plug and Play: UPnP Error: CUPnPControlPoint::AddPortMapping: WAN Service not detected.

As can be seen in the ifconfig output below the avahi link and IP address
is on eth0 which has no network cable plugged in, making it very unlikely
for the UPnP to be successful! I never use avahi anyway so the solution
for me is uninstalling it but this will probably catch other people out.

$/sbin/ifconfig
eth0      Link encap:Ethernet  HWaddr 00:13:a9:2b:10:a6
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:18

eth0:avahi Link encap:Ethernet  HWaddr 00:13:a9:2b:10:a6
          inet addr:169.254.6.101  Bcast:169.254.255.255  Mask:255.255.0.0
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          Interrupt:18

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:5805 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5805 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:2164255 (2.0 MiB)  TX bytes:2164255 (2.0 MiB)

wlan0     Link encap:Ethernet  HWaddr 00:13:02:3f:e6:2b
          inet addr:192.168.0.64  Bcast:192.168.0.255  Mask:255.255.255.0
          inet6 addr: fe80::213:2ff:fe3f:e62b/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:45633 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26437 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:35467177 (33.8 MiB)  TX bytes:6599386 (6.2 MiB)

#496654#42
Date:
2011-04-25 19:13:59 UTC
From:
To:
Hi all,

Is this bug still actual? couldn't it be router-specific or libupnp3
and so not related to amule? If someone can still replicate it and can
debug it further it would really be helpful.

Regards,

#496654#47
Date:
2011-05-14 11:03:42 UTC
From:
To:
Hi all,

Sorry about the delay responding the message, but the last months I was very
busy. Let me 1 or 2 weeks to make some probes, and I'll tell you if the
problem still exists and any other information that can help.

Greetings, David

2011/4/25 Sandro Tosi <morph@debian.org>

#496654#52
Date:
2011-05-15 22:52:28 UTC
From:
To:
Well, as I said in my last message, this is the amule output when it starts
using UPnP:

#####################################################################
2011-05-15 23:42:18: Starting aMule 2.2.6 using wxGTK2 v2.8.10
2011-05-15 23:42:18: Archivo de créditos cargado, 247 clientes conocidos
2011-05-15 23:42:18: Cargando filtros IP 'ipfilter.dat' y
'ipfilter_static.dat'
2011-05-15 23:42:18: Cargado 0 rangos IP desde
'/home/larcen/.aMule/ipfilter.dat'. 0 líneas malformadas fueron descartadas
2011-05-15 23:42:18: Cargado 0 rangos IP desde
'/home/larcen/.aMule/ipfilter_static.dat'. 0 líneas malformadas fueron
descartadas
2011-05-15 23:42:18: Conexiones externas deshabilitadas en el archivo de
configuración
2011-05-15 23:42:18: Created Client UDP-Socket at port 4672
2011-05-15 23:42:18: Universal Plug and Play: bound to 192.168.1.134:50000.
2011-05-15 23:42:18: Universal Plug and Play: UPnP Error:
CUPnPControlPoint::AddPortMapping: WAN Service not detected.

2011-05-15 23:42:18:  - Esto es aMule 2.2.6 using wxGTK2 v2.8.10 basado en
eMule.
2011-05-15 23:42:18:    Ejecutándose en Linux 2.6.32-5-686 i686
2011-05-15 23:42:18:  - Visita http://www.amule.org para comprobar si hay
una nueva versión disponible

2011-05-15 23:42:18: Cargadas 248 fotos de banderas.
2011-05-15 23:42:18: Cargando archivo server.met:
/home/larcen/.aMule/server.met
2011-05-15 23:42:18: 0 servidores encontrados en server.met
2011-05-15 23:42:18: Encontrado 17 partes de archivo
2011-05-15 23:42:18: Encontrado 55 archivos compartidos
2011-05-15 23:42:18: Conectando
2011-05-15 23:42:18: Leídos 200 contactos Kad
2011-05-15 23:42:19: ThreadScheduler: Completed task 'AICH Syncronizing', 0
tasks remaining.
2011-05-15 23:42:19: Tu copia de aMule está actualizada.
2011-05-15 23:51:21: Universal Plug and Play: WAN Service Detected:
'urn:schemas-upnp-org:service:WANIPConnection:1'.
2011-05-15 23:51:21: Universal Plug and Play: Successfully retrieved SCPD
Document for service urn:schemas-upnp-org:service:WANIPConnection:1,
absEventSubURL: http://192.168.1.1:80/WANIPConnection.
2011-05-15 23:51:21: Universal Plug and Play: Successfully subscribed to
service urn:schemas-upnp-org:service:WANIPConnection:1, absEventSubURL:
http://192.168.1.1:80/WANIPConnection.
2011-05-15 23:51:21: Universal Plug and Play: Uninteresting service
detected: 'urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1'.
Ignoring.
2011-05-15 23:51:21: Universal Plug and Play: Uninteresting service
detected: 'urn:schemas-upnp-org:service:Layer3Forwarding:1'. Ignoring.
2011-05-15 23:51:21: Universal Plug and Play: UPNP_EVENT_RECEIVED:
2011-05-15 23:51:21:     SID: uuid:78ddf376-1dd2-11b2-945e-f08b06ed30ec
2011-05-15 23:51:21:     Key: 0
2011-05-15 23:51:21:     Property list:
2011-05-15 23:51:21:         s:PossibleConnectionTypes='IP_Routed'
2011-05-15 23:51:21:         s:ConnectionStatus='Connected'
2011-05-15 23:51:21:         s:ExternalIPAddress='192.168.0.12'
2011-05-15 23:51:21:         s:PortMappingNumberOfEntries='-7'
############################################################################

After the last messages, the router ports still closed. If you have any
questions or proofs that I can do, let me know.

Greetings, David.

#496654#57
Date:
2011-05-23 15:17:06 UTC
From:
To:
Hi again,

I've tried aMule UPnP again but using another router (Thompson), newer than
the other one. This time, UPnP worked perfectly, so I suppose the problem
can be caused by my old router, but I don't know why.

Greetings, David.

2011/5/16 David Sanchez Herrero <david.krusty@gmail.com>

#496654#64
Date:
2016-06-24 10:54:35 UTC
From:
To:
Hello greeting
#496654#69
Date:
2018-01-27 09:18:12 UTC
From:
To:
$1M donated to You Reply To: mrsmavis03@gmail.com
#496654#74
Date:
2026-10-03 20:14:04 UTC
From:
To:
Hi,

Back in 2011 you found that UPnP worked with a different router, so the
problem was specific to the original one. I'm closing this bug; please
reopen it if UPnP still fails with the current version.

Regards,
Sandro