« Back to list

CVE-2026-2474

Status: AnalyzedHigh (7.5)—

Crypt::URandom versions from 0.41 before 0.55 for Perl is vulnerable to a heap buffer overflow in the XS function crypt_urandom_getrandom().

The function does not validate that the length parameter is non-negative. If a negative value (e.g. -1) is supplied, the expression length + 1u causes an integer wraparound, resulting in a zero-byte allocation. The subsequent call to getrandom(data, length, GRND_NONBLOCK) passes the original negative value, which is implicitly converted to a large unsigned value (typically SIZE_MAX). This can result in writes beyond the allocated buffer, leading to heap memory corruption and application crash (denial of service).

Read full descriptionShow less

In common usage, the length argument is typically hardcoded by the caller, which reduces the likelihood of attacker-controlled exploitation. Applications that pass untrusted input to this parameter may be affected.

CVSS

Exploitation probability (EPSS)

EPSS (Exploit Prediction Scoring System, FIRST) estimates how likely a vulnerability is to be exploited in the wild within 30 days. It complements CVSS (impact) and CISA KEV (confirmed exploitation).

🎯 ATT&CK techniques

How this vulnerability is exploited and what the attacker gains, in MITRE ATT&CK terms.

Buffer overflow en función XS de Perl accesible remotamente sin autenticación (AV:N, PR:N, UI:N); impacto DoS por corrupción de memoria heap y crash de aplicación (A:H, CWE-122).

Inferred by our analysis agent from the official description, CVSS vector and CWE, and checked by a supervisor. May contain errors.

🛡️ ATT&CK mitigations that cover these techniques

Affected technologies (1)

CWEs

References

Raw JSON (NVD)

Show
{
  "id": "CVE-2026-2474",
  "cveTags": [],
  "metrics": {
    "ssvcV203": [
      {
        "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
        "ssvcData": {
          "id": "CVE-2026-2474",
          "role": "CISA Coordinator",
          "options": [
            {
              "exploitation": "none"
            },
            {
              "automatable": "yes"
            },
            {
              "technicalImpact": "partial"
            }
          ],
          "version": "2.0.3",
          "timestamp": "2026-02-17T14:47:36.338726Z"
        }
      }
    ],
    "cvssMetricV31": [
      {
        "type": "Secondary",
        "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
        "cvssData": {
          "scope": "UNCHANGED",
          "version": "3.1",
          "baseScore": 7.5,
          "attackVector": "NETWORK",
          "baseSeverity": "HIGH",
          "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
          "integrityImpact": "NONE",
          "userInteraction": "NONE",
          "attackComplexity": "LOW",
          "availabilityImpact": "HIGH",
          "privilegesRequired": "NONE",
          "confidentialityImpact": "NONE"
        },
        "impactScore": 3.6,
        "exploitabilityScore": 3.9
      }
    ]
  },
  "affected": [
    {
      "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
      "affectedData": [
        {
          "repo": "https://github.com/david-dick/crypt-urandom",
          "vendor": "DDICK",
          "product": "Crypt::URandom",
          "versions": [
            {
              "status": "affected",
              "version": "0.41",
              "lessThan": "0.55",
              "versionType": "custom"
            }
          ],
          "packageName": "Crypt-URandom",
          "programFiles": [
            "URandom.xs"
          ],
          "collectionURL": "https://cpan.org/modules",
          "defaultStatus": "unaffected",
          "programRoutines": [
            {
              "name": "crypt_urandom_getrandom()"
            }
          ]
        }
      ]
    }
  ],
  "published": "2026-02-16T21:22:18.107",
  "references": [
    {
      "url": "https://metacpan.org/release/DDICK/Crypt-URandom-0.54/source/URandom.xs#L35-79",
      "tags": [
        "Issue Tracking"
      ],
      "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e"
    },
    {
      "url": "https://metacpan.org/release/DDICK/Crypt-URandom-0.55/source/Changes",
      "tags": [
        "Product",
        "Release Notes"
      ],
      "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e"
    }
  ],
  "vulnStatus": "Analyzed",
  "weaknesses": [
    {
      "type": "Secondary",
      "source": "9b29abf9-4ab0-4765-b253-1875cd9b441e",
      "description": [
        {
          "lang": "en",
          "value": "CWE-122"
        },
        {
          "lang": "en",
          "value": "CWE-1284"
        }
      ]
    }
  ],
  "descriptions": [
    {
      "lang": "en",
      "value": "Crypt::URandom versions from 0.41 before 0.55 for Perl is vulnerable to a heap buffer overflow in the XS function crypt_urandom_getrandom().\n\nThe function does not validate that the length parameter is non-negative. If a negative value (e.g. -1) is supplied, the expression length + 1u causes an integer wraparound, resulting in a zero-byte allocation. The subsequent call to getrandom(data, length, GRND_NONBLOCK) passes the original negative value, which is implicitly converted to a large unsigned value (typically SIZE_MAX). This can result in writes beyond the allocated buffer, leading to heap memory corruption and application crash (denial of service).\n\nIn common usage, the length argument is typically hardcoded by the caller, which reduces the likelihood of attacker-controlled exploitation. Applications that pass untrusted input to this parameter may be affected."
    },
    {
      "lang": "es",
      "value": "Las versiones de Crypt::URandom de 0.41 anteriores a 0.55 para Perl son vulnerables a un desbordamiento de búfer de montón en la función XS crypt_urandom_getrandom().\n\nLa función no valida que el parámetro de longitud no sea negativo. Si se proporciona un valor negativo (p. ej., -1), la expresión length + 1u causa un desbordamiento de enteros, lo que resulta en una asignación de cero bytes. La llamada subsiguiente a getrandom(data, length, GRND_NONBLOCK) pasa el valor negativo original, que se convierte implícitamente a un valor sin signo grande (típicamente SIZE_MAX). Esto puede resultar en escrituras más allá del búfer asignado, lo que lleva a corrupción de memoria en el montón y a un fallo de la aplicación (denegación de servicio).\n\nEn el uso común, el argumento de longitud suele estar codificado de forma rígida por el llamador, lo que reduce la probabilidad de explotación controlada por el atacante. Las aplicaciones que pasan entrada no confiable a este parámetro pueden verse afectadas."
    }
  ],
  "lastModified": "2026-06-17T10:31:08.167",
  "configurations": [
    {
      "nodes": [
        {
          "negate": false,
          "cpeMatch": [
            {
              "criteria": "cpe:2.3:a:ddick:crypt\\:\\:urandom:*:*:*:*:*:perl:*:*",
              "vulnerable": true,
              "matchCriteriaId": "4FFA138E-FEF2-445E-A513-9C69AEFC03CF",
              "versionEndExcluding": "0.55",
              "versionStartIncluding": "0.41"
            }
          ],
          "operator": "OR"
        }
      ]
    }
  ],
  "sourceIdentifier": "9b29abf9-4ab0-4765-b253-1875cd9b441e"
}