diff --git a/src/shrpx_http2_upstream.cc b/src/shrpx_http2_upstream.cc index d73485c7..4c47ad8a 100644 --- a/src/shrpx_http2_upstream.cc +++ b/src/shrpx_http2_upstream.cc @@ -915,10 +915,13 @@ int Http2Upstream::on_downstream_header_complete(Downstream *downstream) nv[hdidx++] = response_status.c_str(); for(Headers::const_iterator i = downstream->get_response_headers().begin(); i != downstream->get_response_headers().end(); ++i) { - if(util::strieq((*i).first.c_str(), "transfer-encoding") || - util::strieq((*i).first.c_str(), "keep-alive") || // HTTP/1.0? - util::strieq((*i).first.c_str(), "connection") || - util:: strieq((*i).first.c_str(), "proxy-connection")) { + if(util::strieq((*i).first.c_str(), "connection") || + util::strieq((*i).first.c_str(), "host") || + util::strieq((*i).first.c_str(), "keep-alive") || + util::strieq((*i).first.c_str(), "proxy-connection") || + util::strieq((*i).first.c_str(), "te") || + util::strieq((*i).first.c_str(), "transfer-encoding") || + util::strieq((*i).first.c_str(), "upgrade")) { // These are ignored } else if(!get_config()->no_via && util::strieq((*i).first.c_str(), "via")) { diff --git a/src/shrpx_spdy_downstream_connection.cc b/src/shrpx_spdy_downstream_connection.cc index 83c589b4..6f6f47cb 100644 --- a/src/shrpx_spdy_downstream_connection.cc +++ b/src/shrpx_spdy_downstream_connection.cc @@ -290,16 +290,12 @@ int SpdyDownstreamConnection::push_request_headers() } // Ignore transfer-encoding continue; - } else if(util::strieq((*i).first.c_str(), "upgrade")) { - // nghttpx handles HTTP/2.0 upgrade and does not relay it to the - // downstream. - if(util::strieq((*i).second.c_str(), NGHTTP2_PROTO_VERSION_ID)) { - continue; - } } else if(util::strieq((*i).first.c_str(), "x-forwarded-proto") || util::strieq((*i).first.c_str(), "keep-alive") || util::strieq((*i).first.c_str(), "connection") || util::strieq((*i).first.c_str(), "proxy-connection") || + util::strieq((*i).first.c_str(), "te") || + util::strieq((*i).first.c_str(), "upgrade") || util::strieq((*i).first.c_str(), "http2-settings")) { // These are ignored continue;