Documentation ¶
Index ¶
- func Banner() string
- func Check403(url, word string, client *http.Client, user_agent string) ([]string, []int, error)
- func CheckRedirect(url string, client *http.Client, payloads []string, keyword string) ([]string, error)
- func CreateHttpClient(timeout int) *http.Client
- func CreateHttpClientFollowRedirects(timeout int) *http.Client
- func DefaultHttpClient() *http.Client
- func DetectWaf(url string, payload string, keyword string, client *http.Client) (string, error)
- func FetchEndpoints(urls <-chan string, results chan string, client *http.Client) error
- func FilterUrls(urls []string, filters []string) []string
- func FindSecrets(url string, client *http.Client) ([]string, error)
- func GetAllPerms() []string
- func GetAllUrls(domain string, results chan string, client *http.Client, recursive bool) error
- func GetCommonPayloads() []string
- func GetEndpoints(urls []string, results chan string, workers int, client *http.Client) error
- func GetPayloads() []string
- func GetPerms(level int) []string
- func GetSubdomains(dom string, results chan string, providers []string, client *http.Client) error
- func GetTech(url string, client *http.Client) (map[string]struct{}, error)
- func Green(str string, c bool)
- func Magenta(str string, c bool)
- func Red(str string, c bool)
- func StartTimer() time.Time
- func TimerDiff(t1 time.Time) time.Duration
- func Version() string
- func Warning(str string, c bool)
- func Whois(domain string) (wp.WhoisInfo, error)
- type DnsInfo
- type MX
- type NS
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Check403 ¶
try different ways to bypass 403 status code urls returns slice of urls with payloads on them, a slice with their respective status codes, and finally an error
func CheckRedirect ¶
func CheckRedirect(url string, client *http.Client, payloads []string, keyword string) ([]string, error)
this function checks if given url is vulnerable to open redirect with provided payloads if keyword has value, it will be replaced with payloads Example: vuln_urls, err := CheckRedirect("http://example.com/index.php?p=FUZZ", client, []string{"bing.com", "//bing.com"}, "FUZZ")
func CreateHttpClient ¶
create an http client with given timeout (in milliseconds), skip tls verify and some other useful settings don't follow redirects Example: client := CreateHttpClient(5000)
func CreateHttpClientFollowRedirects ¶
this functions does the same as CreateHttpClient() but this one follows redirects
func DefaultHttpClient ¶
function which aids users if they want to use a default client instance instead of creating a new one
func DetectWaf ¶
this function send a request to url with an LFI payload to try to trigger the possible WAF (Web Application Firewall) i.e. Cloudflare Example: waf, err := gorecon.DetectWaf(url, "", "", gorecon.DefaultHttpClient())
func FetchEndpoints ¶
this function receives urls from channel so it's better for concurrency and configuration
func FilterUrls ¶
remove useless urls, duplicates and more to optimize results as much as possible from a list of urls Example: new_urls := gorecon.FilterUrls(urls, []string{"hasparams"})
func FindSecrets ¶
this function receives a url and a client to look for potential leaked secrets like API keys (using regex)
func GetAllPerms ¶
func GetAllPerms() []string
this function returns all defined permutations for S3 buckets name generation
func GetAllUrls ¶
main function to enumerate urls about provided domain, urls are sent through channel set "recursive" to false if you don't want to get urls related to subdomains
func GetEndpoints ¶
main function to extract JS endpoints from a list of urls it receives a custom client for further customization Example: go gorecon.GetEndpointsFromFile(urls, results, 15, gorecon.DefaultClient())
func GetPerms ¶
this function returns more or less permutations based on given level 1 returns less permutations than 6 (1 lower, 5 higher)
func GetSubdomains ¶
this function sents through provided channel all the gathered subdomains providers slice is used to configure the providers to use it also receives a client so you can custom most of the process Example: err := GetSubdomains("example.com", results, []string{"alienvault", "crt", "rapiddns", "wayback"}, gorecon.DefaultClient())
func GetTech ¶
this function send a request to given url and returns running technologies Example: techs, err := GetTech("http://github.com", gorecon.DefaultClient())
func StartTimer ¶
return current time for later chaining with TimerDiff() to get elapsed time
Types ¶
type DnsInfo ¶
type DnsInfo struct { Domain string `json:"domain"` // given domain CNAME string `json:"cname"` // returns the canonical name for the given host TXT []string `json:"txt"` // returns the DNS TXT records for the given domain name MX []MX `json:"mx"` // returns a slice of MX (Mail eXchanges) NS []NS `json:"ns"` // returns a slice of NS (Name Server) Hosts []string `json:"hosts"` // returns a slice of given host's IPv4 and IPv6 addresses }
struct used by main function