CVE-2021-39185
CRITICAL 9.1CVSS 3.1Default CORS config allows any origin with credentials
Http4s is a minimal, idiomatic Scala interface for HTTP services. In http4s versions 0.21.26 and prior, 0.22.0 through 0.22.2, 0.23.0, 0.23.1, and 1.0.0-M1 through 1.0.0-M24, the default CORS configuration is vulnerable to an origin reflection attack. The middleware is also susceptible to a Null Origin Attack. The problem is fixed in 0.21.27, 0.22.3, 0.23.2, and 1.0.0-M25. The original CORS implementation and CORSConfig are deprecated. See the GitHub GHSA for more information, including code examples and workarounds.
- Published
- 1 Sep 2021
- Last modified
- 8 Jul 2026
- Assigned by
- security-advisories@github.com
- NVD status
- Modified
- Weakness
- CWE-346
- Also known as
- GHSA-52cf-226f-rhr6
- Sources
- NVDJSONOSV GHSA-52cf-226f-rhr6JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | security-advisories@github.com (Secondary) | CVSS 3.1 | CRITICAL 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
| OSV | GitHub | CVSS 3.1 | CRITICAL 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | MEDIUM 6.4 | AV:N/AC:L/Au:N/C:P/I:P/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:*:*:*:*:*:*:*:* |
<= 0.21.26 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:*:*:*:*:*:*:*:* |
>= 0.22.0, <= 0.22.2 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:0.23.0:*:*:*:*:*:*:* |
= 0.23.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:0.23.1:*:*:*:*:*:*:* |
= 0.23.1 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone1:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone10:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone11:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone12:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone13:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone14:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone15:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone16:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone17:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone18:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone19:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone2:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone20:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone21:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone22:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone23:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone24:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone3:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone4:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone5:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone6:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone7:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone8:*:*:*:*:*:* |
= 1.0.0 | |
| NVD | typelevel | http4scpe:2.3:a:typelevel:http4s:1.0.0:milestone9:*:*:*:*:*:* |
= 1.0.0 | |
| OSV | Maven | org.http4s:http4s-server_2.13.0-M5 | all versions | |
| OSV | Maven | org.http4s:http4s-server_3 | >= 0.22.0, < 0.22.3 | 0.22.3 |
| OSV | Maven | org.http4s:http4s-server_3 | >= 0.23.0, < 0.23.2 | 0.23.2 |
| OSV | Maven | org.http4s:http4s-server_2.10 | all versions | |
| OSV | Maven | org.http4s:http4s-server_2.11 | all versions | |
| OSV | Maven | org.http4s:http4s-server_2.12 | < 0.21.27 | 0.21.27 |
| OSV | Maven | org.http4s:http4s-server_2.12 | >= 0.22.0, < 0.22.3 | 0.22.3 |
| OSV | Maven | org.http4s:http4s-server_2.12 | >= 0.23.0, < 0.23.2 | 0.23.2 |
| OSV | Maven | org.http4s:http4s-server_2.13 | < 0.21.27 | 0.21.27 |
| OSV | Maven | org.http4s:http4s-server_2.13 | >= 0.22.0, < 0.22.3 | 0.22.3 |
| OSV | Maven | org.http4s:http4s-server_2.13 | >= 0.23.0, < 0.23.2 | 0.23.2 |
References
- https://github.com/http4s/http4s/releases/tag/v0.23.2 · Third Party Advisory, WEB
- https://github.com/http4s/http4s/security/advisories/GHSA-52cf-226f-rhr6 · Patch, Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2021-39185 · ADVISORY
- https://github.com/http4s/http4s · PACKAGE
History
- 25 Nov 2026 20:33 UTC · NVD: first stored (published 1 Sep 2021)
- 25 Nov 2026 20:13 UTC · OSV: first stored (published 2 Sep 2021)