Allow reserved IP adresses

This commit is contained in:
Miraty 2022-08-11 16:36:54 +02:00
parent d984dd2f20
commit e64b6f5f56

View file

@ -41,8 +41,6 @@ function knotcZoneExec($zone, $cmd) {
} }
function checkIpFormat($ip) { function checkIpFormat($ip) {
if (!filter_var($ip, FILTER_VALIDATE_IP, FILTER_FLAG_NO_RES_RANGE))
userError("IP address is on the reserved range.");
if (filter_var($ip, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4)) if (filter_var($ip, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4))
return "A"; return "A";
if (filter_var($ip, FILTER_VALIDATE_IP, FILTER_FLAG_IPV6)) if (filter_var($ip, FILTER_VALIDATE_IP, FILTER_FLAG_IPV6))