Skip to content
OpenAdvisories
Medium · 5.3 CVE-2024-58135 EUVD-2025-13365GHSA-3r5v-gmfp-3mh9

Mojolicious versions from 7.28 through 9.45 for Perl will generate weak HMAC session cookie secrets via "mojo generate app" by default

Published May 3, 2025 · Updated Jun 5, 2026 · Assigned by CPANSec

Description

Mojolicious versions from 7.28 through 9.45 for Perl will generate weak HMAC session cookie secrets via "mojo generate app" by default.

When creating a default app skeleton with the "mojo generate app" tool, a weak secret is written to the application's configuration file using the insecure rand() function, and used for authenticating and protecting the integrity of the application's sessions. This may allow an attacker to brute force the application's session keys.

Release 9.46 fixes the issue by providing high quality randomness, even in absence of CryptX.

Users should be aware that the update does not replace previously generated weak secrets. A secret generated with the previous version MUST be replaced to ensure the updated version is using a strong secret.

Affected products

VendorProductAffectedFixed
SRI Mojolicious 7.28 – ≤ 9.45 —

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.

ReleasePackageFixed inAdvisory
Debian 14 libmojolicious-perl No fix yet —
Debian 13 libmojolicious-perl No fix yet —
Debian 12 libmojolicious-perl No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 26.10 libmojolicious-perl No fix yet —
Ubuntu 26.04 LTS libmojolicious-perl No fix yet —
Ubuntu 25.10 libmojolicious-perl No fix yet —
Ubuntu 24.04 LTS libmojolicious-perl No fix yet —
Ubuntu 22.04 LTS libmojolicious-perl No fix yet —
Show 3 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu 20.04 LTS libmojolicious-perl No fix yet —
Ubuntu 18.04 LTS libmojolicious-perl No fix yet —
Ubuntu 16.04 LTS libmojolicious-perl No fix yet —

Amazon Linux

ReleasePackageFixed inAdvisory
Amazon Linux 2023 perl-Test-Mojo +1 9.40-3.amzn2023.0.1 ALAS2023-2025-985

Azure Linux

ReleasePackageFixed inAdvisory
Azure Linux 3 perl-Mojolicious No fix yet —
Azure Linux 2 (CBL-Mariner) perl-Mojolicious No fix yet —

Advisories 1

References