HTTP/1 server crash due to MaxBytesReader header race in net/http

State
Published
Severity
5.9 Medium
Published
Nov 11, 2026
Updated
Nov 16, 2026
Reserved
Sep 23, 2026

Read the record on cve.org

Description

For HTTP/1 servers, when MaxBytesReader's limit is exceeded, "Connection: close" header is automatically set without synchronization, which might race with another header being set explicitly in the server handler. As a result, an HTTP/1 server that utilizes MaxBytesReader or MaxBytesHandler can crash due to runtime panic if its handler reads the request body concurrently with writing the response header.

ProductVersions
net/http Go standard librarybefore 1.26.11 Affected1.27.0-0 to before 1.27.4 Affected

Weaknesses

  • CWE-820 Missing Synchronization
  • CWE-362 Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')

References

Every record here comes from the CVE Program's CVE List. © 1999-2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.

© 2026 NVIDIA, the NVIDIA logo, and NVIDIA Inception are trademarks and/or registered trademarks of NVIDIA Corporation in the U.S. and other countries.