Skip to content

Commit 5c49445

Browse files
committed
Ignore old padding format of "..."
1 parent 3182958 commit 5c49445

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

forwardproxy.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,9 @@ func (h *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyht
302302
return serveHijack(w, targetConn)
303303
case 2: // http2: keep reading from "request" and writing into same response
304304
defer r.Body.Close()
305-
return dualStream(targetConn, r.Body, w, r.Header.Get("Padding") != "")
305+
padding := r.Header.Get("Padding")
306+
// Ignores old client padding of "..."
307+
return dualStream(targetConn, r.Body, w, padding != "" && padding[0] != '.')
306308
}
307309

308310
panic("There was a check for http version, yet it's incorrect")

0 commit comments

Comments
 (0)