Commit b3734e7b authored by Stan Hu's avatar Stan Hu

Upgrade rack-proxy to v0.7.2

This fixes a bug that manifested with the `webpack-dev-server` and the
`thin` Web server.

When a chunked transfer is proxied from rack-proxy, the proxied HTTP
response would contain the original `Transfer-Encoding: chunked` HTTP
header. However, the body would be stripped of the chunked encoding
headers. As a result, Workhorse would fail to parse the body with the
error:

```
httputil: ReverseProxy read error during body copy: invalid byte in
chunk length
```

This occurred because the Golang chunked decoder expected to parse a
length represented as an ASCII number followed by a `\r\n`. Instead,
the first byte was a binary character from the gzipped data.

This does not occur with Puma because Puma initiates a request with an
HTTP/1.0 header and explicitly disables chunked transfers.

https://github.com/ncr/rack-proxy/pull/59 fixes this problem by
dropping the `Transfer-Encoding: chunked` header so that Workhorse
won't handle the HTTP response as a chunked transfer.

See https://gitlab.com/gitlab-org/gitlab-development-kit/-/issues/1443
for more details.

Changelog: fixed
parent 37230728
......@@ -285,7 +285,7 @@ gem 'fast_blank'
gem 'gitlab-chronic', '~> 0.10.5'
gem 'gitlab_chronic_duration', '~> 0.10.6.2'
gem 'rack-proxy', '~> 0.6.0'
gem 'rack-proxy', '~> 0.7.2'
gem 'sassc-rails', '~> 2.1.0'
gem 'autoprefixer-rails', '10.2.5.1'
......
......@@ -968,7 +968,7 @@ GEM
httpclient
json-jwt (>= 1.11.0)
rack (>= 2.1.0)
rack-proxy (0.6.0)
rack-proxy (0.7.2)
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
......@@ -1605,7 +1605,7 @@ DEPENDENCIES
rack-attack (~> 6.3.0)
rack-cors (~> 1.0.6)
rack-oauth2 (~> 1.16.0)
rack-proxy (~> 0.6.0)
rack-proxy (~> 0.7.2)
rack-timeout (~> 0.5.1)
rails (~> 6.1.4.6)
rails-controller-testing
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment