CVE-2026-80490 (GCVE-0-2026-80490)

Vulnerability from cvelistv5 – Published: 2026-09-30 15:20 – Updated: 2026-09-30 17:07
VLAI
Title
Algorithm::AhoCorasick::XS versions through 0.04 for Perl read the haystack string length before the scalar is stringified
Summary
Algorithm::AhoCorasick::XS versions through 0.04 for Perl read the haystack string length before the scalar is stringified. The matches, first_match and match_details methods use the T_STD_STRING typemap to translate Perl scalars (SVs) into strings via the std::string constructor, using the SvPV macro to stringify the haystack input, and the SvCUR macro to determine the length of the SV. When the input SVs are references, integers (IVs) or floats (NVs), the SvCUR macro will return an invalid length if it is run before the input is stringified, leading to an out-of-bounds read which can abort the process. Note that the evaluation order of arguments to std::string is unspecified. Depending on the compiler, SvCUR may be run first and lead to an abort that cannot be caught within Perl. This can be triggered when the haystack is a numeric value, for example, my $ac = Algorithm::AhoCorasick::XS->new( [ "11", "22" ] ); $ac->matches( 211 ); This can occur when the haystack is the result of reading data from decoded JSON or a numeric database column. It can also be triggered when using a blessed object as a haystack.
Severity
No CVSS data available.
CWE
Impacted products
Vendor Product Version CPE status
Affected: 0 , ≤ 0.04 (custom)
Show details on NVD website

