Every CVE Search/ Get API key

CVE-2025-25200

Koa has Inefficient Regular Expression Complexity

9.2 CriticalPublic exploitFix available

Koa is expressive middleware for Node.js using ES2017 async functions. Prior to versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3, Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack. Versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3 fix the issue.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
None
Integrity
None
Availability
High

Exploit likelihood

0.84%Up 0.8 points since Feb 13, 2025
90%50%10%1%

What each source reports

CVE List Score used 9.2

Koa has Inefficient Regular Expression Complexity

Koa is expressive middleware for Node.js using ES2017 async functions. Prior to versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3, Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack. Versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3 fix the issue.

Record
CVE-2025-25200
CVSS 4.0
9.2 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H
Weakness
CWE-1333
Updated
2026-11-02
EUVDEUVD-2025-4086 9.2

Koa is expressive middleware for Node.js using ES2017 async functions. Prior to versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3, Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack. Versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3 fix the issue.

Record
EUVD-2025-4086
CVSS 4.0
9.2 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H
Updated
2026-11-03
GitHub AdvisoriesGHSA-593f-38f6-jp5m 9.2

Inefficient Regular Expression Complexity in koa

Summary

Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack.

PoC

Coming soon.

Impact

This is a Regex Denial-of-Service attack and causes memory exhaustion. The regex should be improved and empty values should not be allowed.

Record
GHSA-593f-38f6-jp5m
CVSS 4.0
9.2 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H
Weakness
CWE-1333
Updated
2026-11-02
NVD 9.2

Koa is expressive middleware for Node.js using ES2017 async functions. Prior to versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3, Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack. Versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3 fix the issue.

Record
CVE-2025-25200
CVSS 4.0
9.2 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Weakness
CWE-1333
Updated
2026-11-02
OSV 9.2

Koa has Inefficient Regular Expression Complexity

Koa is expressive middleware for Node.js using ES2017 async functions. Prior to versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3, Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack. Versions 0.21.2, 1.7.1, 2.15.4, and 3.0.0-alpha.3 fix the issue.

Record
CVE-2025-25200
CVSS 4.0
9.2 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H
Weakness
CWE-1333
Updated
2026-11-02
OSVGHSA-593f-38f6-jp5m 9.2

Inefficient Regular Expression Complexity in koa

Summary

Koa uses an evil regex to parse the X-Forwarded-Proto and X-Forwarded-Host HTTP headers. This can be exploited to carry out a Denial-of-Service attack.

PoC

Coming soon.

Impact

This is a Regex Denial-of-Service attack and causes memory exhaustion. The regex should be improved and empty values should not be allowed.

Record
GHSA-593f-38f6-jp5m
CVSS 4.0
9.2 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H
Weakness
CWE-1333
Updated
2026-11-02
OSVCLSA-2026-1787657292 No score

TuxCare security update for koa (4 CVEs)

TuxCare rebuilt koa to address 4 CVEs. Fixed in 2.15.3-tuxcare.1.

Record
CLSA-2026-1787657292
Updated
2026-11-02
OSVCLSA-2026-1792779347 No score

TuxCare security update for koa (4 CVEs)

TuxCare rebuilt koa to address 4 CVEs. Fixed in 2.15.4-tuxcare.1.

Record
CLSA-2026-1792779347
Updated
2026-11-02
OSVROOT-APP-NPM-CVE-2025-25200 No score

CVE-2025-25200 in koa - Patched by Root

Root has patched CVE-2025-25200 in the koa package for Root:npm. Multiple fixed versions available.

Record
ROOT-APP-NPM-CVE-2025-25200
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
koa
npm
2.0.0 up to 2.15.4
2.15.4
koa
npm
3.0.0-alpha.0 up to 3.0.0-alpha.3
3.0.0-alpha.3
koa
npm
1.0.0 up to 1.7.1
1.7.1
koa
npm
before 0.21.2
0.21.2
koa
TuxCare:npm
From an advisory covering 4 CVEs
2.15.3-tuxcare.0 up to 2.15.3-tuxcare.1, plus listed versions
2.15.3
2.15.3-tuxcare.1
koa
TuxCare:npm
From an advisory covering 4 CVEs
2.15.4-tuxcare.0 up to 2.15.4-tuxcare.1, plus listed versions
2.15.4
2.15.4-tuxcare.1
koa
Root:npm
before 2.15.3-aikido.2
2.15.3-aikido.22.11.0-aikido.22.15.3-aikido.12.11.0-aikido.12.15.4-aikido.22.15.4-aikido.32.15.4-aikido.4
@rootio/koa
Root:npm
before 2.15.3-root.io.2
2.15.3-root.io.22.11.0-root.io.22.15.3-root.io.12.11.0-root.io.12.15.4-root.io.12.15.4-root.io.22.15.4-root.io.32.15.4-root.io.4

Public exploits

Links only. Every CVE stores no exploit code.

Public exploits
SourceLinkDate
PoC in GitHubdwictor0/PoC-CVE-2025-252002026-03-22
PoC in GitHubgduma-phData/patch-CVE-2025-252002026-08-24

History

History
RecordedChangedSources
affected, facts
aliases, publishedEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV, PoC in GitHub

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2025-25200 is a critical vulnerability (CVSS 9.2) in Koajs Koa, published February 12, 2025. Public exploit code exists. EPSS puts the chance of exploitation in the next 30 days at 0.84%, the 58th percentile. Fixed in koa 2.15.4.

References

Show 4 moreShow less
MoveEnter Open