Common attacks and weaknesses
- Stolen private keys give network access (no second factor in the protocol).
Default port of WireGuard VPN tunnels.
Traffic is wrapped in a tunnel between the two ends, so the network in between only sees the tunnel. Everything is encrypted: someone on the path only sees unreadable bytes.
Unofficial use. The IANA assignment below differs from what is usually found on this port in practice.
No entry. The port is free for any application, so check what uses it on your hosts.
// source: IANA service name and port number registry
Linux
sudo ss -ltnup 'sport = :51820' # process listening on 51820
sudo lsof -nP -i :51820macOS
sudo lsof -nP -i :51820
Windows (PowerShell)
Get-NetTCPConnection -LocalPort 51820 -State Listen | Select LocalAddress, OwningProcess Get-NetUDPEndpoint -LocalPort 51820 netstat -ano | findstr :51820
From another machine
nmap -p 51820 -sV <host> sudo nmap -sU -p 51820 <host> nc -zv <host> 51820
Block it in the firewall
sudo ufw deny 51820/udp # Linux (ufw) New-NetFirewallRule -DisplayName "Block 51820" -Direction Inbound -LocalPort 51820 -Protocol UDP -Action Block # Windows
Default port of WireGuard VPN tunnels.
Port 51820 is registered for UDP.
It is rated 2/10 (low) when exposed to the Internet. Stolen private keys give network access (no second factor in the protocol). Protect and rotate keys; restrict AllowedIPs per peer.
On Linux run "ss -ltnup 'sport = :51820'", on macOS "lsof -nP -i :51820", and on Windows "netstat -ano | findstr :51820" to see the local process. From another machine, "nmap -p 51820 <host>" shows whether it is reachable.