remove hardcoded tor hosts
use user config + minor reorg.
This commit is contained in:
7
ppf.py
7
ppf.py
@@ -26,13 +26,8 @@ base_header = {
|
||||
'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; rv:60.0) Gecko/20100101 Firefox/60.0'
|
||||
}
|
||||
|
||||
database = 'proxies.sqlite'
|
||||
|
||||
searx_instances = ('https://searx.me', 'https://searx.xyz', 'https://searx.site', 'https://searx.win', 'https://searx.ru', 'https://stemy.me/searx', 'https://searx.at', 'https://listi.me', 'https://searx.dk', 'https://searx.laquadrature.net' )
|
||||
|
||||
retry_messages = ('Engines cannot retrieve results', 'Rate limit exceeded')
|
||||
proxies={'http':'socks5://127.0.0.1:9050','https':'socks5://127.0.0.1:9050'}
|
||||
|
||||
CONFIG = 'config.ini'
|
||||
|
||||
def cleanhtml(raw_html):
|
||||
@@ -160,6 +155,8 @@ if __name__ == '__main__':
|
||||
|
||||
database = parser.get('global', 'database')
|
||||
search = parser.getboolean('proxyfind', 'search')
|
||||
tor_hosts = parser.get('global', 'tor_host').split(',')
|
||||
proxies={'http':'socks5://%s' % random.choice(tor_hosts),'https':'socks5://%s' % random.choice(tor_hosts)}
|
||||
|
||||
sqlite = mysqlite.mysqlite(database, str)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user