views:

214

answers:

1

I would like to discover the type of the NAT (FullCone, Restricted Cone, Port Restricted cone, Symmetric) a given network interface is behind.

I've tested different tools (http://freshmeat.net/projects/jstun/, http://code.google.com/p/boogu/) but they report different results for the same interface.

I'm looking for a definitive answer in Python (or other languages, 2nd choice being Java, if nothing else is available).

+1  A: 

http://en.wikipedia.org/wiki/STUN

NAT devices are implemented in a number of different types of address and port mapping schemes. STUN does not work correctly with all of them.

Is that definitive enough? It's only a wikipedia quote, but from this it looks like your request is physically impossible.

S.Lott