CVE-2021-21328
Description
Vapor is a web framework for Swift. In Vapor before version 4.40.1, there is a DoS attack against anyone who Bootstraps a metrics backend for their Vapor app. The following is the attack vector: 1. send unlimited requests against a vapor instance with different paths. this will create unlimited counters and timers, which will eventually drain the system. 2. downstream services might suffer from this attack as well by being spammed with error paths. This has been patched in 4.40.1. The `DefaultResponder` will rewrite any undefined route paths for to `vapor_route_undefined` to avoid unlimited counters.
Weakness
- CWE-400: Uncontrolled Resource Consumption
Timeline
- 2021-02-26Published by the CNA01:45 UTC
- 2023-06-09GitHub advisory published (GHSA-gcj9-jj38-hwmc)833 days after publication
Exploit and advisory records
GitHub advisory GHSA-gcj9-jj38-hwmc, affected packages:
| Package | Vulnerable versions | Fixed in |
|---|---|---|
| SwiftURL github.com/vapor/vapor | before 4.40.1 | 4.40.1 |
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| vapor_project vapor | before 4.40.1fixed in 4.40.1 | 4.40.1 |
References
- https://github.com/vapor/vapor/commit/e3aa712508db2854ac0ab905696c65fd88fa7e23
- https://github.com/vapor/vapor/releases/tag/4.40.1
- https://github.com/vapor/vapor/security/advisories/GHSA-gcj9-jj38-hwmc
- https://vapor.codes/
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2021-21328'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2021-21328'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2021-21328'curl 'https://api.contrastcyber.com/cve_products/CVE-2021-21328'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).