miniupnp.tuxfamily.org Forum Index miniupnp.tuxfamily.org
The forum about miniupnp and libnatpmp
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

(20071213) Mac airport gives NATPMP_ERR_NOGATEWAYSUPPORT?
Goto page 1, 2  Next
 
Post new topic   Reply to topic    miniupnp.tuxfamily.org Forum Index -> libnatpmp Bugs
View previous topic :: View next topic  
Author Message
Charles



Joined: 06 Nov 2007
Posts: 20

PostPosted: Sat Dec 15, 2007 5:08 pm    Post subject: (20071213) Mac airport gives NATPMP_ERR_NOGATEWAYSUPPORT? Reply with quote

I'm not sure whether this is a configuration error or a code error, so I thought I'd pass it upstream for a second opinion. This is a report from a Transmission user with a Mac Airport router. The 'natpmp.c' referred to in the log is here.
Quote:
  • Standard Airport Extreme 802.11a/b/g router, set to use NAT-PMP
  • Yes, NAT-PMP is enabled (checked in Airport Utility)
  • Using port 9090, the site tells me that my port status is "Stealth", and the "Protocol and Application" is "WebSM"
  • my router is 10.0.0.138 and my computer is 10.0.0.2.
  • Here are the port mapping entries from the debug log using 0.96+ r4173:
2007-12-15 20:20:42 +1100 natpmp.c:69 [Debug] Port Mapping (NAT-PMP): initnatpmp returned success (0)
2007-12-15 20:20:42 +1100 natpmp.c:69 [Debug] Port Mapping (NAT-PMP): sendpublicaddressrequest returned success (2)
2007-12-15 20:20:42 +1100 shared.c:90 [Info] Port Mapping: mapping state changed from 'unmapped' to 'mapping'
2007-12-15 20:20:42 +1100 shared.c:111 [Info] Port Mapping: opened port 9090 to listen for incoming peer connections
2007-12-15 20:20:50 +1100 natpmp.c:71 [Error] Port Mapping (NAT-PMP): readnatpmpresponseorretry returned error -7, errno is 61 (Connection refused)
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Sun Dec 16, 2007 6:38 pm    Post subject: Reply with quote

I thik the Airport "classic" doesn't support NAT-PMP, it is available in Airport Extreme and newer hardware.
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Sun Dec 16, 2007 6:40 pm    Post subject: Reply with quote

You can find some more information on apple website :
http://docs.info.apple.com/article.html?artnum=302510
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Charles



Joined: 06 Nov 2007
Posts: 20

PostPosted: Mon Dec 17, 2007 2:16 am    Post subject: Reply with quote

miniupnp wrote:
I thik the Airport "classic" doesn't support NAT-PMP, it is available in Airport Extreme and newer hardware.

The OP stated that he's using an Airport Extreme, and NAT-PMP is enabled.
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Tue Dec 18, 2007 8:58 am    Post subject: Reply with quote

Charles wrote:
miniupnp wrote:
I think the Airport "classic" doesn't support NAT-PMP, it is available in Airport Extreme and newer hardware.

The OP stated that he's using an Airport Extreme, and NAT-PMP is enabled.

oops sorry.
In anycase, the error 61 (Connection refused) is returned when the client receives a "ICMP Port Unreachable" packet that is sent when the Port 5351 UDP is closed.
Maybe the default network gateway is not the Airport Extreme ? ok getgateway() is returning a wrong adress.
Quote:
my router is 10.0.0.138 and my computer is 10.0.0.2.
10.0.0.138 looks suspicious Smile
It could help to have a look at the routing table of this user.
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Jethryn Freyman



Joined: 20 Dec 2007
Posts: 7

PostPosted: Thu Dec 20, 2007 11:13 pm    Post subject: Reply with quote

Quote:
It could help to have a look at the routing table of this user

Thats me Smile

My computer is a 2.2GHz Macbook Pro with OS X 10.5.1, and all available software updates installed.

My router is an 802.11/a/b/g Airport Extreme, it's local IP is 10.0.0.138. NAT-PMP is enabled. System Preferences are set to configure IPv4 using DHCP, and my computer has the local IP 10.0.0.2.

Below is a debug log from the bittorrent application Transmission (version 0.96+ r4155) showing all messages related to sockets or port mapping.

Code:
2007-12-21 09:44:19 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:69 [Debug] Port Mapping (NAT-PMP): initnatpmp returned success (0)

2007-12-21 09:44:19 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:69 [Debug] Port Mapping (NAT-PMP): sendpublicaddressrequest returned success (2)

