streamingcommunity URL statico
This commit is contained in:
@@ -39,6 +39,8 @@
|
||||
"serietvsubita": "http://serietvsubita.xyz",
|
||||
"serietvu": "https://www.serietvu.live",
|
||||
"streamtime": "https://t.me/s/StreamTime",
|
||||
"streamingita": "https://www.streamingita.pro",
|
||||
"streamingcommunity": "https://streamingcommunity.space",
|
||||
"tantifilm": "https://www.tantifilm.cfd",
|
||||
"tapmovie": "https://it.tapmovie.net",
|
||||
"toonitalia": "https://toonitalia.co",
|
||||
@@ -47,7 +49,6 @@
|
||||
"findhost": {
|
||||
"altadefinizionecommunity": "https://altaregistrazione.net",
|
||||
"animealtadefinizione": "https://www.animealtadefinizione.it",
|
||||
"filmpertutti": "https://filmpertuttiii.nuovo.live",
|
||||
"streamingcommunity": "https://streamingcommunity-nuovo.link"
|
||||
"filmpertutti": "https://filmpertuttiii.nuovo.live"
|
||||
}
|
||||
}
|
||||
@@ -9,33 +9,34 @@ from core import support, channeltools, httptools
|
||||
from platformcode import logger
|
||||
|
||||
|
||||
def findhost(url):
|
||||
return 'https://' + support.match(url, patron='var domain\s*=\s*"([^"]+)').match
|
||||
# def findhost(url):
|
||||
# return 'https://' + support.match(url, patron='var domain\s*=\s*"([^"]+)').match
|
||||
|
||||
|
||||
host = support.config.get_channel_url(findhost)
|
||||
host = support.config.get_channel_url()
|
||||
session = requests.Session()
|
||||
session.request = functools.partial(session.request, timeout=httptools.HTTPTOOLS_DEFAULT_DOWNLOAD_TIMEOUT)
|
||||
headers = {}
|
||||
|
||||
|
||||
def getHeaders(forced=False):
|
||||
global headers
|
||||
global host
|
||||
if not headers:
|
||||
try:
|
||||
headers = {'User-Agent': 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14'}
|
||||
response = session.get(host, headers=headers)
|
||||
if not response.url.startswith(host):
|
||||
host = support.config.get_channel_url(findhost, forceFindhost=True)
|
||||
csrf_token = support.match(response.text, patron='name="csrf-token" content="([^"]+)"').match
|
||||
headers = {'User-Agent': 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14',
|
||||
'content-type': 'application/json;charset=UTF-8',
|
||||
'Referer': host,
|
||||
'x-csrf-token': csrf_token,
|
||||
'Cookie': '; '.join([x.name + '=' + x.value for x in response.cookies])}
|
||||
except:
|
||||
host = support.config.get_channel_url(findhost, forceFindhost=True)
|
||||
if not forced: getHeaders(True)
|
||||
# try:
|
||||
headers = {'User-Agent': 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14'}
|
||||
response = session.get(host, headers=headers)
|
||||
# if not response.url.startswith(host):
|
||||
# host = support.config.get_channel_url(findhost, forceFindhost=True)
|
||||
csrf_token = support.match(response.text, patron='name="csrf-token" content="([^"]+)"').match
|
||||
headers = {'User-Agent': 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14',
|
||||
'content-type': 'application/json;charset=UTF-8',
|
||||
'Referer': host,
|
||||
'x-csrf-token': csrf_token,
|
||||
'Cookie': '; '.join([x.name + '=' + x.value for x in response.cookies])}
|
||||
# except:
|
||||
# host = support.config.get_channel_url(findhost, forceFindhost=True)
|
||||
# if not forced: getHeaders(True)
|
||||
|
||||
getHeaders()
|
||||
|
||||
|
||||
@@ -729,7 +729,7 @@ def dooplay_search(item, blacklist=""):
|
||||
|
||||
|
||||
def dooplay_search_vars(item, blacklist):
|
||||
if item.contentType == 'list': # ricerca globale
|
||||
if item.contentType == 'undefined': # ricerca globale
|
||||
type = '(?P<type>movies|tvshows)'
|
||||
typeActionDict = {'findvideos': ['movies'], 'episodios': ['tvshows']}
|
||||
typeContentDict = {'movie': ['movies'], 'tvshow': ['tvshows']}
|
||||
|
||||
@@ -11,7 +11,7 @@ from platformcode import logger, config
|
||||
def test_video_exists(page_url):
|
||||
logger.info("(page_url='%s')" % page_url)
|
||||
response = httptools.downloadpage(page_url)
|
||||
if not response.sucess or "Not Found" in response.data or "File was deleted" in response.data \
|
||||
if not response.success or "Not Found" in response.data or "File was deleted" in response.data \
|
||||
or "is no longer available" in response.data:
|
||||
return False, config.get_localized_string(70449) % "Streamlare"
|
||||
return True, ""
|
||||
|
||||
Reference in New Issue
Block a user