Advisory

RUSTSEC-2023-0085

Also known as: GHSA-w7hm-hmxv-pvhf

Summary

HPACK decoder panics on invalid input

Details

Due to insufficient checking of input data, decoding certain data sequences can
lead to _Decoder::decode_ panicking rather than returning an error.

Example code that triggers this vulnerability looks like this:

use hpack::Decoder;

pub fn main() {
  let input = &[0x3f];
  let mut decoder = Decoder::new();
  let _ = decoder.decode(input);
}

hpack is unmaintained. A crate with the panics fixed has been published as
hpack-patched.

Also consider using
loona-hpack or
httlib-huffman as an alternative.

Version 0.3.1 of
fluke-hpack still reproduces the panic
described in this advisory.

Severity

Not rated by the source.

Dates

Published
2023-09-15 12:00 UTC
Modified
2026-07-22 17:45 UTC

Affected packages and fixes

hpack

crates.io · All systems

Affected

  • introduced 0.0.0-0 (semver)

Fixed versions

None listed

Fix

No fixed version is listed.

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: RustSec Advisory Database · CC0-1.0

Sources & licences