php-ip
php-ip copied to clipboard
IPBlock not working correctly with prefix larger than 23
Unexpected behaviour while using IPBlock with prefixes larger than 23
$block = IPBlock::create('35.35.32.0/22');
foreach ($block as $ip) {
echo $ip,"\n";
}
35.35.32.0
35.35.32.1
35.35.32.2
...
35.35.35.230
35.35.35.231
84.83.80.48
84.83.80.49
85.83.84.54
85.83.84.55