HTTPserver: support "chunked" Transfer-Encoding

This commit is contained in:
Matthew Zipkin
2025-03-12 14:51:31 -04:00
parent 80e1cfe5a2
commit 6734bcdeff
3 changed files with 199 additions and 22 deletions

View File

@@ -215,7 +215,7 @@ constexpr size_t MAX_HEADERS_SIZE{8192};
//! Maximum size of an HTTP request body
constexpr uint64_t MAX_BODY_SIZE{32_MiB};
//! Thrown when a request body exceeds MAX_BODY_SIZE
//! Thrown when a request body exceeds MAX_BODY_SIZE (or *will* exceed, in chunked transfer)
//! so the server can reply with more specific code 413 (content too large) vs general 400 (bad request)
struct ContentTooLargeError : std::runtime_error {
using std::runtime_error::runtime_error;