---
id: "CVE-2026-78048"
kind: "vulnerability"
aliases: ["CVE-2026-78048"]
title: "Apache bRPC: crafted HPACK headers crash HTTP/2 and gRPC servers"
severity: "high"
cvss: null
epss: 0.00242
exploited: false
status: "open"
category: "package"
products: []
ecosystems: []
tags: ["bpc", "c++", "grpc", "http2", "package", "self-hosted"]
not_affected_if: ["http1-only", "internal-network-only", "not-using-brpc"]
published_at: "2026-10-21T12:17:23+00:00"
first_seen_at: "2026-10-23T21:57:28+00:00"
updated_at: "2026-10-25T05:02:39+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-78048", "first_seen_at": "2026-10-23T21:57:28+00:00"}, {"source": "epss", "url": "https://api.first.org/data/v1/epss?cve=CVE-2026-78048", "first_seen_at": "2026-10-24T13:15:54+00:00"}]
---

# Apache bRPC: crafted HPACK headers crash HTTP/2 and gRPC servers

A remote client can send a crafted sequence of HPACK-compressed HTTP/2 headers to a bRPC server, tripping an assertion that aborts the whole process. The result is a denial of service with no authentication needed.

_Summary, check and fix written by a model from the sources; labelled as such._

## How to check

- Run `grep -rn "brpc" CMakeLists.txt` or check your lock files and build manifests for the bRPC version in use
- Check that the bRPC library version is below `1.18.0` on any server that accepts HTTP/2 or gRPC traffic from untrusted networks

## Fix

- Upgrade Apache bRPC to `1.18.0` or later
- Alternatively, apply the patch from https://github.com/apache/brpc/pull/3462

## Timeline

- 2026-10-23T21:57:28+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-78048
- 2026-10-24T13:15:54+00:00 epss https://api.first.org/data/v1/epss?cve=CVE-2026-78048

## From the sources

A reachable-assertion flaw in the HPACK header-compression decoder of the HTTP/2 (h2/gRPC) stack in Apache bRPC (version < 1.18.0) on all platforms allows a remote attacker to crash the server process by sending a crafted sequence of HPACK headers, resulting in a denial of service.

Root Cause:
In src/brpc/details/hpack.cpp, IndexTable::Init sizes the dynamic-table ring buffer as num_headers = max_size / (32 + 2), i.e. it assumes a minimum table entry of 34 bytes (name >= 1 byte + value >= 1 byte + 32 bytes of overhead). However, RFC 7541 section 4.1 specifies that the minimum entry size is 33 bytes, because the value may be empty (name >= 1 byte + value == 0 + 32 bytes). For the default 4096-byte table this allocates only 120 slots (4096/34). Eviction in AddHeader is driven by byte usage (_max_size), not by slot count, so a peer can add 121 minimal 33-byte entries (121*33 = 3993 <= 4096) without triggering eviction. The 121st AddHeader then hits CHECK(!_header_queue.full()), which aborts the process.

Affected Scenarios:
Use a bRPC server that serves HTTP/2 or gRPC requests (e.g. via the h2 protocol) from an untrusted network. The malicious header block is processed during HPACK decoding of incoming requests without authentication.

How to Fix: 
(Choose one of the following options) 
1. Upgrade bRPC to version 1.18.0, which fixes this issue.
2. Apply this patch: https://github.com/apache/brpc/pull/3462

Note:
The fix sizes the dynamic table for the 33-byte minimum entry (max_size / (32 + 1)) and ensures at least one ring-buffer slot is kept when max_size is smaller than the minimum entry, so that initialization cannot fail on malloc(0).

---

_Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai_
