Esempio n. 1
0
def brute_force(cpv, url):
    results = generic.brute_force(cpv, url)

    if url.startswith('mirror://kde/unstable/'):
        url = url.replace('mirror://kde/unstable/', 'mirror://kde/stable/')
        results += generic.brute_force(cpv, url)

    return clean_results(results)
Esempio n. 2
0
def scan_url(pkg, url, options):
    results = generic.scan(pkg.cpv, url)

    if generic.startswith('mirror://kde/unstable/'):
        url = generic.replace('mirror://kde/unstable/', 'mirror://kde/stable/')
        results += generic.scan(pkg.cpv, url)

    if not results:  # if nothing was found go brute forcing
        results = generic.brute_force(pkg.cpv, url)

        if generic.startswith('mirror://kde/unstable/'):
            url = generic.replace('mirror://kde/unstable/',
                                  'mirror://kde/stable/')
            results += generic.brute_force(pkg.cpv, url)

    return clean_results(results)