Pontential fix for nuclei stuck issue
@@ -348,6 +348,10 @@ func (r *Request) executeRequest(reqURL string, request *generatedRequest, previ
}
return err
}
+ // If the status code is HTTP 101, we should not proceed with reading body.
+ if resp != nil && resp.StatusCode == http.StatusSwitchingProtocols {
+ return nil
+ }
defer func() {
_, _ = io.CopyN(ioutil.Discard, resp.Body, drainReqSize)
resp.Body.Close()
