Audit fixes
This commit is contained in:
@@ -55,7 +55,7 @@ func Network_Validate(c *Network) error {
|
||||
}
|
||||
|
||||
func Peer_Sanitize(p *Peer) {
|
||||
p.Name = strings.TrimSpace(p.Name)
|
||||
p.Name = strings.TrimSpace(strings.ToLower(p.Name))
|
||||
if len(p.Addr4) != 0 {
|
||||
if addr, ok := netip.AddrFromSlice(p.Addr4); ok {
|
||||
// Unmap so an IPv4-mapped form is stored canonically as 4 bytes.
|
||||
|
||||
Reference in New Issue
Block a user