CVE-2025-58369 fs2: Half-shutdown of socket during TLS handshake may result in spin loop on opposite side
An attacker can cause a CPU spin loop and denial of service in fs2-io TLS sessions by half-shutting down the socket during handshake.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2025-58369?
CVE-2025-58369 is a medium-severity denial of service vulnerability in typelevel fs2, published on 5 Sep 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
fs2 is a compositional, streaming I/O library for Scala. Versions up to and including 2.5.12, 3.0.0-M1 through 3.12.2, and 3.13.0-M1 through 3.13.0-M6 are vulnerable to denial of service attacks though TLS sessions using fs2-io on the JVM using the fs2.io.net.tls package. When establishing a TLS session, if one side of the connection shuts down `write` while the peer side is awaiting more data to progress the TLS handshake, the peer side will spin loop on the socket read, fully utilizing a CPU. The CPU is consumed until the overall connection is closed, potentially shutting down a fs2-io powered server. This issue is fixed in versions 2.5.13, 3.12.1, and 3.13.0-M7.
Weakness: CWE-400
Which versions are affected by CVE-2025-58369?
34 open source packages ship an affected version, including co.fs2:fs2-io_2.12, co.fs2:fs2-io_0.26 and co.fs2:fs2-io_0.27.
| Package | Affected | Fixed in |
|---|---|---|
co.fs2:fs2-io_2.12 Maven | All versions | 2.5.13 |
co.fs2:fs2-io_2.12 Maven | All versions | 2.5.13 |
co.fs2:fs2-io_2.12 Maven | From 3.0.0-M1 | 3.12.2 |
co.fs2:fs2-io_2.12 Maven | From 3.0.0-M1 | 3.12.2 |
co.fs2:fs2-io_2.12 Maven | From 3.13.0-M1 | 3.13.0-M7 |
co.fs2:fs2-io_2.12 Maven | From 3.13.0-M1 | 3.13.0-M7 |
28 more packages
co.fs2:fs2-io_0.26 Maven | All versions | None |
co.fs2:fs2-io_0.26 Maven | All versions | None |
co.fs2:fs2-io_0.27 Maven | All versions | None |
co.fs2:fs2-io_0.27 Maven | All versions | None |
co.fs2:fs2-io_2.11 Maven | All versions | None |
co.fs2:fs2-io_2.11 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-M4 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-M4 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-M5 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-M5 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-RC1 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-RC1 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-RC2 Maven | All versions | None |
co.fs2:fs2-io_2.12.0-RC2 Maven | All versions | None |
co.fs2:fs2-io_2.13 Maven | All versions | 2.5.13 |
co.fs2:fs2-io_2.13 Maven | All versions | 2.5.13 |
co.fs2:fs2-io_2.13 Maven | From 3.0.0-M1 | 3.12.2 |
co.fs2:fs2-io_2.13 Maven | From 3.0.0-M1 | 3.12.2 |
co.fs2:fs2-io_2.13 Maven | From 3.13.0-M1 | 3.13.0-M7 |
co.fs2:fs2-io_2.13 Maven | From 3.13.0-M1 | 3.13.0-M7 |
co.fs2:fs2-io_2.13.0-M5 Maven | All versions | None |
co.fs2:fs2-io_2.13.0-M5 Maven | All versions | None |
co.fs2:fs2-io_3 Maven | All versions | 2.5.13 |
co.fs2:fs2-io_3 Maven | All versions | 2.5.13 |
co.fs2:fs2-io_3 Maven | From 3.0.0-M1 | 3.12.2 |
co.fs2:fs2-io_3 Maven | From 3.0.0-M1 | 3.12.2 |
co.fs2:fs2-io_3 Maven | From 3.13.0-M1 | 3.13.0-M7 |
co.fs2:fs2-io_3 Maven | From 3.13.0-M1 | 3.13.0-M7 |
How do I fix CVE-2025-58369?
Upgrade co.fs2:fs2-io_2.12 to a fixed version for your release line: 2.5.13, 3.12.2 or 3.13.0-M7.
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-58369 being exploited?
There is no known exploitation of CVE-2025-58369 in the wild and no public exploit code.
Sources
Also known as GHSA-rrw2-px9j-qffj.