Vulnerability · Published Jul 16, 2025 · Assigned by CPANSec

CVE-2025-40918Authen::SASL::Perl::DIGEST_MD5 versions 2.04 through 2.1800 for Perl generates the cnonce insecurely

Medium 6.5

In plain English

A medium-severity security flaw in Authen::SASL::Perl::DIGEST_MD5 from EHUELS. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.5% (higher than 40% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)6.5Medium
Exploit odds (30 days)0.5%top 60.3% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

Authen::SASL::Perl::DIGEST_MD5 versions 2.04 through 2.1800 for Perl generates the cnonce insecurely. The cnonce (client nonce) is generated from an MD5 hash of the PID, the epoch time and the built-in rand function. The PID will come from a small set of numbers, and the epoch time may be guessed, if it is not leaked from the HTTP Date header. The built-in rand function is unsuitable for cryptographic usage. According to RFC 2831, The cnonce-value is an opaque quoted string value provided by the client and used by both client and server to avoid chosen plaintext attacks, and to provide mutual authentication. The security of the implementation depends on a good choice. It is RECOMMENDED that it contain at least 64 bits of entropy.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Alpine:v3.24perl-authen-sasl2.1900ALPINE-CVE-2025-40918
Debian:12libauthen-sasl-perlno fix listedDEBIAN-CVE-2025-40918
Debian:13libauthen-sasl-perlno fix listedDEBIAN-CVE-2025-40918
Debian:14libauthen-sasl-perl2.1900-1DEBIAN-CVE-2025-40918
Ubuntu:22.04:LTSlibauthen-sasl-perlno fix listedUBUNTU-CVE-2025-40918
Ubuntu:24.04:LTSlibauthen-sasl-perlno fix listedUBUNTU-CVE-2025-40918
Ubuntu:25.10libauthen-sasl-perlno fix listedUBUNTU-CVE-2025-40918
Ubuntu:26.04:LTSlibauthen-sasl-perlno fix listedUBUNTU-CVE-2025-40918
Ubuntu:26.10libauthen-sasl-perlno fix listedUBUNTU-CVE-2025-40918

Affected products (as reported)

VendorProductVersions
EHUELS Authen::SASL::Perl::DIGEST_MD5 2.04 – through 2.1800

Weakness: CWE-340, CWE-338 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N

References