str(conf.directories_only)) textutils.output_info('Starting Discovery on ' + conf.target_host) if conf.use_tor: textutils.output_info('Using Tor, be patient it WILL be slow!') textutils.output_info( 'Max timeout count and url fetch timeout doubled for the occasion ;)' ) conf.max_timeout_count *= 2 conf.fetch_timeout_secs *= 2 # Handle keyboard exit before multi-thread operations try: # Resolve target host to avoid multiple dns lookups resolved, port = dnscache.get_host_ip(parsed_host, parsed_port) # Benchmark target host if is_ssl: database.connection_pool = HTTPSConnectionPool( resolved, port=str(port), timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count) else: database.connection_pool = HTTPConnectionPool( resolved, port=str(port), timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count)
textutils.output_debug('Using User-Agent: ' + str(conf.user_agent)) textutils.output_debug('Search only for files: ' + str(conf.files_only)) textutils.output_debug('Search only for subdirs: ' + str(conf.directories_only)) textutils.output_info('Starting Discovery on ' + conf.target_host) if conf.use_tor: textutils.output_info('Using Tor, be patient it WILL be slow!') textutils.output_info('Max timeout count and url fetch timeout doubled for the occasion ;)') conf.max_timeout_count *= 2 conf.fetch_timeout_secs *= 2 # Handle keyboard exit before multi-thread operations try: # Resolve target host to avoid multiple dns lookups resolved, port = dnscache.get_host_ip(parsed_host, parsed_port) # Benchmark target host if is_ssl: database.connection_pool = HTTPSConnectionPool(resolved, timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count) else: database.connection_pool = HTTPConnectionPool(resolved, timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count) # Vhost forgery if conf.forge_vhost != '<host>': conf.target_host = conf.forge_vhost root_path = '' if conf.files_only: # 0. Sample /uuid to figure out what is a classic 404 and set value in database sample_root_404()
textutils.output_debug('Using proxy: ' + str(conf.proxy_url)) textutils.output_info('Starting Discovery on ' + conf.target_host) if conf.use_tor: textutils.output_info('Using Tor, be patient it WILL be slow!') textutils.output_info('Max timeout count and url fetch timeout doubled for the occasion ;)') conf.max_timeout_count *= 2 conf.fetch_timeout_secs *= 2 # Handle keyboard exit before multi-thread operations print_results_worker = None try: # Resolve target host to avoid multiple dns lookups if not conf.proxy_url: resolved, port = dnscache.get_host_ip(conf.target_host, conf.target_port) # disable urllib'3 SSL warning (globally) urllib3.disable_warnings() # Benchmark target host if conf.proxy_url: database.connection_pool = ProxyManager(conf.proxy_url, timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count, cert_reqs='CERT_NONE') elif not conf.proxy_url and is_ssl: database.connection_pool = HTTPSConnectionPool(resolved, port=str(port), timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count) else: database.connection_pool = HTTPConnectionPool(resolved, port=str(port), timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count) # Vhost forgery if conf.forge_vhost != '<host>':
textutils.output_info('Starting Discovery on ' + conf.target_host) if conf.use_tor: textutils.output_info('Using Tor, be patient it WILL be slow!') textutils.output_info( 'Max timeout count and url fetch timeout doubled for the occasion ;)' ) conf.max_timeout_count *= 2 conf.fetch_timeout_secs *= 2 # Handle keyboard exit before multi-thread operations print_results_worker = None try: # Resolve target host to avoid multiple dns lookups if not conf.proxy_url: resolved, port = dnscache.get_host_ip(conf.target_host, conf.target_port) # disable urllib'3 SSL warning (globally) urllib3.disable_warnings() # Benchmark target host if conf.proxy_url: database.connection_pool = ProxyManager( conf.proxy_url, timeout=conf.fetch_timeout_secs, maxsize=conf.thread_count, cert_reqs='CERT_NONE') elif not conf.proxy_url and is_ssl: database.connection_pool = HTTPSConnectionPool( resolved, port=str(port),