ngx_chunkin v0.20: fixed some memory bugs and added support for chunked PUT

agentzh agentzh at gmail.com
Mon Aug 2 11:46:11 MSD 2010


Hi, folks!

I've just pushed a new release (v0.20) for my ngx_chunkin module:

    http://github.com/agentzh/chunkin-nginx-module/tarball/v0.20

Here's the changes included in this version:

    *  fixed a bug that may read incomplete chunked body. thanks Gong
Kaihui (龚开晖).
    * fixed various memory issues in the implementation which may
cause nginx processes to crash.
    * added support for chunked POST requests.
    * now we always require "error_page 411 @resume" and no default
(buggy) magic any more. thanks Gong Kaihui (龚开晖).

This module adds HTTP 1.1 chunked input support for Nginx without the
need of patching the Nginx core.

Behind the scene, it registers an access-phase handler that will
eagerly read and decode incoming request bodies when a
Transfer-Encoding: chunked header triggers a 411 error page in Nginx.
For requests that are not in the chunked transfer encoding, this
module is a "no-op".

To enable the magic, just turn on the chunkin config option and define
a custom 411 error_page using chunkin_resume, like this:

  server {
    chunkin on;

    error_page 411 = @my_411_error;
    location @my_411_error {
        chunkin_resume;
    }

    ...
  }

See its wiki page for the full documentation:

    http://wiki.nginx.org/NginxHttpChunkinModule

Note that nginx 0.8.41 and 0.7.67 are confirmed to work with this
version. Nginx releases newer than 0.8.41 will NOT work due to this
issue:

    http://forum.nginx.org/read.php?29,103078

(There has not been any replies from the nginx author.)

Cheers,
-agentzh



More information about the nginx mailing list