Tatsuhiro Tsujikawa
40a666e7d1
Add nghttp2_submit_response2 tests
2013-11-28 21:47:10 +09:00
Tatsuhiro Tsujikawa
e57b3a2139
Set protocol ID to draft-08 temporarily
2013-11-21 21:58:45 +09:00
Tatsuhiro Tsujikawa
3d863ed254
nghttp2_hd: Clear reference set with index 0
2013-11-16 17:05:18 +09:00
Tatsuhiro Tsujikawa
94ec4dbe42
nghttpd_hd: Update static table and use 1-based index
...
The specification now says that index to the header table entry is
1-based. Since 0-based index is very handy to access arrays, we
internally uses 0-based index. We just convert it to 1-based when
we emit to the block and convert 1-based to 0-based on decoding.
2013-11-16 16:18:44 +09:00
Tatsuhiro Tsujikawa
40347487c9
Don't sort headers in library code
...
Remove sorting headers from library code. The application must sort
them if necessary. nghttpx and nghttpd do the sorting of the headers
in stable way if names are equal.
2013-11-13 23:56:02 +09:00
Tatsuhiro Tsujikawa
2ae788eddd
Replace nghttp2_set_option with nghttp2_session_{client,server}_new2
...
nghttp2_session_client_new2 and nghttp2_session_server_new2 take
additional parameters which specifies session options.
nghttp2_set_option is somewhat crumsy because of type checking.
Now we use nghttp2_opt_set, which specifies individual options with
types. We changed the value of nghttp2_opt, so this change will
require re-compile.
2013-11-08 00:12:39 +09:00
Tatsuhiro Tsujikawa
d5c1eb04c9
Update .gitignore
2013-11-04 18:39:48 +09:00
Tatsuhiro Tsujikawa
8cd2b57f8a
tests: Add test for header compression without indexing
2013-11-03 18:30:57 +09:00
Tatsuhiro Tsujikawa
7b3dade184
tests: Fix memory leak
2013-11-02 16:55:58 +09:00
Tatsuhiro Tsujikawa
4bc44b0c0b
Implement SETTINGS_ENABLE_PUSH
...
It is not clear that SETTINGS_ENABLE_PUSH = 0 disallows HEADERS
to the reserved streams. For now, we just check the reception
and transmission of PUSH_PROMISE against SETTINGS_ENABLE_PUSH.
2013-11-02 16:53:06 +09:00
Tatsuhiro Tsujikawa
9ee468ce62
tests: Remove unused function strcopy
2013-11-01 00:32:31 +09:00
Tatsuhiro Tsujikawa
f2f8300b62
Add more tests for nghttp2_adjust_local_window_size
2013-10-31 21:26:53 +09:00
Tatsuhiro Tsujikawa
49b8ea1bf3
tests: Add failmalloc tests
2013-10-31 02:02:00 +09:00
Tatsuhiro Tsujikawa
ad64f11a95
Remove code submitting WINDOW_UPDATE with negative delta
...
It is effectively dead code because we should have already submit
WINDOW_UPDATE before this case happens.
2013-10-30 23:43:40 +09:00
Tatsuhiro Tsujikawa
2e7bc014e1
Return 0 if recv_window_size is negative; add tests
2013-10-30 01:58:38 +09:00
Tatsuhiro Tsujikawa
6c99ff12c9
nghttp2_hd: Rename local as deflate
2013-10-29 00:42:08 +09:00
Tatsuhiro Tsujikawa
2dd44746a6
Merge branch 'master' into hpack-exp
2013-10-28 23:15:14 +09:00
Tatsuhiro Tsujikawa
a416891454
tests: Fix test error on 32-bit system
2013-10-28 22:00:49 +09:00
Tatsuhiro Tsujikawa
924c858c8f
tests: Add SETTINGS_HEADER_TABLE_SIZE test case
2013-10-28 01:08:09 +09:00
Tatsuhiro Tsujikawa
8c530f36cb
Include std lib headers before cunit header file
2013-10-27 23:20:44 +09:00
Tatsuhiro Tsujikawa
683253e334
Declare HTTP-draft-07/2.0
2013-10-27 23:16:49 +09:00
Tatsuhiro Tsujikawa
67ce60544e
Change maximum frame length to 16383
2013-10-27 21:17:09 +09:00
Tatsuhiro Tsujikawa
cfb9857f27
Use FRAME_SIZE_ERROR for invalid payload length
2013-10-27 20:55:44 +09:00
Tatsuhiro Tsujikawa
5ace898392
Update error code
2013-10-27 19:31:24 +09:00
Tatsuhiro Tsujikawa
a46ccdb144
Apply initiated SETTINGS changes on reception of ACK
2013-10-27 19:22:51 +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
8f8c841df0
Merge branch 'master' into hpack-exp
2013-10-25 22:51:51 +09:00
Tatsuhiro Tsujikawa
896db5b24f
API change: Add flags parameter to all submit_* functions
...
The nghttp2_submit_{request,response} family do not get this change.
2013-10-25 22:50:24 +09:00
Tatsuhiro Tsujikawa
5a81e03497
nghttp2_hd: Add static table entry to dynamic table on emission
2013-10-24 21:52:02 +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
Tatsuhiro Tsujikawa
4e4fab01b1
Merge branch 'master' into hpack-exp
...
Conflicts:
lib/nghttp2_hd.c
2013-10-18 20:06:36 +09:00
Tatsuhiro Tsujikawa
0efa6e657f
Fix outbound flow control count
...
We wrongly added the whole payload length even if we sent part of it.
2013-10-18 19:43:59 +09:00
Tatsuhiro Tsujikawa
5add90489f
Protocol ID change for HPACK experiment
2013-10-16 01:19:06 +09:00
Tatsuhiro Tsujikawa
ed43635c7b
Updated latest initial static header table
2013-10-16 00:09:00 +09:00
Tatsuhiro Tsujikawa
50cdcca911
Implement static Huffman for header compression
...
The current implementation uses Huffman code tables described
in http://tools.ietf.org/html/draft-rpeon-httpbis-header-compression-03
2013-10-15 23:55:12 +09:00
Tatsuhiro Tsujikawa
8cf3731802
Experiment HPACK with upcoming changes
...
* remove substitution
* reversed insertion and removal from header table
* unified initial static table
2013-10-12 21:49:01 +09:00
Tatsuhiro Tsujikawa
e85418f045
Fix local window size adjustments
...
Now shrinking local window size properly limits the amount of
WINDOW_UPDATE value so that shrinked window is honored.
2013-10-12 17:02:37 +09:00
Tatsuhiro Tsujikawa
c5501dcb8d
tests: Test WINDOW_UPDATE is queued when certain amount of DATA is received
2013-10-04 21:42:02 +09:00
Tatsuhiro Tsujikawa
21d76dcc75
Add nghttp2_session_continue API function
...
The NGHTTP2_ERR_PAUSE library error code is introduced to pause
the execution of nghttp2_session_mem_recv() when that error code
is returned from nghttp2_on_frame_recv_callback or
nghttp2_on_data_chunk_recv_callback. If this happens, the parameters
available for both callbacks are retained until the application
calls nghttp2_session_continue(). The application must retain
input bytes which was used to produce the frame.
After successful call of nghttp2_session_continue, the application
can continue to call nghttp2_session_mem_recv() to process
additional data.
2013-09-28 17:59:24 +09:00
Tatsuhiro Tsujikawa
b14a97a273
Update .gitignore
2013-09-14 21:18:08 +09:00
Tatsuhiro Tsujikawa
99ba622fed
Add NGHTTP2_OPT_PEER_MAX_CONCURRENT_STREAMS option
...
And utilize it in nghttp to limit initial max concurrent streams.
2013-09-14 19:41:49 +09:00
Tatsuhiro Tsujikawa
94263216fb
Add nghttp2_submit_request2
...
This function is similar to nghttp2_submit_request and the
difference is it takes an array of nghttp2_nv as name/value pairs.
It is useful if name/value pairs is not NULL-terminated in the
application code.
2013-09-11 00:55:35 +09:00
Daniel Stenberg
a1c3f89c72
nghttp2_pack_settings_payload: added a buffer size argument
...
To make it less likely that a user gets a buffer overflow if a
too small buffer is used.
2013-09-09 21:22:27 +09:00
Tatsuhiro Tsujikawa
a6a394902e
tests: Fix out-of-bound read
2013-09-08 23:16:25 +09:00
Tatsuhiro Tsujikawa
a67d042a00
tests: Fix buffer overrun
2013-09-08 15:29:46 +09:00
Tatsuhiro Tsujikawa
2c127b5cb6
Remove unused functions/macros
2013-09-07 15:48:16 +09:00
Tatsuhiro Tsujikawa
4dcf9ad4f2
Make hd encoder ordering aware and one-pass
...
The encoder algorithm is simplified and it now preserves ordering
of the headers. It also becomes one-pass encoder.
2013-09-06 21:53:28 +09:00
Tatsuhiro Tsujikawa
d960cf8953
Add const to read-only nghttp2_frame* parameter in callbacks
2013-09-03 21:24:14 +09:00
Tatsuhiro Tsujikawa
053c444769
Add int return value to nghttp2_on_request_recv_callback
2013-08-29 23:03:21 +09:00