Documentation
¶
Index ¶
- Variables
- func CheckMaxPages(config *BaseSearchConfiguration) bool
- func CheckMaxSubdomains(config *BaseSearchConfiguration) bool
- func CreateDirIfNotExist(dir string)
- func GetHTTPCookieResponse(urls string, cookies []*http.Cookie, timeout int) (resp *http.Response, cookie []*http.Cookie, err error)
- func GetHTTPResponse(url string, timeout int) (resp *http.Response, err error)
- func GetHomeDir() string
- func InitializeWildcardDNS(state *State) bool
- func NewUUID() (string, error)
- func Unique(elements []string) []string
- func Validate(state *State, strslice []string) (subdomains []string)
- type BaseSearchConfiguration
- type BruteforceResult
- type Config
- type Result
- type Setting
- type State
- type StringSet
Constants ¶
This section is empty.
Variables ¶
var ( Red = "\033[31;1;4m" // red color Cyan = "\033[36;6;2m" // cyan color Green = "\033[32;6;3m" // Green color Reset = "\033[0m" // reset for default color Info = "\033[33;1;1m" Que = "\033[34;1;1m" Bad = "\033[31;1;1m" Good = "\033[32;1;1m" Run = "\033[97;1;1m" )
Use like this
fmt.Printf("[%sCRTSH%s] %s", r, rs, subdomain)
Functions ¶
func CheckMaxPages ¶
func CheckMaxPages(config *BaseSearchConfiguration) bool
CheckMaxPages checks if maximum number of pages per service was found.
func CheckMaxSubdomains ¶
func CheckMaxSubdomains(config *BaseSearchConfiguration) bool
CheckMaxSubdomains checks if maximum number of domains was found.
func CreateDirIfNotExist ¶
func CreateDirIfNotExist(dir string)
Create config directory if it does not exists
func GetHTTPCookieResponse ¶
func GetHTTPCookieResponse(urls string, cookies []*http.Cookie, timeout int) (resp *http.Response, cookie []*http.Cookie, err error)
GetHTTPResponse : Returns a HTTP Response object It needs URL To Visit and a cookie array to send with request. Note, It needs full url with scheme and a timeout value. It returns a HTTP Response object with a cookie array.
func GetHTTPResponse ¶
GetHTTPResponse : Returns a HTTP Response object It needs URL To Visit. Note, It needs full url with scheme and a timeout value. It returns a HTTP Response object
func InitializeWildcardDNS ¶
Method to eliminate Wildcard Is based on OJ Reeves Work on Gobuster Project github.com/oj/gobuster :-)
func NewUUID ¶
NewUUID generates a random UUID according to RFC 4122 Taken from : https://play.golang.org/p/4FkNSiUDMg
Used for bruteforcing and detection of Wildcard Subdomains :-)
func Unique ¶
Returns unique items in a slice Adapted from http://www.golangprograms.com/remove-duplicate-values-from-slice.html
Types ¶
type BaseSearchConfiguration ¶
type BaseSearchConfiguration struct {
MaxDomains int // Max subdomains per page
MaxPages int // Max pages we should query
CurrentPageNo int // Current page we are checking
CurrentRetries int // Retries we have already made
PrevLinksFound []string // Links we have previously found
CurrentSubdomains []string // Subdomains we have already found on a page
AllSubdomains []string // All Subdomains found so far
}
Configuration Structure which contains configuration for each search engine.
type BruteforceResult ¶
Current Bruteforce structure
type Config ¶
type Config struct {
VirustotalAPIKey string `json:"virustotalApikey"` // Virustotal API Key
PassivetotalUsername string `json:"passivetotalUsername"` // PassiveTotal Username (Email Address)
PassivetotalKey string `json:"passivetotalKey"` // PassiveTotal api key
SecurityTrailsKey string `json:"securitytrailsKey"` // SecurityTrails api key
RiddlerEmail string `json:"riddlerEmail"` // Riddler Email
RiddlerPassword string `json:"riddlerPassword"` // Riddler Password
CensysUsername string `json:"censysUsername"` // Censys Username
CensysSecret string `json:"censysSecret"` // Censys API Key
}
func ReadConfigFile ¶
Reads a config file from disk and returns Configuration structure If not exists, create one and then return
type Result ¶
type Result struct {
Subdomains []string // Subdomains found
Error error // Any error that has occured
}
Current result structure
type Setting ¶
type Setting struct {
CensysPages string // Censys pages to check. For All, use "all"
}
func InitializeSettings ¶
func InitializeSettings() (setting *Setting)
type State ¶
type State struct {
Color bool // Whether to use color or not
Threads int // Number of threads to use
Timeout int // Timeout for requests to different passive sources
Verbose bool // Show verbose information
Domain string // Domain name to find subdomains for
Recursive bool // Whether perform recursive subdomain discovery or not
Output string // Name of output file
Alive bool // Get only alive subdomains (x - no wildcards :-))
IsJSON bool // Provide JSON output file
Wordlist string // Wordlist file for subdomains bruteforcing
Bruteforce bool // Flag to decide whether to bruteforce or not
WildcardIPs StringSet // Wildcard IP Structure
IsWildcard bool // Does the host has wildcard subdomains, if yes parse them carefully
WildcardForced bool // Force processing of wildcard DNS Responses
Sources string // Comma separated list of sources to use
Silent bool // Show only silent output or not
FinalResults []string // Contains final bruteforcing results
SetConfig string // Used for changing the current configuration file details
SetSetting string // Used for passing custom configuration to the application
CurrentSettings Setting // Current application settings
ConfigState Config // Current configuration file state
}
Holds the State read in from the CLI