CVE-2026-2474Crypt::URandom versions from 0.41 before 0.55 for Perl is vulnerable to a heap buffer…
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). 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.
What to do
Fixed builds are available from Alpine, Debian: see the table below for the fixed version per release.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 26.04 | libcrypt-urandom-perl | Not affected vulnerable_code_not_present | ||
| Ubuntu 25.10 | libcrypt-urandom-perl | Will not fix The getrandom subroutine was introduced in 0.41 | UBUNTU-CVE-2026-2474 | |
| Ubuntu 24.04 | libcrypt-urandom-perl | Not affected vulnerable_code_not_present | ||
| Ubuntu 22.04 | libcrypt-urandom-perl | Not affected vulnerable_code_not_present | ||
| Debian 14 | libcrypt-urandom-perl | Fixed | 0.55-1 | DEBIAN-CVE-2026-2474 |
| Debian 13 | libcrypt-urandom-perl | Fixed | 0.54-1+deb13u1 | DEBIAN-CVE-2026-2474 |
| Alpine Linux 3.24 | perl-crypt-urandom | Fixed | 0.55-r0 | ALPINE-CVE-2026-2474 |
What the vendor says
As published in the CVE record by CPANSec, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- DDICK Crypt::URandom: affected: 0.41 to before 0.55; fixed in
0.55
Solution: Update to version 0.55 or later
Vendor advisories:
References
- https://metacpan.org/release/DDICK/Crypt-URandom-0.55/source/Changes
- https://metacpan.org/release/DDICK/Crypt-URandom-0.54/source/URandom.xs#L35-79
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.