by vlovich123 · 2d ago · 0 comments
EDIT: And on a practical level, the port number is sent as plaintext in the packet header, and generally much easier to snoop on than a secret sent in the data.
Whereas a wireguard setup using a nonstandard port would require an individual malicious operator to MITM your traffic to your homelab, then additionally attempt attack the service themselves. It would be so rare that even a single occurance is extraordinarily unlikely to ever occur. As a result, you could have real-time phone notifications for such an event, and be notified on an incorrect key exchange or other invalid packet instantly. Or just aggressively fail2ban any IP range that makes an invalid handshake.
Effective security is achieved through layers, the goal is just raising the opportunity cost enough that it will realistically not be compromised without severely hindering functionality.