CVE-2025-5891 Unitech pm2 Config.js redos

Medium 5.3 Published Updated

Remote attackers can cause denial of service in Unitech pm2 via inefficient regular expressions in the configuration module.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2025-5891?

CVE-2025-5891 is a medium-severity denial of service vulnerability in Unitech pm2, published on 9 Jun 2025. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

A vulnerability classified as problematic was found in Unitech pm2 up to 6.0.6. This vulnerability affects unknown code of the file /lib/tools/Config.js. The manipulation leads to inefficient regular expression complexity. The attack can be initiated remotely. The exploit has been disclosed to the public and may be used.

Weakness: CWE-400, CWE-1333

Which versions are affected by CVE-2025-5891?

2 open source packages ship an affected version, including pm2. It affects 1 product.

PackageAffectedFixed in
pm2 npmAll versions7.0.0
pm2 npmAll versions7.0.0

Products include Keymetric Pm2.

How do I fix CVE-2025-5891?

Upgrade pm2 to 7.0.0 or later.

Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.

Is CVE-2025-5891 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-5891 exists.

Sources

Also known as GHSA-x5gf-qvw8-r2rm.

Is CVE-2025-5891 in your software?

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

Check your SBOMs for free