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 

Unable to get gateway

 
Post new topic   Reply to topic    miniupnp.tuxfamily.org Forum Index -> libnatpmp Bugs
View previous topic :: View next topic  
Author Message
Hazard



Joined: 21 Jan 2010
Posts: 2

PostPosted: Thu Jan 21, 2010 4:20 am    Post subject: Unable to get gateway Reply with quote

I'm looking to use libnatpmp for a configuring NAT, and went to build natpmpc-static.exe on Windows as a test (using the latest release). Just running the program without any arguments to try to obtain the gateway, I got the following result:

initnatpmp() returned 0 (SUCCESS)
sendpublicaddressrequest returned 2 (SUCCESS)
readnatpmpresponseorretry returned -5 (FAILED)
errno=0 'No error'

However, given that I have an old Linksys RT31P2 (from Vonage) which is known to have upnp issues, I figured it was just my router. So I had two of my colleagues try running it, one with a Netgear wpn824 (supported on the config site) and the other with the trusty Linksys WRT-54GL with Tomato firmware. Both had upnp enabled, but got the same result.

I did some digging in the code, and found that the recvfrom on line 178 of natpmp.c was returning an error. As you need to use WSAGetLastError() in Windows to get anything meaningful (errno returns 0), I put that in there and found that I was getting an WSAEWOULDBLOCK. Does this mean that the proper UDP port isn't open?

I'm pretty unfamiliar with natpmp & upnp (I'm not sure exactly how closely, if at all, they're related, or if enabling one usually enables the other), but would like to get this to work soon if possible. Should I be using upnp instead for broader support? If natpmp is the better bet, I'm willing to help troubleshoot and contribute patches if someone could give me some guidance. Let me know if I'll need Wireshark installed for anything (I haven't used it much since it was called Ethereal, but I used to know what I was doing with that at least for TCP, SCTP, and PPP stack debugging Wink ). I know that my router may be a hinderance if it happens to have the upnp bugs I read about (it may or may not, I'm not entirely sure), but am looking to buy a new one anyway (probably something with 802.11n draft 2.0 that is fast).

Thanks!
Back to top
View user's profile Send private message
miniupnp
Site Admin


Joined: 14 Apr 2007
Posts: 1500

PostPosted: Thu Jan 21, 2010 5:03 pm    Post subject: Reply with quote

Well all routers you are citing are supporting UPnP IGD but not NAT-PMP (which is from Apple and mainly supported by Apple Hardware and software)

Use miniUPnPc : Windows binary
_________________
Main miniUPnP author.
http://miniupnp.tuxfamily.org/
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    miniupnp.tuxfamily.org Forum Index -> libnatpmp Bugs All times are GMT
Page 1 of 1

 
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.