Documentation ¶
Index ¶
Constants ¶
View Source
const IPLocalhost = `((127\.([0-9]{1,3}\.){2}[0-9]{1,3})|(::1)$)`
IPLocalhost is a regex pattern for IPv4 or IPv6 loopback range.
View Source
const IPv4Localhost = `(127\.([0-9]{1,3}\.){2}[0-9]{1,3})`
IPv4Localhost is a regex pattern for IPv4 localhost address range.
Variables ¶
This section is empty.
Functions ¶
func IsIPv4Localhost ¶
IsIPv4Localhost returns true if ip matches the IPv4 localhost regular expression.
func IsLocalhost ¶
IsLocalhost returns true if ip matches the localhost IP regular expression. Used for determining if nameserver settings are being passed which are localhost addresses
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.