paivana

HTTP paywall reverse proxy
Log | Files | Refs | Submodules | README | LICENSE

NEWS (2540B)


      1 Unreleased:
      2   - The reverse proxy streams both directions.  A request or response
      3     body is relayed as it arrives instead of being assembled in memory
      4     first, so its size is no longer bounded by memory -- previously
      5     anything over 40 MiB was refused outright with 502, and the client
      6     could not receive a single byte until the origin had sent the last
      7     one.  The origin's framing now reaches the client unchanged as
      8     well: a declared Content-Length stays declared and a chunked
      9     response stays chunked, where before both were recomputed from the
     10     assembled buffer.  A HEAD accordingly reports the length the
     11     equivalent GET would have had, rather than 0.
     12 
     13   - Configuration: REQUEST_BUFFER_MAX (and its -u/--max-upload flag)
     14     now sizes the buffer a request body is relayed through, 256 KiB by
     15     default, and no longer decides how large an upload may be.  That is
     16     MAX_REQUEST_SIZE, new, 1 MiB by default.  RESPONSE_BUFFER_MAX is
     17     the mirror of the first; there is deliberately no mirror of the
     18     second, since removing the limit on a response is the point of the
     19     change.
     20 
     21     UPGRADING: a configuration that set REQUEST_BUFFER_MAX (or -u) to
     22     permit large uploads meant the limit, so where it is set and
     23     MAX_REQUEST_SIZE is not, MAX_REQUEST_SIZE takes its value.  Such a
     24     configuration therefore keeps behaving as it did, at the cost of a
     25     correspondingly large relay buffer; set both explicitly to separate
     26     them.
     27 
     28   - Timeouts: UPSTREAM_TIMEOUT (60 s) now bounds the time to the
     29     response *headers* rather than to the whole transfer, since a large
     30     download legitimately runs for longer than any useful ceiling.  A
     31     stalled transfer is bounded instead by the new
     32     UPSTREAM_STALL_TIMEOUT (60 s), which is how long the origin may
     33     move no bytes in either direction, and which does not run while
     34     paivana is holding the origin back because the client has not
     35     caught up.
     36 
     37   - An origin that fails after its response headers have gone out can
     38     no longer be reported as 502: the status is already on the wire.
     39     It is reported as a framing error instead -- a declared
     40     Content-Length that is not met, or a chunked response closed
     41     without its terminating chunk -- which RFC 9112 section 8.1.2
     42     requires a client to treat as a failure.  The exception is an
     43     HTTP/1.0 client receiving a response of unknown length, where the
     44     close is the framing and truncation cannot be signalled.
     45 
     46   - Requires GNUnet 0.29.0 for GNUNET_CURL_job_add_stream().