Skip to content

Why are the md5 values ​​the same? when using httpx as sdk. #1685

Answered by r00tuser111
r00tuser111 asked this question in Q&A
Discussion options

You must be logged in to vote

After some source code analysis, I found that there is a configuration item named: h.Options.MaxResponseBodySizeToRead in httpx/common/httpx/httpx.go.

if !generic.EqualsAny(httpresp.StatusCode, http.StatusSwitchingProtocols, http.StatusNotModified) {
var err error
respbody, err = io.ReadAll(io.LimitReader(httpresp.Body, h.Options.MaxResponseBodySizeToRead))
if err != nil && !shouldIgnoreBodyErrors {
return nil, err
}
}

Set MaxResponseBodySizeToRead: 2147483647,

The configuration item corresponding to cli should be

-rstr, -response-size-to-read int max response size to read in bytes (default 2147483647)

Now this problem is solved.

https://www.example.com:9981 9981 1.1.1.1 map[body_md5:d4…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by r00tuser111
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant