From 34762b092ab66ea855e6ba7226ab34f92c8aa285 Mon Sep 17 00:00:00 2001 From: Gwyn <60668579+0xGwyn@users.noreply.github.com> Date: Tue, 15 Aug 2023 15:27:11 +0330 Subject: [PATCH] Update integration.go (#1319) Fixed minor mistakes in the comments --- internal/testutils/integration.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/internal/testutils/integration.go b/internal/testutils/integration.go index e5c23e4..2f5b3d0 100644 --- a/internal/testutils/integration.go +++ b/internal/testutils/integration.go @@ -7,7 +7,7 @@ import ( "strings" ) -// RunNucleiAndGetResults returns a list of results for a template +// RunHttpxAndGetResults returns a list of the results func RunHttpxAndGetResults(url string, debug bool, extra ...string) ([]string, error) { cmd := exec.Command("bash", "-c") cmdLine := `echo "` + url + `" | ./httpx ` @@ -35,7 +35,7 @@ func RunHttpxAndGetResults(url string, debug bool, extra ...string) ([]string, e return parts, nil } -// RunNucleiAndGetResults returns a list of results for a template +// RunHttpxAndGetCombinedResults returns the results as a single string variable func RunHttpxAndGetCombinedResults(url string, debug bool, extra ...string) (string, error) { cmd := exec.Command("bash", "-c") cmdLine := `echo "` + url + `" | ./httpx ` @@ -53,6 +53,8 @@ func RunHttpxAndGetCombinedResults(url string, debug bool, extra ...string) (str } return string(data), nil } + +// RunHttpxBinaryAndGetResults returns a list of the results func RunHttpxBinaryAndGetResults(target string, httpxBinary string, debug bool, args []string) ([]string, error) { cmd := exec.Command("bash", "-c") cmdLine := fmt.Sprintf(`echo %s | %s `, target, httpxBinary)