Merge branch 'master' of https://github.com/kodiondemand/addon
This commit is contained in:
@@ -14,7 +14,11 @@ list_quality = ['default']
|
||||
|
||||
def findhost():
|
||||
permUrl = httptools.downloadpage('https://www.cinemalibero.online/', follow_redirects=False).headers
|
||||
return 'https://www.' + permUrl['location'].replace('https://www.google.com/search?q=site:', '')
|
||||
import urlparse
|
||||
p = list(urlparse.urlparse(permUrl['location'].replace('https://www.google.com/search?q=site:', '')))
|
||||
if not p[0]:
|
||||
p[0] = 'https'
|
||||
return urlparse.urlunparse(p)
|
||||
|
||||
host = config.get_channel_url(findhost)
|
||||
headers = [['Referer', host]]
|
||||
|
||||
@@ -253,7 +253,7 @@ def downloadpage(url, **opt):
|
||||
load_cookies()
|
||||
domain = urlparse.urlparse(url).netloc
|
||||
CF = False
|
||||
if domain in ['www.guardaserie.media', 'casacinema.space', 'wstream.video', 'akvideo.stream', 'backin.net', 'dreamsub.stream']:
|
||||
if domain in ['www.guardaserie.media', 'casacinema.space', 'wstream.video', 'akvideo.stream', 'backin.net', 'dreamsub.stream', 'altadefinizione-nuovo.link']:
|
||||
from lib import cloudscraper
|
||||
session = cloudscraper.create_scraper()
|
||||
CF = True
|
||||
|
||||
@@ -515,7 +515,8 @@ class UnshortenIt(object):
|
||||
|
||||
return uri, r.code if r else 200
|
||||
except Exception as e:
|
||||
return uri, str(e)
|
||||
logger.error(e)
|
||||
return uri, 0
|
||||
|
||||
|
||||
def _unshorten_linkup(self, uri):
|
||||
|
||||
@@ -25,7 +25,15 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
|
||||
|
||||
packed = scrapertools.find_single_match(data, r'(eval.*?)</script>')
|
||||
unpacked = jsunpack.unpack(packed)
|
||||
media_url = scrapertools.find_single_match(unpacked, r'MDCore\.furl\s*=\s*"([^"]+)"')
|
||||
|
||||
# mixdrop like to change var name very often, hoping that will catch every
|
||||
list_vars = scrapertools.find_multiple_matches(unpacked, r'MDCore\.\w+\s*=\s*"([^"]+)"')
|
||||
for var in list_vars:
|
||||
if '.mp4' in var:
|
||||
media_url = var
|
||||
break
|
||||
else:
|
||||
media_url = ''
|
||||
if not media_url.startswith('http'):
|
||||
media_url = 'http:%s' % media_url
|
||||
video_urls.append(["%s [Mixdrop]" % ext, media_url])
|
||||
|
||||
Reference in New Issue
Block a user