improved raw requests same header handling

dev
Mzack9999 2020-11-24 21:06:13 +01:00
parent e5d4c7a6d0
commit 1f6b83f312
1 changed files with 8 additions and 1 deletions

View File

@ -400,7 +400,14 @@ func (r *BulkHTTPRequest) parseRawRequest(request, baseURL string) (*RawRequest,
value = p[1]
}
rawRequest.Headers[key] = value
// in case of unsafe requests multiple headers should be accepted
// therefore use the full line as key
_, found := rawRequest.Headers[key]
if r.Unsafe && found {
rawRequest.Headers[line] = ""
} else {
rawRequest.Headers[key] = value
}
}
// Handle case with the full http url in path. In that case,