A very (very) simple program to connect to a STUN server and get your host's public IP. In fact, it's almost the example provided for stun Go library
Useful to check if you can reach a STUN server and what is the public IP presented to this server.
With the default STUN server (stun.l.google.com:19302):
> ./stunip
123.45.67.89
Or, in a Windows environment:
> .\stunip.exe
123.45.67.89
Output is the XOR Mapped Address returned by the STUN server when binding to it. This IP is the public IP address of your host (or your Internet router).
With a custom STUN server:
> ./stunip -server worldaz.turn.teams.microsoft.com:3478
123.45.67.89