Description
Web::API 2.8 and earlier for Perl uses the rand() function as the default source of entropy, which is not cryptographically secure, for cryptographic functions.
Specifically Web::API uses the Data::Random library which specifically states that it is "Useful mostly for test programs". Data::Random uses the rand() function.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| LEV | Web::API | ≤ 2.8 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | libweb-api-perl | No fix yet | — |
| Debian 13 | libweb-api-perl | No fix yet | — |
| Debian 12 | libweb-api-perl | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | libweb-api-perl | No fix yet | — |
| Ubuntu 26.04 LTS | libweb-api-perl | No fix yet | — |
| Ubuntu 25.10 | libweb-api-perl | No fix yet | — |
| Ubuntu 24.04 LTS | libweb-api-perl | No fix yet | — |
| Ubuntu 22.04 LTS | libweb-api-perl | No fix yet | — |
Show 2 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 20.04 LTS | libweb-api-perl | No fix yet | — |
| Ubuntu 18.04 LTS | libweb-api-perl | No fix yet | — |
References
- https://perldoc.perl.org/functions/rand
- https://security.metacpan.org/docs/guides/random-data-for-security.html
- https://metacpan.org/release/BAREFOOT/Data-Random-0.13/source/lib/Data/Random.pm#L537
- https://metacpan.org/dist/Web-API/source/lib/Web/API.pm#L20
- https://metacpan.org/dist/Web-API/source/lib/Web/API.pm#L348