Skip to content

Commit

Permalink
Merge pull request #371 from projectdiscovery/add_br_decoding_support
Browse files Browse the repository at this point in the history
add br decoding support
  • Loading branch information
tarunKoyalwar authored Mar 22, 2024
2 parents 909ad7b + 9a71586 commit 0ae70b4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions http/normalization.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"net/http"
"strings"

"github.com/andybalholm/brotli"
"github.com/pkg/errors"
"golang.org/x/text/encoding/simplifiedchinese"
"golang.org/x/text/transform"
Expand Down Expand Up @@ -68,6 +69,8 @@ func wrapDecodeReader(resp *http.Response) (rc io.ReadCloser, err error) {
rc, err = gzip.NewReader(resp.Body)
case "deflate":
rc, err = zlib.NewReader(resp.Body)
case "br":
rc = io.NopCloser(brotli.NewReader(resp.Body))
default:
rc = resp.Body
}
Expand Down

0 comments on commit 0ae70b4

Please sign in to comment.