CVE-2024-58040 Crypt::RandomEncryption for Perl uses insecure rand() function during encryption

Critical 9.1 Published Updated

The Perl Crypt::RandomEncryption library uses an insecure random number generator, potentially allowing attackers to predict encryption keys and decrypt data.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2024-58040?

CVE-2024-58040 is a critical vulnerability in QWER Crypt::RandomEncryption, published on 29 Sep 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

Crypt::RandomEncryption for Perl version 0.01 uses insecure rand() function during encryption.

Weakness: CWE-338, CWE-331

Which versions are affected by CVE-2024-58040?

It affects 1 product.

Products include Qwer Crypt\.

How do I fix CVE-2024-58040?

No fix has been published for CVE-2024-58040 yet. Limit exposure of the affected software until one is available.

Is CVE-2024-58040 being exploited?

There is no known exploitation of CVE-2024-58040 in the wild and no public exploit code.

Sources

Also known as GHSA-3fwq-4gv2-9v92.

Is CVE-2024-58040 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free