Version 0.3.12
This commit is contained in:
1 parent
054d387e37
commit
7854310240
3 files changed
+11
-3
No files matched your search
@@ -1,7 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||||
<addon id="plugin.video.movistarplus"
|
<addon id="plugin.video.movistarplus"
|
||||||
name="Movistar+"
|
name="Movistar+"
|
||||||
version="0.3.11"
|
version="0.3.12"
|
||||||
provider-name="Paco8">
|
provider-name="Paco8">
|
||||||
<requires>
|
<requires>
|
||||||
<!--- <import addon="xbmc.python" version="2.25.0"/> -->
|
<!--- <import addon="xbmc.python" version="2.25.0"/> -->
|
||||||
|
|||||||
@@ -80,6 +80,8 @@ class Movistar(object):
|
|||||||
|
|
||||||
# Device ID
|
# Device ID
|
||||||
self.account['device_id'] = self.cache.load_file('device_id.conf')
|
self.account['device_id'] = self.cache.load_file('device_id.conf')
|
||||||
|
if self.account['device_id']:
|
||||||
|
self.account['device_id'] = self.account['device_id'].strip('"')
|
||||||
if not reuse_devices:
|
if not reuse_devices:
|
||||||
LOG('not reusing devices')
|
LOG('not reusing devices')
|
||||||
if not self.account['device_id']:
|
if not self.account['device_id']:
|
||||||
@@ -326,6 +328,7 @@ class Movistar(object):
|
|||||||
return self.delete_device(self.account['device_id'])
|
return self.delete_device(self.account['device_id'])
|
||||||
|
|
||||||
def new_device_id(self):
|
def new_device_id(self):
|
||||||
|
"""
|
||||||
headers = self.net.headers.copy()
|
headers = self.net.headers.copy()
|
||||||
headers['Content-Type'] = 'application/json'
|
headers['Content-Type'] = 'application/json'
|
||||||
headers['x-movistarplus-ui'] = '2.36.30'
|
headers['x-movistarplus-ui'] = '2.36.30'
|
||||||
@@ -334,7 +337,12 @@ class Movistar(object):
|
|||||||
url = 'https://auth.dof6.com/movistarplus/webplayer/accounts/'+ self.account['id'] + '/devices/?qspVersion=ssp'
|
url = 'https://auth.dof6.com/movistarplus/webplayer/accounts/'+ self.account['id'] + '/devices/?qspVersion=ssp'
|
||||||
response = self.net.session.post(url, headers=headers)
|
response = self.net.session.post(url, headers=headers)
|
||||||
content = response.content.decode('utf-8')
|
content = response.content.decode('utf-8')
|
||||||
return content.replace('"', '')
|
return content.strip('"')
|
||||||
|
"""
|
||||||
|
import random
|
||||||
|
s = ''
|
||||||
|
for _ in range(0, 32): s += random.choice('abcdef0123456789')
|
||||||
|
return s
|
||||||
|
|
||||||
def delete_device(self, device_id):
|
def delete_device(self, device_id):
|
||||||
headers = self.net.headers.copy()
|
headers = self.net.headers.copy()
|
||||||
|
|||||||
@@ -161,7 +161,7 @@ class RequestHandler(BaseHTTPRequestHandler):
|
|||||||
global previous_token, reregister_needed
|
global previous_token, reregister_needed
|
||||||
while True:
|
while True:
|
||||||
LOG('reregister_needed: {}'.format(reregister_needed))
|
LOG('reregister_needed: {}'.format(reregister_needed))
|
||||||
if reregister_needed:
|
if reregister_needed and xbmcaddon.Addon().getSettingBool('reregister'):
|
||||||
mvs().unregister_device()
|
mvs().unregister_device()
|
||||||
mvs().register_device()
|
mvs().register_device()
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user