Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Additional error check on hybrid request parsing #804

Merged
merged 1 commit into from
Mar 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion pkg/engine/hybrid/crawl.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ func (c *Crawler) navigateRequest(s *common.CrawlSession, request *navigation.Re
} else {
statucCodeText = http.StatusText(statusCode)
}
httpreq, _ := http.NewRequest(e.Request.Method, URL.String(), strings.NewReader(e.Request.PostData))
httpreq, err := http.NewRequest(e.Request.Method, URL.String(), strings.NewReader(e.Request.PostData))
if err != nil {
return errorutil.NewWithTag("hybrid", "could not new request").Wrap(err)
}
// Note: headers are originally sent using `c.addHeadersToPage` below changes are done so that
// headers are reflected in request dump
if httpreq != nil {
Expand Down
Loading