• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

elixir-mint / hpax
96%

Build:
DEFAULT BRANCH: main
Repo Added 24 Sep 2021 06:42AM UTC
Token w95jYetSpXwTO5No1xBXiaiwdSAxLPGlS regen
Build 51 Last
Files 4
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH main
branch: SELECT
CHANGE BRANCH
x
Sync Branches
  • No branch selected
  • al/1.18
  • al/elixir-req
  • al/huffman
  • al/update-elixir
  • andrea/coverage
  • andrea/dialyzer-in-ci
  • andrea/fix-ci
  • deprecation_warnings
  • elixir-1.17
  • fix-warnings
  • fix/huffman-decode-invalid-encoding
  • fix/static-table-empty-values
  • fix_resize
  • main
  • table_size_fixes
  • wm-fix-warnings
  • wm-validate-header

27 Jul 2026 08:06AM UTC coverage: 95.882%. Remained the same
7eea90af881d0fcd10b072cdb99a3f1d4021386b

push

github

web-flow
Use empty binary, not nil, for static table entries with no default value (#27)

HPAX.Table's @static_table stored `nil` as the value for the many
static entries that have no default (RFC 7541, Appendix A - e.g.
:authority, host, user-agent). Decoding a plain Indexed Header Field
Representation (section 6.1) against one of these entries - fully
legal per the RFC, and something real HTTP/2 clients (and h2spec) do
- returned that literal `nil` as the header value, silently violating
this module's own documented contract that decoded values are always
binaries (HPAX.header_value() :: binary()).

Any caller relying on that contract (e.g. calling byte_size/1 on
every decoded value) would crash on such a request. This also meant
the encoder could never emit a compact single-byte indexed reference
when asked to encode one of these headers with a literal empty-string
value, since the {:full, index} match required by lookup_by_header/3
was guarded with `is_binary(value)` and so never fired for the
nil-valued entries.

Storing "" instead of nil fixes both: decoded values are always
binaries as documented, and encoding a header whose value happens to
be "" for one of these names now correctly compresses to one byte.

* Test that encoding a static entry's default value compresses to one byte

Covers the encoder-side half of the previous commit's fix: headers
whose value matches a static table entry with no defined default
(e.g. "user-agent": "") can now be found via a {:full, index} match
and encoded as a single indexed-header-field byte, rather than always
falling back to a literal encoding because the {:full, _} lookup
clause was guarded with is_binary(value) and so never matched the
old nil-valued entries.

163 of 170 relevant lines covered (95.88%)

4275.42 hits per line

Relevant lines Covered
Build:
Build:
170 RELEVANT LINES 163 COVERED LINES
4275.42 HITS PER LINE
Source Files on main
  • Tree
  • List 4
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
7eea90af... main Use empty binary, not nil, for static table entries with no default value (#27) HPAX.Table's @static_table stored `nil` as the value for the many static entries that have no default (RFC 7541, Appendix A - e.g. :authority, host, user-agent). Deco... push 27 Jul 2026 08:09AM UTC web-flow github
95.88
05adfdc4... main Raise a catchable error on malformed Huffman-coded input (#26) HPAX.Huffman.decode/1 only handled two "end of input" cases: an exhausted binary, and 1-7 leftover bits that form valid EOS padding. Any input that leaves 8 or more trailing bits whic... push 25 Jul 2026 08:07PM UTC web-flow github
95.88
444a1d2f... fix/static-table-empty-values Test that encoding a static entry's default value compresses to one byte Covers the encoder-side half of the previous commit's fix: headers whose value matches a static table entry with no defined default (e.g. "user-agent": "") can now be found ... Pull #27 25 Jul 2026 06:55PM UTC mtrudel github
95.86
18a42a5e... fix/huffman-decode-invalid-encoding Use empty binary, not nil, for static table entries with no default value HPAX.Table's @static_table stored `nil` as the value for the many static entries that have no default (RFC 7541, Appendix A - e.g. :authority, host, user-agent). Decoding a... Pull #26 25 Jul 2026 02:15AM UTC mtrudel github
95.88
7719986d... fix/huffman-decode-invalid-encoding Raise a catchable error on malformed Huffman-coded input HPAX.Huffman.decode/1 only handled two "end of input" cases: an exhausted binary, and 1-7 leftover bits that form valid EOS padding. Any input that leaves 8 or more trailing bits which don'... Pull #26 25 Jul 2026 01:41AM UTC mtrudel github
95.88
8d9c57ab... main Release v1.0.4 push 05 Jul 2026 04:12PM UTC whatyouhide github
95.86
1ba4bb2d... main Merge commit from fork push 05 Jul 2026 04:09PM UTC web-flow github
95.86
6b4d69c0... main Fix warnings in Elixir 1.20 and require Elixir 1.15+ (#25) push 20 Jan 2026 08:20AM UTC web-flow github
95.81
c8c66831... fix-warnings Bump runner to 22.04 Pull #25 20 Jan 2026 08:08AM UTC sabiwara github
95.81
ae37c39f... fix-warnings Require Elixir 1.15+ Pull #25 19 Jan 2026 08:37AM UTC sabiwara github
96.41
See All Builds (47)

Badge your Repo: hpax

We detected this repo isn’t badged! Grab the embed code to the right, add it to your repo to show off your code coverage, and when the badge is live hit the refresh button to remove this message.

Could not find badge in README.

Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

Refresh
  • Settings
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc