3 from BeautifulSoup import BeautifulSoup
9 pattern = re.compile("^f.fb2.*")
10 os.environ['http_proxy']='http://192.168.1.100:3128'
11 os.environ['no_proxy']='localhost,127.0.0.1'
12 proxies = {'http': 'http://localhost:3128'}
15 for host in ['flibustahezeous3.onion','flibusta.i2p','flibusta.net']:
18 print "Trying %s" % (host)
19 html_page = urllib.urlopen("http://%s/daily/" % (host))
20 html = BeautifulSoup(html_page)
22 os_command = "wget -c -q -P \"%s\" http://%s/daily/%s" % (db.upload_files,host,'%s')
26 for link in html.findAll('a'):
27 file = link.get("href")
29 if pattern.match(file):
31 if not db.TestArchive(file):
32 print "Processing %s" % file
33 if os.system(os_command % file) == 0:
43 print "Got from %s" % host