2007-12-21 09:44:19 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/shared.c:90 [Info] Port Mapping: mapping state changed from 'unmapped' to 'mapping'

2007-12-21 09:44:19 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/net.c:183 [Info] Bound socket 11 to port 9090

2007-12-21 09:44:19 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/shared.c:111 [Info] Port Mapping: opened port 9090 to listen for incoming peer connections

2007-12-21 09:44:27 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:71 [Error] Port Mapping (NAT-PMP): readnatpmpresponseorretry returned error -7, errno is 61 (Connection refused)

2007-12-21 09:44:27 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:111 [Error] Port Mapping (NAT-PMP): If your router supports NAT-PMP, please make sure NAT-PMP is enabled!

2007-12-21 09:44:27 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:112 [Error] Port Mapping (NAT-PMP): NAT-PMP port forwarding unsuccessful, trying UPnP next

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:96 [Info] Port Mapping (UPNP): Found Internet Gateway Device 'http://10.0.0.138:80/upnp/LANHostCfgMgmt?dev=3'

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:97 [Info] Port Mapping (UPNP): Local LAN IP Address is '10.0.0.2'

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:146 [Info] Port Mapping (UPNP): Port forwarding via 'http://10.0.0.138:80/upnp/LANHostCfgMgmt?dev=3', service 'urn:schemas-upnp-org:service:LANHostConfigManagement:1'.  (local address: 10.0.0.2:9090)

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:148 [Info] Port Mapping (UPNP): Port forwarding successful!

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/shared.c:90 [Info] Port Mapping: mapping state changed from 'mapping' to 'mapped'


I'm free to answer any other questions
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Fri Dec 21, 2007 2:24 pm    Post subject: Reply with quote

Could you capture with ethereal/wireshark or a similar tool (tcpdump/tshark/etc..) the Request that libnatpmp is sending to somewhere on the port 5351 ???

Are other tools using NAT-PMP correctly working with your configuration ?
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Jethryn Freyman



Joined: 20 Dec 2007
Posts: 7

PostPosted: Sat Dec 22, 2007 10:49 am    Post subject: Reply with quote

I'll give wireshark a go, though last time I used it (on Tiger) it was very unstable, usually crashing before I could save anything. Hopefully it'll work better with leopard.

Quote:
Are other tools using NAT-PMP correctly working with your configuration ?

Not exactly sure if I have any other tools using NAT-PMP, but I don't have any network trouble. Any software I could download that uses NAT-PMP so I could test it?
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Sat Dec 22, 2007 2:12 pm    Post subject: Reply with quote

Jethryn Freyman wrote:
I'll give wireshark a go, though last time I used it (on Tiger) it was very unstable, usually crashing before I could save anything. Hopefully it'll work better with leopard.

Quote:
Are other tools using NAT-PMP correctly working with your configuration ?

Not exactly sure if I have any other tools using NAT-PMP, but I don't have any network trouble. Any software I could download that uses NAT-PMP so I could test it?


LightHouse seems to be perfect for debugging purpose. It detects and configure UPnP or NAT-PMP routers.
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Jethryn Freyman



Joined: 20 Dec 2007
Posts: 7

PostPosted: Sat Dec 22, 2007 11:26 pm    Post subject: Reply with quote

Latest message log from Transmission (messages regarding port mapping, Transmission 0.96+ r4196, OS X 10.5.1)

Code:
2007-12-23 10:03:10 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/net.c:183 [Info] Bound socket 11 to port 9090

2007-12-23 10:03:10 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/shared.c:90 [Info] Port Mapping: mapping state changed from 'unmapped' to 'mapping'

2007-12-23 10:03:10 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/shared.c:111 [Info] Port Mapping: opened port 9090 to listen for incoming peer connections

2007-12-23 10:03:10 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:69 [Debug] Port Mapping (NAT-PMP): initnatpmp returned success (0)

2007-12-23 10:03:10 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:69 [Debug] Port Mapping (NAT-PMP): sendpublicaddressrequest returned success (2)

2007-12-23 10:03:18 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:111 [Error] Port Mapping (NAT-PMP): If your router supports NAT-PMP, please make sure NAT-PMP is enabled!

2007-12-23 10:03:18 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:112 [Error] Port Mapping (NAT-PMP): NAT-PMP port forwarding unsuccessful, trying UPnP next

2007-12-23 10:03:18 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:71 [Error] Port Mapping (NAT-PMP): readnatpmpresponseorretry returned error -7, errno is 61 (Connection refused)

