naggie / dsnet

FAST command to manage a centralised wireguard VPN. Think wg-quick but quicker: key generation + address allocation.
https://calbryant.uk/blog/how-to-set-up-a-wireguard-vpn-in-minutes-with-dsnet/
MIT License
673 stars 33 forks source link

Peer name validation to RFC 1123 #91

Open frillip opened 10 months ago

frillip commented 10 months ago

Peer names should be validated to RFC 1123, as these should be considered hostnames.

Suggest that characters that are not [a-zA-Z0-9\-\.] be either removed entirely or replaced with -, and anything over 63 characters be truncated, and dsnet prompt to confirm the modified name (as default by pressing enter) or user to enter a new one.