pystun3
Discover NAT type using STUN protocol
TLDR
SYNOPSIS
pystun3 [-H server] [-p port] [-i ip] [options]
DESCRIPTION
pystun3 is a STUN (Session Traversal Utilities for NAT) client that discovers the type of NAT between a host and the internet. It communicates with a STUN server to determine the NAT classification (full cone, restricted cone, port restricted, or symmetric) and reports the external IP address and mapped port.Understanding NAT type is essential for configuring VoIP, video conferencing, and peer-to-peer applications that require direct connections between hosts. The tool can target specific STUN servers and bind to particular network interfaces.
PARAMETERS
-H STUNHOST, **--host** STUNHOST
STUN server hostname.-P STUNPORT, **--host-port** STUNPORT
STUN server port (default: 3478).-p SOURCEPORT, **--port** SOURCEPORT
Source port to listen on (default: 54320).-i SOURCEIP, **--interface** SOURCEIP
Network interface for client (default: 0.0.0.0).-d, --debug
Enable debug logging.--version
Show program version.
CAVEATS
Requires network access. STUN server must be reachable. NAT types vary.
HISTORY
pystun3 is a Python 3 port of pystun, implementing STUN (Session Traversal Utilities for NAT) client functionality.
