We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Code in https://github.com/CIDRAM/CIDRAM/tree/v3/vault/CIDRAM/CIDRAM/Aggregator.php in constructTables() creates wrong netmasks for the last octet.
Netmasks are fine for: ["ffff:ffff:ffff:ffff:ffff:ffff:ffff::"]=> int(112) ["ffff:ffff:ffff:ffff:ffff:ffff:fffe::"]=> int(111) ["ffff:ffff:ffff:ffff:ffff:ffff:fffc::"]=> and then wrong for the last octet: ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff:0"]=> int(128) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fffe:0"]=> int(127) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fffc:0"]=> int(126) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fff8:0"]=> int(125) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fff0:0"]=> int(124) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffe0:0"]=> int(123) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffc0:0"]=> int(122) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ff80:0"]=> int(121) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ff00:0"]=> int(120) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fe00:0"]=> int(119) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fc00:0"]=> int(118) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:f800:0"]=> int(117) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:f000:0"]=> int(116) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:e000:0"]=> int(115) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:c000:0"]=> int(114) ["ffff:ffff:ffff:ffff:ffff:ffff:ffff:8000:0"]=> int(113)
The :0 is too much there if we fully iterate through the last octet as well.
Fix is to append only an empty string, not :0, for the last octet: $End = ($Octet === 8) ? '' : '::';
The text was updated successfully, but these errors were encountered:
Bug-fix (#486).
8fa3149
Changelog excerpt: - The aggregator's constructTables method was constructing the wrong IPv6 netmask for last hextet; Fixed.
985870c
a58d82e
51cc4b2
Bug-fix (CIDRAM/CIDRAM#486).
3c7d6d5
Successfully merging a pull request may close this issue.
Code in https://github.com/CIDRAM/CIDRAM/tree/v3/vault/CIDRAM/CIDRAM/Aggregator.php in constructTables() creates wrong netmasks for the last octet.
Netmasks are fine for:
["ffff:ffff:ffff:ffff:ffff:ffff:ffff::"]=>
int(112)
["ffff:ffff:ffff:ffff:ffff:ffff:fffe::"]=>
int(111)
["ffff:ffff:ffff:ffff:ffff:ffff:fffc::"]=>
and then wrong for the last octet:
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff:0"]=>
int(128)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fffe:0"]=>
int(127)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fffc:0"]=>
int(126)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fff8:0"]=>
int(125)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fff0:0"]=>
int(124)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffe0:0"]=>
int(123)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffc0:0"]=>
int(122)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ff80:0"]=>
int(121)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:ff00:0"]=>
int(120)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fe00:0"]=>
int(119)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:fc00:0"]=>
int(118)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:f800:0"]=>
int(117)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:f000:0"]=>
int(116)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:e000:0"]=>
int(115)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:c000:0"]=>
int(114)
["ffff:ffff:ffff:ffff:ffff:ffff:ffff:8000:0"]=>
int(113)
The :0 is too much there if we fully iterate through the last octet as well.
Fix is to append only an empty string, not :0, for the last octet:
$End = ($Octet === 8) ? '' : '::';
The text was updated successfully, but these errors were encountered: