Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

STUN Binding Request

This script utilizes the STUN protocol to discover the public IP address and port of a device behind a NAT, facilitating seamless internet connectivity.

Usage

To run the script, use the following command:

python stun_request.py [options]

Arguments

  • --stun: Specify one or more STUN server addresses (e.g., --stun stun.l.google.com:19302). This argument can be repeated to include multiple servers.

  • --timeout: Set the timeout duration in seconds for the STUN request (default is 4.0 seconds).

  • --workers: Define the number of concurrent worker threads to query the STUN servers (default is 8).

  • --help: Show the help message and exit.

Example

Using the default STUN servers:

python stun_request.py

Or with a custom STUN server and a different timeout:

python stun_request.py --stun stun.example.com:3478 --timeout 5.0

License

GPL-3.0 license

About

A script that uses the STUN protocol to discover a device's public IP address and port behind a NAT.

Topics

Resources

Stars

Watchers

Forks

Contributors

Languages