{
  "containers": {
    "adp": [
      {
        "providerMetadata": {
          "dateUpdated": "2026-09-30T17:07:30.931Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "url": "http://www.openwall.com/lists/oss-security/2026/09/30/15"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "collectionURL": "https://cpan.org/modules",
          "defaultStatus": "unaffected",
          "modules": [
            "Algorithm::AhoCorasick::XS"
          ],
          "packageName": "Algorithm-AhoCorasick-XS",
          "packageURL": "pkg:cpan/Algorithm-AhoCorasick-XS",
          "programFiles": [
            "typemap"
          ],
          "programRoutines": [
            {
              "name": "Algorithm::AhoCorasick::XS::first_match"
            },
            {
              "name": "Algorithm::AhoCorasick::XS::matches"
            },
            {
              "name": "Algorithm::AhoCorasick::XS::match_details"
            }
          ],
          "repo": "https://github.com/richardjharris/Algorithm-AhoCorasick-XS",
          "versions": [
            {
              "lessThanOrEqual": "0.04",
              "status": "affected",
              "version": "0",
              "versionType": "custom"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "Algorithm::AhoCorasick::XS versions through 0.04 for Perl read the haystack string length before the scalar is stringified.\n\nThe matches, first_match and match_details methods use the T_STD_STRING typemap to translate Perl scalars (SVs) into strings via the std::string constructor, using the SvPV macro to stringify the haystack input, and the SvCUR macro to determine the length of the SV.\n\nWhen the input SVs are references, integers (IVs) or floats (NVs), the SvCUR macro will return an invalid length if it is run before the input is stringified, leading to an out-of-bounds read which can abort the process.\n\nNote that the evaluation order of arguments to std::string is unspecified. Depending on the compiler, SvCUR may be run first and lead to an abort that cannot be caught within Perl.\n\nThis can be triggered when the haystack is a numeric value, for example,\n\n    my $ac = Algorithm::AhoCorasick::XS-\u003enew( [ \"11\", \"22\" ] );\n    $ac-\u003ematches( 211 );\n\nThis can occur when the haystack is the result of reading data from decoded JSON or a numeric database column. It can also be triggered when using a blessed object as a haystack."
        }
      ],
      "problemTypes": [
        {
          "descriptions": [
            {
              "cweId": "CWE-125",
              "description": "CWE-125 Out-of-bounds Read",
              "lang": "en",
              "type": "CWE"
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-09-30T15:20:45.601Z",
        "orgId": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
        "shortName": "CPANSec"
      },
      "references": [
        {
          "tags": [
            "vendor-advisory",
            "issue-tracking"
          ],
          "url": "https://rt.cpan.org/Ticket/Display.html?id=181560"
        },
        {
          "url": "https://metacpan.org/release/RJH/Algorithm-AhoCorasick-XS-0.04/source/typemap#L14"
        },
        {
          "tags": [
            "issue-tracking"
          ],
          "url": "https://github.com/richardjharris/Algorithm-AhoCorasick-XS/pull/1"
        },
        {
          "tags": [
            "patch"
          ],
          "url": "https://security.metacpan.org/patches/A/Algorithm-AhoCorasick-XS/0.04/CVE-2026-80490-r1.patch"
        }
      ],
      "source": {
        "discovery": "UNKNOWN"
      },
      "title": "Algorithm::AhoCorasick::XS versions through 0.04 for Perl read the haystack string length before the scalar is stringified",
      "workarounds": [
        {
          "lang": "en",
          "value": "No fixed release is available. Apply the patch or the change in the linked pull request.\n\nFor deployments that cannot apply the patch, ensure that all input passed to the matching functions is stringified, for example\n\n    $ac-\u003ematches( \"$input\" );"
        }
      ],
      "x_generator": {
        "engine": "cpansec-cna-tool 0.1"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
    "assignerShortName": "CPANSec",
    "cveId": "CVE-2026-80490",
    "datePublished": "2026-09-30T15:20:45.601Z",
    "dateReserved": "2026-08-26T13:32:56.300Z",
    "dateUpdated": "2026-09-30T17:07:30.931Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "nvd": {
      "cve": {
        "affected": [
          {
            "affectedData": [
              {
                "collectionURL": "https://cpan.org/modules",
                "defaultStatus": "unaffected",
                "modules": [
                  "Algorithm::AhoCorasick::XS"
                ],
                "packageName": "Algorithm-AhoCorasick-XS",
                "packageURL": "pkg:cpan/Algorithm-AhoCorasick-XS",
                "programFiles": [
                  "typemap"
                ],
                "programRoutines": [
                  {
                    "name": "Algorithm::AhoCorasick::XS::first_match"
                  },
                  {
                    "name": "Algorithm::AhoCorasick::XS::matches"
                  },
                  {
                    "name": "Algorithm::AhoCorasick::XS::match_details"
                  }
                ],
                "repo": "https://github.com/richardjharris/Algorithm-AhoCorasick-XS",
                "versions": [
                  {
                    "lessThanOrEqual": "0.04",
                    "status": "affected",
                    "version": "0",
                    "versionType": "custom"
                  }
                ]
              }
            ],
            "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e"
          }
        ],
        "cveTags": [],
        "descriptions": [
          {
            "lang": "en",
            "value": "Algorithm::AhoCorasick::XS versions through 0.04 for Perl read the haystack string length before the scalar is stringified.\n\nThe matches, first_match and match_details methods use the T_STD_STRING typemap to translate Perl scalars (SVs) into strings via the std::string constructor, using the SvPV macro to stringify the haystack input, and the SvCUR macro to determine the length of the SV.\n\nWhen the input SVs are references, integers (IVs) or floats (NVs), the SvCUR macro will return an invalid length if it is run before the input is stringified, leading to an out-of-bounds read which can abort the process.\n\nNote that the evaluation order of arguments to std::string is unspecified. Depending on the compiler, SvCUR may be run first and lead to an abort that cannot be caught within Perl.\n\nThis can be triggered when the haystack is a numeric value, for example,\n\n    my $ac = Algorithm::AhoCorasick::XS-\u003enew( [ \"11\", \"22\" ] );\n    $ac-\u003ematches( 211 );\n\nThis can occur when the haystack is the result of reading data from decoded JSON or a numeric database column. It can also be triggered when using a blessed object as a haystack."
          }
        ],
        "id": "CVE-2026-80490",
        "lastModified": "2026-09-30T19:57:08.043",
        "metrics": {},
        "published": "2026-09-30T16:19:10.127",
        "references": [
          {
            "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
            "url": "https://github.com/richardjharris/Algorithm-AhoCorasick-XS/pull/1"
          },
          {
            "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
            "url": "https://metacpan.org/release/RJH/Algorithm-AhoCorasick-XS-0.04/source/typemap#L14"
          },
          {
            "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
            "url": "https://rt.cpan.org/Ticket/Display.html?id=181560"
          },
          {
            "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
            "url": "https://security.metacpan.org/patches/A/Algorithm-AhoCorasick-XS/0.04/CVE-2026-80490-r1.patch"
          },
          {
            "source": "af854a3a-2127-422b-91ae-364da2661108",
            "url": "http://www.openwall.com/lists/oss-security/2026/09/30/15"
          }
        ],
        "sourceIdentifier": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
        "vulnStatus": "Deferred",
        "weaknesses": [
          {
            "description": [
              {
                "lang": "en",
                "value": "CWE-125"
              }
            ],
            "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
            "type": "Secondary"
          }
        ]
      }
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Loading…

Loading…

Related by attack behaviour

Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.


Loading…