preread post request body not returned for h2
|Reported by:||Owned by:|
|uname -a:||Linux 3.11.0-15-generic #25~precise1-Ubuntu SMP Thu Jan 30 17:39:31 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux|
nginx: nginx version: instart/nginx based on: 1.9.12
built by gcc 4.6.4 (Ubuntu/Linaro 4.6.4-1ubuntu1~12.04)
built with OpenSSL 1.0.2h-fips 3 May 2016
TLS SNI support enabled
I am experimenting with POST over h2. The use case is to read full request body in rewrite phase and process it for further undisclosed use. What I am seeing is if client request body is already read along with http headers by the time ngx_http_read_client_request_body function is called, the preread body is never returned to the post handler. This is unlike how http/1.1 works (relevant code in ngx_http_read_client_request_body function), that is, http/1.1 specific code returns the preread client request body to post handler.