{"id":"CVE-2026-40198","aliases":["CVE-2026-40198"],"related":[],"kind":"vulnerability","state":"published","title":"Net::CIDR::Lite versions before 0.23 for Perl does not validate IPv6 group count, which may allow IP ACL bypass","summary":"Net::CIDR::Lite versions before 0.23 for Perl does not validate IPv6 group count, which may allow IP ACL bypass.\n\n_pack_ipv6() does not check that uncompressed IPv6 addresses (without ::) have exactly 8 hex groups. Inputs like \"abcd\", \"1:2:3\", or \"1:2:3:4:5:6:7\" are accepted and produce packed values of wrong length (3, 7, or 15 bytes instead of 17).\n\nThe packed values are used internally for mask and comparison operations. find() and bin_find() use Perl string comparison (lt/gt) on these values, and comparing strings of different lengths gives wrong results. This can cause find() to incorrectly report an address as inside or outside a range.\n\nExample:\n\n  my $cidr = Net::CIDR::Lite->new(\"::/8\");\n  $cidr->find(\"1:2:3\");  # invalid input, incorrectly returns true\n\nThis is the same class of input validation issue as CVE-2021-47154 (IPv4 leading zeros) previously fixed in this module.\n\nSee also CVE-2026-40199, a related issue in the same function affecting IPv4 mapped IPv6 addresses.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Net::CIDR::Lite versions before 0.23 for Perl does not validate IPv6 group count, which may allow IP ACL bypass.\n\n_pack_ipv6() does not check that uncompressed IPv6 addresses (without ::) have exactly 8 hex groups. Inputs like \"abcd\", \"1:2:3\", or \"1:2:3:4:5:6:7\" are accepted and produce packed values of wrong length (3, 7, or 15 bytes instead of 17).\n\nThe packed values are used internally for mask and comparison operations. find() and bin_find() use Perl string comparison (lt/gt) on these values, and comparing strings of different lengths gives wrong results. This can cause find() to incorrectly report an address as inside or outside a range.\n\nExample:\n\n  my $cidr = Net::CIDR::Lite->new(\"::/8\");\n  $cidr->find(\"1:2:3\");  # invalid input, incorrectly returns true\n\nThis is the same class of input validation issue as CVE-2021-47154 (IPv4 leading zeros) previously fixed in this module.\n\nSee also CVE-2026-40199, a related issue in the same function affecting IPv4 mapped IPv6 addresses.","source":"cvelist"},{"lang":"es","text":"Las versiones de Net::CIDR::Lite anteriores a la 0.23 para Perl no validan el recuento de grupos IPv6, lo que puede permitir la omisión de ACL de IP.\n\n_pack_ipv6() no comprueba que las direcciones IPv6 sin comprimir (sin ::) tengan exactamente 8 grupos hexadecimales. Entradas como ’abcd’, ’1:2:3’ o ’1:2:3:4:5:6:7’ son aceptadas y producen valores empaquetados de longitud incorrecta (3, 7 o 15 bytes en lugar de 17).\n\nLos valores empaquetados se utilizan internamente para operaciones de máscara y comparación. find() y bin_find() utilizan la comparación de cadenas de Perl (lt/gt) en estos valores, y comparar cadenas de diferentes longitudes produce resultados incorrectos. Esto puede hacer que find() informe incorrectamente una dirección como dentro o fuera de un rango.\n\nEjemplo:\n\n  my $cidr = Net::CIDR::Lite -> new(’::/8’);\n  $cidr -> find(’1:2:3’); # entrada inválida, devuelve true incorrectamente\n\nEsta es la misma clase de problema de validación de entrada que CVE-2021-47154 (ceros iniciales de IPv4) corregido previamente en este módulo.\n\nVéase también CVE-2026-40199, un problema relacionado en la misma función que afecta a las direcciones IPv6 mapeadas a IPv4.","source":"nvd"}],"published":"2026-04-10T21:42:06.835Z","modified":"2026-10-26T21:10:00.170Z","severity":{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":7.5,"rating":"HIGH"},"severities":[{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":7.5,"rating":"HIGH"}],"cwes":["CWE-1286"],"affected":[{"ranges":[{"type":"custom","introduced":"0","fixed":"0.23","status":"affected"}],"vendor":"STIGTSP","product":"Net::CIDR::Lite","package":"Net-CIDR-Lite","repo":"https://github.com/stigtsp/Net-CIDR-Lite","source":"cvelist"},{"ranges":[{"status":"affected","fixed":"0.23"}],"vendor":"stigtsp","product":"net::cidr::lite","cpe":"cpe:2.3:a:stigtsp:net\\:\\:cidr\\:\\:lite:*:*:*:*:*:perl:*:*","source":"nvd"}],"references":[{"url":"https://github.com/stigtsp/Net-CIDR-Lite/commit/25d65f85dbe4885959a10471725ec9d250a589c3.patch","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://metacpan.org/release/STIGTSP/Net-CIDR-Lite-0.23/changes","tags":["release-notes"],"sources":["cvelist","nvd"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-40199","tags":["related","third-party-advisory"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"CPANSec","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"partial","date":"2026-04-13T14:41:19.772Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-40198","url":"https://www.cve.org/CVERecord?id=CVE-2026-40198","licence":"CVE Terms of Use","modified":"2026-04-13T14:41:59.967Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-40198","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-40198","licence":"Public domain","modified":"2026-10-26T21:10:00.170Z"}],"updatedAt":"2026-11-25T22:59:18.552Z","epss":{"score":0.00544,"percentile":0.39273,"date":"2026-11-30T12:00:22.000Z"}}