From e7a750564f424d3b3a2d1046b654593003ab5ad9 Mon Sep 17 00:00:00 2001 From: Alhaziel Date: Thu, 30 May 2019 16:31:45 +0200 Subject: [PATCH] Bypass CloudFlare --- channels/altadefinizioneclick.py | 2 +- channels/seriehd.py | 19 +- core/httptools.py | 12 +- core/support.py | 6 +- lib/cloudscraper/__init__.py | 311 +++++++++ lib/cloudscraper/interpreters/__init__.py | 89 +++ lib/cloudscraper/interpreters/chakracore.py | 95 +++ lib/cloudscraper/interpreters/js2py.py | 32 + lib/cloudscraper/interpreters/jsunfuck.py | 97 +++ lib/cloudscraper/interpreters/nodejs.py | 46 ++ lib/cloudscraper/interpreters/v8.py | 26 + lib/cloudscraper/user_agent/__init__.py | 40 ++ lib/cloudscraper/user_agent/browsers.json | 662 ++++++++++++++++++++ 13 files changed, 1419 insertions(+), 18 deletions(-) create mode 100644 lib/cloudscraper/__init__.py create mode 100644 lib/cloudscraper/interpreters/__init__.py create mode 100644 lib/cloudscraper/interpreters/chakracore.py create mode 100644 lib/cloudscraper/interpreters/js2py.py create mode 100644 lib/cloudscraper/interpreters/jsunfuck.py create mode 100644 lib/cloudscraper/interpreters/nodejs.py create mode 100644 lib/cloudscraper/interpreters/v8.py create mode 100644 lib/cloudscraper/user_agent/__init__.py create mode 100644 lib/cloudscraper/user_agent/browsers.json diff --git a/channels/altadefinizioneclick.py b/channels/altadefinizioneclick.py index b4f3858a..db5bbf70 100644 --- a/channels/altadefinizioneclick.py +++ b/channels/altadefinizioneclick.py @@ -10,7 +10,7 @@ from core.item import Item from platformcode import logger, config from specials import autoplay -host = "https://altadefinizione.center" ### <- cambio Host da .fm a .center +host = "https://alta-definizione.live" ### <- cambio Host da .fm a .center IDIOMAS = {'Italiano': 'IT'} list_language = IDIOMAS.values() diff --git a/channels/seriehd.py b/channels/seriehd.py index 5059cf5e..b072ca68 100644 --- a/channels/seriehd.py +++ b/channels/seriehd.py @@ -3,15 +3,17 @@ # Canale per seriehd # ------------------------------------------------------------ import urlparse +import re from channelselector import thumb +from lib import cloudscraper from core import scrapertoolsV2, servertools, httptools, support from core.item import Item from core.support import menu, log from platformcode import logger, config from specials import autoplay -host = "https://seriehd.casa" +host = "https://seriehd.info" IDIOMAS = {'Italiano': 'IT'} list_language = IDIOMAS.values() @@ -28,7 +30,7 @@ def mainlist(item): log() itemlist = [] - menu(itemlist, 'Serie TV', 'peliculas', host + '/serie-tv-streaming/', 'tvshow') + menu(itemlist, 'Serie TV', 'peliculas', host + '/serie-tv-streaming', 'tvshow') menu(itemlist, 'Per Genere submenu', 'genre', host, 'tvshow', 'TV') menu(itemlist, 'Per Nazione submenu', 'nation', host + '/serie-tv-streaming/', 'tvshow', 'TV') menu(itemlist, 'Cerca...', 'search', contentType='episode', args='TV') @@ -105,11 +107,10 @@ def episodios(item): data = httptools.downloadpage(item.url).data patron = r'