Fix HPACK/QPACK decoding of excessively large variable-length integers.

HPACK decoders will emit a compression error if a variable-length integer, used for index or string length, exceeds `uint32_t::max()`.

The fix to index decoding will actually fail any HPACK entry with index value larger than 2^32 received on the wire which is currently decoded into a wrong 32-bit integer.

We are already failing excessively long string literals in current implementation of HPACK and QPACK, so the fix to string length decoding will just fail the entry in earlier stage. But on a 32-bit platform, the current implementation won't be sufficient.

Protected by FLAGS_gfe2_reloadable_flag_http2_hpack_varint_decoding_fix, default true.

PiperOrigin-RevId: 795187015
7 files changed
tree: ed6c936ef7bf9b77878848f1b94e112617afc031
  1. build/
  2. depstool/
  3. quiche/
  4. .bazelrc
  5. .bazelversion
  6. BUILD.bazel
  7. CONTRIBUTING.md
  8. LICENSE
  9. MODULE.bazel
  10. MODULE.bazel.lock
  11. README.md
  12. WHITESPACE
README.md

QUICHE

QUICHE stands for QUIC, Http, Etc. It is Google‘s production-ready implementation of QUIC, HTTP/2, HTTP/3, and related protocols and tools. It powers Google’s servers, Chromium, Envoy, and other projects. It is actively developed and maintained.

There are two public QUICHE repositories. Either one may be used by embedders, as they are automatically kept in sync:

To embed QUICHE in your project, platform APIs need to be implemented and build files need to be created. Note that it is on the QUICHE team's roadmap to include default implementation for all platform APIs and to open-source build files. In the meanwhile, take a look at open source embedders like Chromium and Envoy to get started:

To contribute to QUICHE, follow instructions at CONTRIBUTING.md.

QUICHE is only supported on little-endian platforms.