IpUtils
class IpUtils
Http utility functions.
Methods
static bool
checkIp(string $requestIp, string|array $ips)
Checks if an IPv4 or IPv6 address is contained in the list of given IPs or subnets.
static bool
checkIp4(string $requestIp, string $ip)
Compares two IPv4 addresses.
static bool
checkIp6(string $requestIp, string $ip)
Compares two IPv6 addresses.
Details
at line line 36
static bool
checkIp(string $requestIp, string|array $ips)
Checks if an IPv4 or IPv6 address is contained in the list of given IPs or subnets.
at line line 62
static bool
checkIp4(string $requestIp, string $ip)
Compares two IPv4 addresses.
In case a subnet is given, it checks if it contains the request IP.
at line line 98
static bool
checkIp6(string $requestIp, string $ip)
Compares two IPv6 addresses.
In case a subnet is given, it checks if it contains the request IP.