CyberSecBulletin
CVE-2023-39325NVD status: Modified

net/http: Allocation of Resources Without Limits or Throttling

CVE-2023-39325 is a high-severity allocation of resources without limits or throttling vulnerability in net/http from Go standard library, with a CVSS 3.1 base score of 7.5 out of 10. It can be exploited remotely over the network by an unauthenticated attacker, without any action from a user. The record lists versions 1.20.10, 1.21.3 as the first without the flaw, so updating net/http to one of those releases or later removes the exposure. There is no confirmed exploitation so far. EPSS estimates a 3.8% chance of exploitation within 30 days, which is in the top 9.83% of all scored CVEs.

Next patch cycle

High severity with no evidence of exploitation so far.

What to do

  1. Update net/http to 1.20.10 or 1.21.3, whichever matches your release line, or a later version.
  2. Update golang.org/x/net/http2 to 0.17.0 or a later version.
  3. Update Go to 1.20.10 or 1.21.3, whichever matches your release line, or a later version.
  4. Read the advisory on go.dev for workarounds and exact fixed builds.
  5. Until you can update, restrict network access to the affected service so it is not reachable from untrusted networks.

Affected products and versions

VendorProductAffected versionsFixed in
Go standard librarynet/httpbefore 1.20.10; 1.21.0-0 up to, but not including, 1.21.31.20.10, 1.21.3
Golang.org/x/netgolang.org/x/net/http2before 0.17.00.17.0
GoGo1.20.0 up to, but not including, 1.20.10; 1.21.0 up to, but not including, 1.21.31.20.10, 1.21.3
GoHttp2before 0.17.00.17.0
Fedora ProjectFedora37; 38; 39Not stated
NetAppAstra TridentNot specified in the recordNot stated
NetAppAstra Trident AutosupportNot specified in the recordNot stated

Version data comes from the organisation that assigned the CVE. Confirm against the vendor advisory before deciding you are unaffected.

How the severity score breaks down

Attack vector
NetworkCan be exploited remotely over a network, including the internet.
Attack complexity
LowNo special conditions are needed; the attack works reliably.
Privileges required
NoneNo account or login is needed.
User interaction
NoneNo action by a victim is required.
Scope
UnchangedImpact stays within the vulnerable component.
Confidentiality
NoneNo data is disclosed.
Integrity
NoneNothing can be modified.
Availability
HighThe component can be taken down completely.

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H. Scored by NVD.

Official description

A malicious HTTP/2 client which rapidly creates requests and immediately resets them can cause excessive server resource consumption. While the total number of requests is bounded by the http2.Server.MaxConcurrentStreams setting, resetting an in-progress request allows the attacker to create a new request while the existing one is still executing. With the fix applied, HTTP/2 servers now bound the number of simultaneously executing handler goroutines to the stream concurrency limit (MaxConcurrentStreams). New requests arriving when at the limit (which can only happen after the client has reset an existing, in-flight request) will be queued until a handler exits. If the request queue grows too large, the server will terminate the connection. This issue is also fixed in golang.org/x/net/http2 for users manually configuring HTTP/2. The default stream concurrency limit is 250 streams (requests) per HTTP/2 connection. This value may be adjusted using the golang.org/x/net/http2 package; see the Server.MaxConcurrentStreams setting and the ConfigureServer function.

Source: the CVE record as published by its numbering authority, via NVD and CVE.org.

The underlying weakness: Allocation of Resources Without Limits or Throttling

The product allocates a reusable resource or group of resources on behalf of an actor without imposing any intended restrictions on the size or number of resources that can be allocated.

How developers prevent this class of flaw

  • Clearly specify the minimum and maximum expectations for capabilities, and dictate which behaviors are acceptable when resource allocation reaches limits.
  • Limit the amount of resources that are accessible to unprivileged users. Set per-user limits for resources. Allow the system administrator to define these limits. Be careful to avoid CWE-410.
  • For any security checks that are performed on the client side, ensure that these checks are duplicated on the server side, in order to avoid CWE-602. Attackers can bypass the client-side checks by modifying values after the checks have been performed, or by changing the client to remove the client-side checks entirely. Then, these modified values would be submitted to the server.

More Allocation of Resources Without Limits or Throttling vulnerabilities (CWE-770)

Timeline

  1. CVE record published.
  2. Record last changed materially (score, affected products, status or references).

References

Third-party and government advisories

Other references

Other vulnerabilities in net/http

All net/http vulnerabilities

Recent Allocation of Resources Without Limits or Throttling vulnerabilities

Spotted an error? Tell us.