Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2025-58369: CWE-400: Uncontrolled Resource Consumption in typelevel fs2

0
Medium
VulnerabilityCVE-2025-58369cvecve-2025-58369cwe-400
Published: Fri Sep 05 2025 (09/05/2025, 21:59:58 UTC)
Source: CVE Database V5
Vendor/Project: typelevel
Product: fs2

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.

AI-Powered Analysis

AILast updated: 11/07/2025, 12:26:34 UTC

Technical Analysis

CVE-2025-58369 is a denial of service vulnerability categorized under CWE-400 (Uncontrolled Resource Consumption) affecting the typelevel fs2 library, a compositional streaming I/O library for Scala. The vulnerability impacts versions up to 2.5.12, 3.0.0-M1 through 3.12.2, and 3.13.0-M1 through 3.13.0-M6. It specifically arises during TLS session establishment on the JVM when using the fs2.io.net.tls package. The issue occurs if one side of a TLS connection shuts down its write channel while the peer side is still awaiting data to progress the TLS handshake. This causes the peer to enter a spin loop on socket read operations, resulting in full CPU utilization on that thread until the connection is closed. This behavior can lead to denial of service by exhausting CPU resources, potentially shutting down servers relying on fs2-io for TLS communication. The vulnerability requires no authentication or user interaction and can be triggered remotely over the network. The CVSS v3.1 base score is 5.3 (medium severity), reflecting network attack vector, low complexity, no privileges required, no user interaction, and impact limited to availability. The issue is resolved in fs2 versions 2.5.13, 3.12.1, and 3.13.0-M7. No known exploits in the wild have been reported as of the publication date. This vulnerability highlights the risks of resource exhaustion attacks in asynchronous streaming libraries handling TLS handshakes.

Potential Impact

For European organizations, this vulnerability poses a risk of denial of service on servers using vulnerable versions of the fs2 library for TLS streaming I/O on the JVM. Such denial of service could disrupt critical services, degrade performance, and cause downtime, impacting business continuity and user experience. Organizations in sectors like finance, telecommunications, and public services that rely on Scala-based JVM applications for secure streaming communications are particularly vulnerable. The CPU exhaustion caused by the spin loop can lead to increased operational costs and potential cascading failures if load balancing or failover mechanisms are insufficient. Although no data confidentiality or integrity impact is present, availability degradation can have significant operational consequences. Given the network-exploitable nature and no authentication requirement, attackers can remotely trigger this condition, increasing the threat surface. European entities with large Scala developer communities or those using typelevel fs2 in production should assess their exposure and prioritize patching to avoid service interruptions.

Mitigation Recommendations

The primary mitigation is to upgrade the fs2 library to a fixed version: 2.5.13, 3.12.1, or 3.13.0-M7 or later. Organizations should audit their codebases and dependencies to identify usage of vulnerable fs2 versions, especially in JVM applications handling TLS streams. Implementing robust monitoring of CPU utilization and network socket states can help detect anomalous spin loops indicative of exploitation attempts. Network-level protections such as rate limiting or connection throttling on TLS endpoints may reduce the risk of resource exhaustion. Employing circuit breakers or timeout mechanisms in the application logic to detect stalled TLS handshakes can prevent indefinite CPU consumption. Additionally, conducting regular dependency updates and integrating vulnerability scanning into CI/CD pipelines will help prevent future exposure. For critical infrastructure, consider isolating vulnerable services behind load balancers or proxies that can absorb or mitigate denial of service attempts until patches are applied.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
GitHub_M
Date Reserved
2025-08-29T16:19:59.012Z
Cvss Version
3.1
State
PUBLISHED

Threat ID: 68bb6059535f4a9773160d1a

Added to database: 9/5/2025, 10:12:41 PM

Last enriched: 11/7/2025, 12:26:34 PM

Last updated: 12/7/2025, 7:09:46 AM

Views: 127

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats