예제 #1
0
def scrape_links(link,
                 browser_args,
                 job_name,
                 out_name,
                 depth,
                 include_external,
                 match,
                 past=None):
    if not past:
        past = BloomFilter(capacity=3 * 10**(depth + 3), error_rate=0.001)

    out = base_link_scraper(link, browser_args, past, include_external)
    if not out:
        return
    if depth:
        args = (browser_args, job_name, out_name, depth - 1, include_external,
                match)
        kwargs = {'past': past}
        group(
            scrape_links.subtask((url, ) + args, kwargs, **
                                 scrape_links.request.delivery_info)
            for url in out)()

    if match:
        out = [url for url in out if any(x in url for x in match)]

    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #2
0
def sqli_dump(num, browser_args, job_name, out_name, url, ident, left, right, attempts):
	out = base_sqli_dump(num, browser_args, url, ident, left, right, attempts)
	if type(out) == str:
		celery_output.delay(out, name, job_name, out_name)
		return

	if attempts - 1:
		base_sqli_dump.delay(num, browser_args, job_name, out_name, url, ident, left, right, attempts - 1)
예제 #3
0
파일: scan_wp.py 프로젝트: gzzo/arachne
def scan_wp(url, browser_args, job_name, out_name, first=True):
	out = base_scan_wp(url, browser_args)
	if out:
		celery_output.delay(out, name, job_name, out_name)
	elif first:
		args = (browser_args, job_name, out_name)
		kwargs = {'first' : False}
		group(scan_wp.subtask( (link,) + args, kwargs, 
			**scan_wp.request.delivery_info) for link in base_find_wp(url))()
예제 #4
0
def check_keyword(link,
                  browser_args,
                  job_name,
                  out_name,
                  keywords,
                  check_url=False):
    out = base_check_keyword(link, browser_args, keywords, check_url)
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #5
0
def sqli_dump(num, browser_args, job_name, out_name, url, ident, left, right,
              attempts):
    out = base_sqli_dump(num, browser_args, url, ident, left, right, attempts)
    if type(out) == str:
        celery_output.delay(out, name, job_name, out_name)
        return

    if attempts - 1:
        base_sqli_dump.delay(num, browser_args, job_name, out_name, url, ident,
                             left, right, attempts - 1)
예제 #6
0
파일: scan_wp.py 프로젝트: yoCruzer/arachne
def scan_wp(url, browser_args, job_name, out_name, first=True):
    out = base_scan_wp(url, browser_args)
    if out:
        celery_output.delay(out, name, job_name, out_name)
    elif first:
        args = (browser_args, job_name, out_name)
        kwargs = {'first': False}
        group(
            scan_wp.subtask((link, ) +
                            args, kwargs, **scan_wp.request.delivery_info)
            for link in base_find_wp(url))()
예제 #7
0
def wp_init(url, browser_args, job_name, out_name):
    params = base_wp_init(url, browser_args)

    b = Browser(name, **browser_args)
    r = b.go(url, data=params)

    if WP_GDKEY in r.text:
        celery_output.delay(out_format(out, params), name, job_name, out_name)
    elif WP_BUSER in r.text:
        wp_user.delay(url, browser_args, job_name, out_name, params)
    else:
        wp_brute.delay(url, browser_args, job_name, out_name, params, 1)
예제 #8
0
def wp_init(url, browser_args, job_name, out_name):
    params = base_wp_init(url, browser_args)

    b = Browser(name, **browser_args)
    r = b.go(url, data=params)

    if WP_GDKEY in r.text:
        celery_output.delay(out_format(out, params), name, job_name, out_name)      
    elif WP_BUSER in r.text:
        wp_user.delay(url, browser_args, job_name, out_name, params)
    else:
        wp_brute.delay(url, browser_args, job_name, out_name, params, 1)
예제 #9
0
def wp_brute(url, browser_args, job_name, out_name, params, pnum=0):
    if pnum:
        params['pwd'] = wp_brute.plist[pnum-1]

    out = base_wp_brute(url, browser_args, params)
    if out:
        return celery_output.delay(out_format(out, params), name, job_name, out_name)
    
    if pnum <= wp_brute.plen:
        wp_brute.delay(url, browser_args, job_name, out_name, params, pnum+1)
예제 #10
0
def wp_brute(url, browser_args, job_name, out_name, params, pnum=0):
    if pnum:
        params['pwd'] = wp_brute.plist[pnum - 1]

    out = base_wp_brute(url, browser_args, params)
    if out:
        return celery_output.delay(out_format(out, params), name, job_name,
                                   out_name)

    if pnum <= wp_brute.plen:
        wp_brute.delay(url, browser_args, job_name, out_name, params, pnum + 1)
예제 #11
0
def scan_dom(url, browser_args, job_name, out_name):
    matches = base_scan_dom(url, browser_args)
    if matches:
        output = url + ' ||| {}'
        celery_output.delay(output.format(matches), name, job_name, out_name)
예제 #12
0
파일: scan_sqli.py 프로젝트: gzzo/arachne
def scan_sqli(url, browser_args, job_name, out_name):
	out = base_sqli_scan(url, browser_args)
	if out:
		celery_output.delay(out, name, job_name, out_name)
예제 #13
0
def exploit_wp_leaguemanager(url, browser_args, job_name, out_name):
    out = base_wp_leaguemanager(url, browser_args)
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #14
0
def scrape_headers(link, browser_args, job_name, out_name, match):
    out = base_scrape_headers(link, browser_args, match)
    if out:
        celery_output.delay(dumps([link, out], indent=4), name, job_name, out_name)
예제 #15
0
def exploit_wp_leaguemanager(url, browser_args, job_name, out_name):
    out = base_wp_leaguemanager(url, browser_args)
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #16
0
def check_keyword(link, browser_args, job_name, out_name, keywords, check_url=False):
	out = base_check_keyword(link, browser_args, keywords, check_url)
	if out:
		celery_output.delay(out, name, job_name, out_name)
예제 #17
0
def check_proxy(proxy, browser_args, job_name, out_name, target_site, target_key):
	out = base_check_proxy(proxy, browser_args, target_site, target_key)
	if out:
		celery_output.delay(out, name, job_name, out_name)
예제 #18
0
def test_rlfi(link, browser_args, job_name, out_name, key):
    out = base_check_keyword(link, browser_args, [key, 'No such file'])
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #19
0
def scan_sqli(url, browser_args, job_name, out_name):
    out = base_sqli_scan(url, browser_args)
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #20
0
파일: scan_xss.py 프로젝트: gzzo/arachne
def scan_dom(url, browser_args, job_name, out_name):
	matches = base_scan_dom(url, browser_args)
	if matches:
		output = url + ' ||| {}'
		celery_output.delay(output.format(matches), name, job_name, out_name)
예제 #21
0
def scrape_proxy(link, browser_args, job_name, out_name):
    out = base_scrape_proxy(link, browser_args)
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #22
0
파일: scan_xss.py 프로젝트: gzzo/arachne
def test_xss(url, browser_args, job_name, out_name):
	out = base_check_keyword(url, browser_args, ['<SSX>'])
	if out:
		output = url + ' ||| {}'
		celery_output.delay(output.format(out), name, job_name, out_name)
예제 #23
0
def test_xss(url, browser_args, job_name, out_name):
    out = base_check_keyword(url, browser_args, ['<SSX>'])
    if out:
        output = url + ' ||| {}'
        celery_output.delay(output.format(out), name, job_name, out_name)
예제 #24
0
def scrape_proxy(link, browser_args, job_name, out_name):
    out = base_scrape_proxy(link, browser_args)
    if out:
        celery_output.delay(out, name, job_name, out_name)
예제 #25
0
def scrape_headers(link, browser_args, job_name, out_name, match):
    out = base_scrape_headers(link, browser_args, match)
    if out:
        celery_output.delay(dumps([link, out], indent=4), name, job_name,
                            out_name)
예제 #26
0
파일: scan_rlfi.py 프로젝트: gzzo/arachne
def test_rlfi(link, browser_args, job_name, out_name, key):
	out = base_check_keyword(link, browser_args, [key, 'No such file'])
	if out:
		celery_output.delay(out, name, job_name, out_name)