2007-12-23 10:03:20 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:96 [Info] Port Mapping (UPNP): Found Internet Gateway Device 'http://10.0.0.138:80/upnp/LANHostCfgMgmt?dev=3'

2007-12-23 10:03:20 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:97 [Info] Port Mapping (UPNP): Local LAN IP Address is '10.0.0.2'

2007-12-23 10:03:20 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:148 [Info] Port Mapping (UPNP): Port forwarding successful!

2007-12-23 10:03:20 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:146 [Info] Port Mapping (UPNP): Port forwarding via 'http://10.0.0.138:80/upnp/LANHostCfgMgmt?dev=3', service 'urn:schemas-upnp-org:service:LANHostConfigManagement:1'.  (local address: 10.0.0.2:9090)

2007-12-23 10:03:20 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/shared.c:90 [Info] Port Mapping: mapping state changed from 'mapping' to 'mapped'


Unfortunately, I couldn't get Wireshark to correctly launch, I'll play around with it a bit more later though. In the meantime, I used a trial version of Frameseer to track the traffic that Transmission generated on launch.

All captures
http://img170.imageshack.us/img170/4935/allzk5.png
NAT-PMP request in detail
http://img204.imageshack.us/img204/5365/onebs8.png

NAT-PMP is enabled in Airport Utility.

Info from Lighthouse
Associated with router: 10.0.0.138 (UPnP)
Checking the the "Port mapping profiles", Transmission is set to use TCP and UDP on public port 9090 and private port 9090. Clicking on "View conflicts", there are no conflicts.

I'm not exactly sure what to do with Lighthouse beyond that, hope some of this helps.
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Thu Dec 27, 2007 3:43 pm    Post subject: Reply with quote

from the 1st screen capture I see that a ICMP port unreachable is sent by 10.0.0.138 just after the request is sent by libnatpmp. On the 2nd capture, everythin,g seems ok in the packet.
You could try to redirect a port with lighthouse, and see what are in the capture.
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Thu Dec 27, 2007 3:46 pm    Post subject: Reply with quote

Just a question : Does the Airport Extreme router support both UPnP and NAT-PMP ?
_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Jethryn Freyman



Joined: 20 Dec 2007
Posts: 7

PostPosted: Fri Dec 28, 2007 8:23 pm    Post subject: Reply with quote

I don't think that Airport Extreme supports UPnP, but it DOES support NAT-PMP. Quote from the help apge for Airport Extreme:

Quote:
NAT Port Mapping Protocol (NAT-PMP) is an Internet Engineering Task Force Internet Draft, an alternative to the more common Universal Plug and Play (UPnP) protocol implemented in many network address translation (NAT) routers. NAT-PMP allows a computer in a private network (behind a NAT router) to automatically configure the router to allow parties outside the private network to contact this computer.


I'll give Lighthouse another go and see what I can find.
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1589

PostPosted: Sun Dec 30, 2007 9:27 pm    Post subject: Reply with quote

Jethryn Freyman wrote:
I don't think that Airport Extreme supports UPnP,

so why transmission gives this ? :
Code:

2007-12-21 09:44:27 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/natpmp.c:112 [Error] Port Mapping (NAT-PMP): NAT-PMP port forwarding unsuccessful, trying UPnP next

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:96 [Info] Port Mapping (UPNP): Found Internet Gateway Device 'http://10.0.0.138:80/upnp/LANHostCfgMgmt?dev=3'

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:97 [Info] Port Mapping (UPNP): Local LAN IP Address is '10.0.0.2'

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:146 [Info] Port Mapping (UPNP): Port forwarding via 'http://10.0.0.138:80/upnp/LANHostCfgMgmt?dev=3', service 'urn:schemas-upnp-org:service:LANHostConfigManagement:1'.  (local address: 10.0.0.2:9090)

2007-12-21 09:44:29 +1100 /var/tmp/pea/transmission.m0k.org/trunk/libtransmission/upnp.c:148 [Info] Port Mapping (UPNP): Port forwarding successful!

_________________
Main miniUPnP author.
https://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Jethryn Freyman



Joined: 20 Dec 2007
Posts: 7

PostPosted: Sun Dec 30, 2007 10:58 pm    Post subject: Reply with quote

Not sure why I thought that Airport Extreme didn't support UPnP. Lighthouse tells me that it's been mapped by UPnP, I have network address translation enabled in the Airport Utility.

I've also got a port mapping profile for Transmission enabled in lighthouse, but Transmission still gives me the "Port is closed" message.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    miniupnp.tuxfamily.org Forum Index -> libnatpmp Bugs All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP
© 2007 Thomas Bernard, author of MiniUPNP.