stunner: Check Your NAT Type with STUN

stunner: Check Your NAT Type with STUN

Summary

Stunner is a Go command-line tool that compares STUN responses from multiple servers to estimate your NAT behavior. Use it to assess how readily devices behind your network may connect through hole punching.

At a glance

Language
Go
License
MIT
Stars
182
Forks
10
Added to OSRepos
May 13, 2026
Last analyzed
October 3, 2026
View on GitHub

Topics

Click on any tag to explore related repositories

Use at your own risk

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.

Overview

Stunner probes multiple STUN servers and compares the external IP and port mappings they observe. It turns those results into a best-effort NAT classification and an indication of how easy or hard hole punching may be.

It is useful when you need a quick network diagnostic, such as checking connectivity conditions for peer-to-peer connections. It is an experimental assessment, not a guarantee that a particular connection method will work.

Key Features

  • Sends STUN Binding Requests to multiple servers for comparison.
  • Fetches the Tailscale DERP map and selects servers automatically when none are specified.
  • Accepts user-specified STUN servers and port settings.
  • Supports binding to a chosen local IP address and port.
  • Reports external mappings and an overall NAT classification in tables.
  • Includes optional debug logging for STUN requests and responses.

Use Cases

  • Network administrators can quickly inspect NAT behavior while troubleshooting connectivity.
  • Developers building peer-to-peer applications can check whether a test network appears suitable for hole punching.
  • Tailscale users can run a quick diagnostic using automatically selected DERP servers.
  • Users comparing network environments can provide the same custom STUN servers to each test.

Project Facts

  • Language: Go
  • License: MIT
  • Stars: 182
  • Forks: 10
  • Topics: network, tailscale
  • Archived: No

Getting Started

Install with Go:

go install github.com/jaxxstorm/stunner@latest

Then run stunner to use automatically selected servers, or pass --stun-server values. See the README for installation alternatives and flags.

Considerations

  • The README describes Stunner as an experimental proof of concept, and its NAT classification is a best-effort interpretation.
  • Real NAT and firewall behavior can be more complex than the tests capture, so results may not predict whether a connection will succeed.
  • Building from source requires Go 1.18 or later, as recommended by the project.

Source repository

Open the original repository on GitHub.

19 counted GitHub visits

View on GitHub

Related repositories

Similar repositories that may be relevant next.

OS
OSRepos

Analysis and discovery of open source repositories. Find interesting projects and follow their updates.

Monitor your website with YourWebsiteScore

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of third-party repository code is at your own risk. Always review source code, dependencies, licenses, and security implications before running anything.

© 2025 OSRepos. Built with Nuxt 3 and lots of ❤️