Tatsuhiro Tsujikawa
e147c14186
Remove ent_name member and use index solely
2014-07-31 23:05:52 +09:00
Tatsuhiro Tsujikawa
06453fb15e
Remove unused role member in nghttp2_hd_context
2014-07-31 23:05:52 +09:00
Tatsuhiro Tsujikawa
744ec4dba1
Don't copy static header and put static table in front of dynamic table
2014-07-31 23:05:52 +09:00
Tatsuhiro Tsujikawa
38bfbffb1b
Remove HPACK reference set
2014-07-31 23:05:52 +09:00
Tatsuhiro Tsujikawa
57e9b94aaa
Handle header table size up to UINT32_MAX
2014-07-22 22:38:18 +09:00
Tatsuhiro Tsujikawa
44310c6de5
Fix integer decoding when it takes multiple reads
2014-07-22 01:50:29 +09:00
Tatsuhiro Tsujikawa
d99e1135c8
Search static header table linearly
2014-07-20 19:13:56 +09:00
Tatsuhiro Tsujikawa
bd06f2cec3
Add const qualifier to nva parameter in nghttp2_hd_deflate_hd()
2014-06-29 23:43:14 +09:00
Tatsuhiro Tsujikawa
d318e6a62e
Support one header field size (name + value) up to 64KiB by default
...
This commits changes the upper bound of one header field size (the sum
of the length of name and value) to 64KiB by default. We may add an
option to change this upper bound in the future.
2014-06-28 11:04:41 +09:00
Tatsuhiro Tsujikawa
d113055899
nghttp2_hd: Use single buffer for an name/value pair
...
Previously we use 2 separate buffer for each name and value. The
problem is we would waste buffer space for name because it is usually
small. Also tuning buffer size for each buffer separately is not
elegant and current HTTP server practice is that one buffer for 1
name/value pair. This commit unifies 2 buffers into 1.
2014-05-28 23:33:37 +09:00
Tatsuhiro Tsujikawa
7b9a8acc22
Add HPACK deflation API
2014-05-13 23:42:55 +09:00
Tatsuhiro Tsujikawa
062d6a8398
Remove outdated comment
2014-05-12 22:58:05 +09:00
Tatsuhiro Tsujikawa
ab76468971
Return NGHTTP2_ERR_BUFFER_ERROR from nghttp2_hd_{deflate,inflate}_hd
...
It is generally useful to know what is the cause of the error. Since
we expose HPACK API, it is friendly to tell application the
insufficient buffer size is a culprit.
2014-05-12 22:58:04 +09:00
Tatsuhiro Tsujikawa
9683f88e6a
Add NGHTTP2_DEFAULT_HEADER_TABLE_SIZE macro
...
Use this macro in Python sources. Python module constant
HD_DEFLATE_HD_TABLE_BUFSIZE_MAX was renamed as
DEFLATE_MAX_HEADER_TABLE_SIZE since the previous name was awkward.
2014-05-11 21:38:30 +09:00
Tatsuhiro Tsujikawa
2e5c7f598f
Fix bug HPACK deflater does not send context update after table size change
2014-05-11 21:25:27 +09:00
Alexis La Goutte
0f5c28ac46
Fix GCC when use -Wpedantic
...
nghttp2_hd.h:115:30: error: comma at end of enumerator list [-Werror=pedantic]
2014-04-30 17:09:05 +02:00
Tatsuhiro Tsujikawa
660c536275
Extend namelen and valuelen in nghttp2_nv to size_t
2014-04-30 23:08:34 +09:00
Tatsuhiro Tsujikawa
167a1102e0
Remove unused NGHTTP2_HD_MAX_BUFFER_LENGTH macro
2014-04-30 10:55:43 +09:00
Tatsuhiro Tsujikawa
3b4aedd566
Add HPACK decoder public API
2014-04-29 15:53:46 +09:00
Tatsuhiro Tsujikawa
7877b676e3
Honor NGHTTP2_NV_FLAG_NO_INDEX in deflater and inflater
2014-04-02 01:25:44 +09:00
Tatsuhiro Tsujikawa
ab2dc5967d
Replace HTTP/2.0 with HTTP/2
2014-03-30 19:26:37 +09:00
Tatsuhiro Tsujikawa
d07bb1ddff
Rework outbound frame buffers
2014-03-13 22:11:02 +09:00
Tatsuhiro Tsujikawa
3f56c938d8
nghttp2_hd: Use nghttp2_bufs, avoiding realloc()
2014-03-11 21:18:28 +09:00
Tatsuhiro Tsujikawa
358b4386d3
Introduce nghttp2_buf to ease buffer management
2014-03-11 01:47:38 +09:00
Tatsuhiro Tsujikawa
fd88c6160d
HPACK post -05 updates
...
* Use 1 Huffman code table for both request and response
* Remove complicated deflater side table size management
* Add encoding context update
* Fix memory leak in inflater
2014-02-13 23:22:52 +09:00
Tatsuhiro Tsujikawa
9314e30987
Support transmission of CONTINUATION, change nghttp2_frame_hd
...
The maximum frame size including header block is still limited
to NGHTTP2_HD_MAX_BUFFER_LENGTH, which is 32KB.
2014-01-26 23:10:33 +09:00
Tatsuhiro Tsujikawa
e7fc2951b8
nghttp2_hd: Define dedicated struct for HPACK deflater and inflater
2014-01-26 17:53:04 +09:00
Tatsuhiro Tsujikawa
8317559090
nghttp2_hd: Implement stream header inflater
...
This stream inflater can inflate incoming header block in streaming
fashion. Currently, we buffer up single name/value pair, but we chose
far more smaller buffer size than HTTP/2 frame size.
2014-01-25 18:24:15 +09:00
Tatsuhiro Tsujikawa
f8a446fbeb
nghttp2_hd: Rewrite huffman decoding
2014-01-24 21:56:19 +09:00
Tatsuhiro Tsujikawa
201ab1a140
nghttp2_hd: Adjust maximum size to index based on table size
2014-01-21 21:49:53 +09:00
Tatsuhiro Tsujikawa
1daf6de102
Update doc
2014-01-17 09:41:39 +09:00
Tatsuhiro Tsujikawa
073e6d3a01
nghttp2_hd: Remove unused variables
2014-01-17 09:36:38 +09:00
Tatsuhiro Tsujikawa
0e4b3d435e
Emit header name/value pair using callback functions
...
Now, in nghttp2_on_frame_recv_callback, nva and nvlen in
HEADERS and PUSH_PROMISE frames are always NULL and 0 respectively.
The header name/value pairs are emitted successive
nghttp2_on_header_callback functions. The end of header fields are
signaled with nghttp2_on_end_headers_callback function.
Since NGHTTP2_ERR_PAUSE for nghttp2_on_frame_recv_callback is
introduced to handle header block, it is now deprecated.
Instead, nghttp2_on_header_callback can be paused using
NGHTTP2_ERR_PAUSE.
2014-01-17 01:49:43 +09:00
Tatsuhiro Tsujikawa
5d788e9753
nghttp2_hd: Move pointer variables before size_t
2014-01-12 19:28:57 +09:00
Tatsuhiro Tsujikawa
0fb4d32d6a
nghttp2_hd: Binary search static table
2014-01-07 23:41:09 +09:00
Tatsuhiro Tsujikawa
468d0fccd3
nghttp2_hd: Use hash to speed up name/value pair search
2014-01-07 22:43:34 +09:00
Tatsuhiro Tsujikawa
9eb031ce83
nghttp2_hd: Avoid nghttp2_hd_huff_decode_count
...
Huffman decoding is costly. It is faster to do geometric realloc
than calling nghttp2_hd_huff_decode_count to know the length in
advance.
2014-01-07 21:44:56 +09:00
Tatsuhiro Tsujikawa
01266182e9
nghttp2_hd: Match deflate_hd_tablelen to hd_table.len on decoder side
2013-12-17 21:39:21 +09:00
Tatsuhiro Tsujikawa
0867b57c39
Update doc
2013-12-14 18:59:09 +09:00
Tatsuhiro Tsujikawa
e61876ccbd
nghttp2_hd: Provide dedicated function to enable no reference set feature
2013-12-14 18:48:41 +09:00
Tatsuhiro Tsujikawa
6ea91e57e0
Adjust struct/class alignment
2013-12-06 23:17:38 +09:00
Tatsuhiro Tsujikawa
8915e91b17
nghttp2_hd: Enlarge buffers used in inflation process dynamically
2013-11-16 23:13:46 +09:00
Tatsuhiro Tsujikawa
3d863ed254
nghttp2_hd: Clear reference set with index 0
2013-11-16 17:05:18 +09:00
Tatsuhiro Tsujikawa
5696a65c5e
nghttp2_hd: Update doc
2013-11-16 16:33:38 +09:00
Tatsuhiro Tsujikawa
b0f76773e1
nghttp2_hd: Use defalte_hd_table_bufsize for decoder as well
2013-10-31 01:51:16 +09:00
Tatsuhiro Tsujikawa
6c99ff12c9
nghttp2_hd: Rename local as deflate
2013-10-29 00:42:08 +09:00
Tatsuhiro Tsujikawa
cbdd44c4ae
nghttp2_hd: Implement local header table size limit for encoder
2013-10-26 18:49:23 +09:00
Tatsuhiro Tsujikawa
0c3cb104e9
nghttp2_hd: Share static table globally
2013-10-24 22:09:40 +09:00
Tatsuhiro Tsujikawa
d5ccc89fc4
Update huffman table and static table
...
Use huffman table in https://github.com/grmocg/httpbis-header-compression
2013-10-21 23:56:14 +09:00
Tatsuhiro Tsujikawa
9e50ae46d9
nghttp_hd: Use NGHTTP2_HD_SIDE_{REQUEST,RESPONSE} instead of {CLIENT,SERVER}
...
This change conveys better notion about compression context.
2013-10-21 00:44:39 +09:00