Explorar o código

support non-preemptive authentication (#1888)

fzhyzamt %!s(int64=4) %!d(string=hai) anos
pai
achega
b1181fd17a
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      models/plugin/client/http_proxy.go

+ 1 - 0
models/plugin/client/http_proxy.go

@@ -231,6 +231,7 @@ func removeProxyHeaders(req *http.Request) {
 func getBadResponse() *http.Response {
 	header := make(map[string][]string)
 	header["Proxy-Authenticate"] = []string{"Basic"}
+	header["Connection"] = []string{"close"}
 	res := &http.Response{
 		Status:     "407 Not authorized",
 		StatusCode: 407,