REDROOM
PHP 8.3.31
Path:
Logout
Edit File
Size: 896 B
Close
/home/getspomw/royalsquad.us/vendor/geoip2/geoip2/src/Util.php
Text
Base64
<?php declare(strict_types=1); namespace GeoIp2; class Util { /** * This returns the network in CIDR notation for the given IP and prefix * length. This is for internal use only. * * @internal * * @ignore */ public static function cidr(string $ipAddress, int $prefixLen): string { $ipBytes = inet_pton($ipAddress); $networkBytes = str_repeat("\0", \strlen($ipBytes)); $curPrefix = $prefixLen; for ($i = 0; $i < \strlen($ipBytes) && $curPrefix > 0; $i++) { $b = $ipBytes[$i]; if ($curPrefix < 8) { $shiftN = 8 - $curPrefix; $b = \chr(0xFF & (\ord($b) >> $shiftN) << $shiftN); } $networkBytes[$i] = $b; $curPrefix -= 8; } $network = inet_ntop($networkBytes); return "$network/$prefixLen"; } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 5 × Files: 2
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
Database
DIR
-
drwxrwxrwx
2025-09-17 07:10:32
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Exception
DIR
-
drwxrwxrwx
2025-09-17 07:10:32
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Model
DIR
-
drwxrwxrwx
2025-09-17 07:10:32
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Record
DIR
-
drwxrwxrwx
2025-09-17 07:10:32
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
WebService
DIR
-
drwxrwxrwx
2025-09-17 07:10:32
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
ProviderInterface.php
525 B
lrw-rw-rw-
2025-05-05 08:48:26
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Util.php
896 B
lrw-rw-rw-
2025-05-05 08:48:26
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).