From d1f8cbaf49005ae4e8744d2b8ca736a518a4f5ee Mon Sep 17 00:00:00 2001 From: fayer3 Date: Fri, 23 Oct 2020 19:24:58 +0200 Subject: [PATCH] v0.4.14 --- addon.xml | 4 +++- changelog.txt | 4 +++- resources/lib/plugin.py | 4 ++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/addon.xml b/addon.xml index ab9709e..c17a6ff 100644 --- a/addon.xml +++ b/addon.xml @@ -1,5 +1,5 @@ - + @@ -74,6 +74,8 @@ - VOD Abfrage repariert dank hrickes. 0.4.13: - ändernder VOD Abfrage zu der vom Server erhaltenen, dies limitiert tie Auflösung auf SD ohne Plus+. +0.4.14: +- beheben von padding Fehler. resources/icon.png diff --git a/changelog.txt b/changelog.txt index c948a60..ba64e0a 100644 --- a/changelog.txt +++ b/changelog.txt @@ -78,4 +78,6 @@ v0.4.11: v0.4.12: - fixed VOD request thanks to hrickes. v0.4.13: -- change VOD request to the one received from the server, this limits playback in most cases to SD resolution without Plus+. \ No newline at end of file +- change VOD request to the one received from the server, this limits playback in most cases to SD resolution without Plus+. +v0.4.14: +- fix padding error. \ No newline at end of file diff --git a/resources/lib/plugin.py b/resources/lib/plugin.py index 562bbe8..7903147 100644 --- a/resources/lib/plugin.py +++ b/resources/lib/plugin.py @@ -995,9 +995,9 @@ def play_video(video_id, tvshow_id, brand, duration): if 'yo.p.fn' in parsed_query and len(parsed_query['yo.p.fn']) > 0: found = True #add missing padding - base64_url_with_padding = parsed_query['yo.p.fn'][0] + '===' + base64_url_with_padding = parsed_query['yo.p.fn'][0] + ('='*(4-len(parsed_query['yo.p.fn'][0])%4)) log(u'base64 url: {0}'.format(base64_url_with_padding)) - video_url = base64.b64decode(base64_url_with_padding) + video_url = base64.urlsafe_b64decode(str(base64_url_with_padding)) if not found: video_url_data = get_url(video_url, headers={'User-Agent': ids.video_useragent}, key = False, critical = True) # get base url