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

Feature request - not showing "non 200 response code has been found" by passing an arg #3

Open
w9w opened this issue Jul 13, 2020 · 0 comments

Comments

@w9w
Copy link

w9w commented Jul 13, 2020

Hi @random-robbie @tomnomnom, I'd like to suggest a feature, - not showing "non 200 response has been found" by passing an arg.

If this is one parameter/URL - it's ok. But when you need to feed URLs to the script thousands of times in automated pipeline and looking at the output in the console in a real-time, - it's a pain for eyes🤯

I've added a quick fix for myself

if resp.StatusCode != http.StatusOK {
fmt.Printf("non-200 response code: %s (%s)\n", u, resp.Status)
}

                            if resp.StatusCode == http.StatusOK {
                                    fmt.Printf("200 response code found, checking...\n")
                                    buf := new(bytes.Buffer)
                                    buf.ReadFrom(resp.Body)
                                    newStr := buf.String()
                                    if strings.Contains(newStr , "k6unx4pudf8k5itoapaxjwzjigz") == true {
                                            color.HiGreen("A string has been found in the response! Details: %s (%s)\n", u, resp.Status)
                                            f, err := os.OpenFile("ssrf.log",
                                                    os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0644)

What I'm suggesting is adding an arg and if it's been passed - not showing print("non-200 response code\n") for a user.

Thank you and have a nice day, Max (@ w2w).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant