From c7118a2078b846d1e4c044930a1025a54bfd66f2 Mon Sep 17 00:00:00 2001 From: icytrues <32688916+icytrues@users.noreply.github.com> Date: Wed, 16 Oct 2019 23:34:06 +0200 Subject: [PATCH] Fixing the "net/url: invalid control character in URL" error on waybackarchive Running string() on an integer returns an empty string, changing to strconv.Itoa() instead. --- libsubfinder/sources/waybackarchive/waybackarchive.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libsubfinder/sources/waybackarchive/waybackarchive.go b/libsubfinder/sources/waybackarchive/waybackarchive.go index a74625e..1ffe045 100644 --- a/libsubfinder/sources/waybackarchive/waybackarchive.go +++ b/libsubfinder/sources/waybackarchive/waybackarchive.go @@ -51,7 +51,7 @@ func Query(args ...interface{}) interface{} { } for i := 0; i <= numPages; i++ { - resp, err := helper.GetHTTPResponse("http://web.archive.org/cdx/search/cdx?url=*."+domain+"/*&output=json&fl=original&collapse=urlkey&page="+string(i), state.Timeout) + resp, err := helper.GetHTTPResponse("http://web.archive.org/cdx/search/cdx?url=*."+domain+"/*&output=json&fl=original&collapse=urlkey&page="+strconv.Itoa(i), state.Timeout) if err != nil { if !state.Silent { fmt.Printf("\nwaybackarchive: %v\n", err)